

$ touch /home/tecmint/.swatchdogrcĪdd your regular expression in this file and each line should contain a keyword and value (sometimes optional), separated by a space or an equal (=) sign. swatchrc), to determine what types of expression patterns to look for and what type of action(s) should be taken when a pattern is matched. Once you have installed the swatch, you need to create its configuration file (default location is /home/$USER/.swatchdogrc or.
#Linux filewatcher remove spaces from filename install
To install most latest version of swatchdog, you need to compile it from source using following commands in any Linux distribution. $ sudo yum install epel-release & sudo yum install swatch The package swatchdog is available to install from the official repositories of mainstream Linux distributions as a package “ swatch” via a package manager as shown. Importantly, swatchdog has grown from a script for watching logs produced by Unix’s syslog facility, and it can monitor just about any kind of logs.

Read Also: 4 Good Open Source Log Monitoring and Management Tools for Linux Note that the program was originally called swatch (the “ Simple Watcher”) but a request by the old Swiss watch company for a name change saw the developer change its name to swatchdog. You can run it from the command line or in the background, detached from any terminal using the daemon mode option. It watches your logs based on regular expressions that you can define in a configuration file. Swatchdog (the “ Simple WATCH DOG”) is a simple Perl script for monitoring active log files on Unix-like systems such as Linux.
