My logwatch is configured correctly and is working correctly when I issue manually


I added it to root's crontab and it is listed correctly when I make crontab -l which gives:

0 5 * * * /etc/cron.daily/0logwatch
0 2 * * * /usr/sbin/logwatch
0 3 * * * /etc/cron.daily/one_of_my_scripts
0 4 * * * /etc/cron.daily/another_script

My scripts work great but logwatch is not working although I added it twice in crontab using a direct call and using the script that is prepared to be run from cron.daily

/var/log/cron seams not to log per-user crontab activities

Any clues?

  • You realize that there is > 1 location where these type of service crons are located right? Have you checked these as well? – mdpc May 8 '14 at 4:27
  • Sorry, I can't get your point. – mmonem May 8 '14 at 8:49
  • Work your way through serverfault.com/questions/449651/… it will help you gather information that will either solve your problem or help us help you. – user9517 May 8 '14 at 9:47
  • Thank you. I followed the link and set the MAITO variable and knew where the problem comes from. sendmail is under /usr/sbin which is not enabled by default for crontab entries – mmonem May 9 '14 at 4:08

I followed @lain's link (thanks @lain), set the MAILTO variable, waited for the report email which let me know that the problem comes from sendmail which is located is under /usr/sbin which is not enabled by default for crontab entries. I just adjusted the PATH and everything is alright

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.