Easy Tutorial
❮ Linux Comm Chattr Linux Comm Tload ❯

Linux swatch Command

Linux Command Manual

The Linux swatch command is used for system monitoring.

swatch can be used to monitor system log files and perform specified actions when certain events occur. The events and corresponding actions to be monitored by swatch are stored in the swatch configuration file. The default configuration file is located in the user's home directory as .swatchrc. However, under the default user home directory of Red Hat Linux, there is no .swatchrc configuration file. You can copy the /usr/doc/swatch-2.2/config_files/swatchrc.personal file to the user's home directory as .swatchrc, and then modify the .swatchrc file to specify the events to be monitored and the actions to be taken.

Syntax

swatch [-A <delimiter>][-c &lt;config file>][-f &lt;log file>][-I <delimiter>][-P <delimiter>][-r <time>][-t &lt;log file>]

Parameter Description:

Example

Start system monitoring

# swatch

Linux Command Manual

❮ Linux Comm Chattr Linux Comm Tload ❯