Project

General

Profile

Linux Server Monitoring Tools and Tips

Tips

Reviewing atop history

When atop is installed on Debian it is running as daemon and writes raw samples to /var/log/atop* These samples can be replayed. E.g.:

atop -r /var/log/atop.log.1

You can step to the next sample by pressing t and switch the view modes m =memory g = general

Monitoring Tools

atop

The program atop is an interactive monitor to view the load on a Linux system. It shows the occupation of the most critical hardware resources (from a performance point of view) on system level, i.e. cpu, memory, disk and network.

It also shows which processes are responsible for the indicated load with respect to cpu- and memory load on process level; disk- and network load is only shown per process if a kernel patch has been installed.

...

dstat

Dstat is a versatile replacement for vmstat, iostat and ifstat. Dstat overcomes some of the limitations and adds some extra features.

Dstat allows you to view all of your system resources instantly, you can eg. compare disk usage in combination with interrupts from your IDE controller, or compare the network bandwidth numbers directly with the disk throughput (in the same interval).

Dstat also cleverly gives you the most detailed information in columns and clearly indicates in what magnitude and unit the output is displayed. Less confusion, less mistakes, more efficient.

Dstat is unique in letting you aggregate block device throughput for a certain diskset or network bandwidth for a group of interfaces, ie. you can see the throughput for all the block devices that make up a single filesystem or storage system.

Dstat allows its data to be directly written to a CSV file to be imported and used by OpenOffice, Gnumeric or Excel to create graphs.

collectl

http://collectl.sourceforge.net/

There are a number of times in which you find yourself needing performance data. These can include benchmarking, monitoring a system's general heath or trying to determine what your system was doing at some time in the past. Sometimes you just want to know what the system is doing right now. Depending on what you're doing, you often end up using different tools, each designed to for that specific situation.

Unlike most monitoring tools that either focus on a small set of statistics, format their output in only one way, run either interatively or as a daemon but not both, collectl tries to do it all. You can choose to monitor any of a broad set of subsystems which currently include buddyinfo, cpu, disk, inodes, infiniband, lustre, memory, network, nfs, processes, quadrics, slabs, sockets and tcp.

The article Try collectl for System Monitoring on serverwatch gives a introduction into collectl.

(At)sar

atsar — system activity report

The program atsar(1) can be used to deliver statistics. The design of

this program can be compared with the standard sadc(1) and sar(1)

programs being delivered for other UNIX-implementations, i.e. a data-

collector which reads the statistical counters (from the files under

the directory /proc ) and a presentation-program which formats the

counters and presents them on stdout.

_ collectl is newer utility and is supposed to be preferred from atsar._

monit

monit is a utility for managing and monitoring processes, files, directories and devices on a Unix system. Monit conducts automatic maintenance and repair and can execute meaningful causal actions in error situations. E.g. monit can start a process if it does not run, restart a process if it does not respond and stop a process if it uses to much resources. You may use monit to monitor files, directories and devices for changes, such as timestamps changes, checksum changes or size changes.

Monit is controlled via an easy to configure control file based on a free-format, token-oriented syntax. Monit logs to syslog or to its own log file and notifies you about error conditions via customizable alert messages. Monit can perform various TCP/IP network checks, protocol checks and can utilize SSL for such checks. Monit provides a http(s) interface and you may use a browser to access the monit program.

see also monin

monin

see also monit

Apache log-file analyses

asql

http://www.steve.org.uk/Software/asql/

asql is a simple console shell which allows you to run SQL queries against an Apache logfile, something that can be very useful - especially at getting information which is not easily available via static logfile analysers.

can be installed via apt-get

Add picture from clipboard (Maximum size: 40 MB)