If you want to check some errors in /var/log/syslog or /var/log/auth.log and you find both files empty, it means system is not able to write logs in both files because of permission issue or any mis configuration. Here is solution for you.
Solution :
Reconfigure rsyslog
Solution :
Reconfigure rsyslog
sudo apt-get install --reinstall rsyslog
sudo service rsyslog restart
If still it does not work, issue may be with permissions, check the owner of both files.
ls -l /var/log/syslog
ls -l /var/log/auth.log
Group and owner should be syslog & adm, if owner or group is set as root or anything else, you need to change with following commands
sudo chown syslog:adm /var/log/syslog
sudo chown syslog:adm /var/log/auth.log
Now check if it starts writing logs in both files. Still it does not work, restart the service rsyslog.
sudo service rsyslog restart
it should work now.
No comments:
Post a Comment