logwatch tool to monitor all the log files and send you via mail
Step:1
sudo apt-get update
sudo apt-get install logwatch
Step 2: Configure Logwatch
sudo cp /usr/share/logwatch/default.conf/logwatch.conf /etc/logwatch/conf/logwatch.conf
Edit configuration file
sudo nano /etc/logwatch/conf/logwatch.conf
Key parameters to configure:
Output
Output = mail
MailTo:
MailTo = your-email@example.com
MailFrom:
MailFrom = logwatch@example.com
Detail:
Set the level of detail (Low, Med, High).
Detail = LowService:
Service = AllStep:3LogDir = /var/logStep 4: Test Logwatch Configurationsudo logwatch --output mail --mailto your-email@example.com --detail Low
Comments
Post a Comment