Chapter 29. System Monitoring Utilities

Table of Contents

29.1. Conventions
29.2. List Of Open Files: lsof
29.3. Who Is Accessing Files: fuser
29.4. Properties Of A File: stat
29.5. Processes: top
29.6. Process List: ps
29.7. Process Tree: pstree
29.8. Who is Doing What: w
29.9. Memory Usage: free
29.10. Kernel Ring Buffer: dmesg
29.11. File Systems And Their Usage: mount, df and du
29.12. The /proc File System
29.13. procinfo
29.14. PCI Resources: lspci
29.15. System Calls Of A Program Run: strace
29.16. Library Calls of a Program Run: ltrace
29.17. Specifying The Required Library: ldd
29.18. Inter Process Communication: ipcs

Abstract

This chapter presents a number of programs and mechanisms with which you can examine the status of your system. Also described are some utilities that are useful for routine work, along with their most important parameters.

29.1. Conventions

For each of the commands introduced, examples of the relevant outputs are presented. In these examples, the first line is the command itself (after the dollar-sign prompt). Remarks are indicated by the use of square brackets [...] and long lines are broken up where necessary. Line endings for long lines are indicated by a backslash (\).

$ command -x -y
output line 1
output line 2
output line 3 is annoyingly long, so long that \
    we have to break it
output line 3
[...]
output line 98
output line 99

The descriptions have been kept short so as to allow as many utilities as possible to be mentioned. Further information on all the commands will be found in the relevant pages of the manual. Most of the commands also understand the parameter --help, which produces a brief list of the possible parameters.