Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My logwatch reports, within the CRON section, contain thousands of entries like those below. How can I either reduce the number of log entries OR have logwatch ignore them?

Jan 30 18:49:01 ota3 CRON[14054]: pam_unix(cron:session): session opened for user zzz by (uid=0)

Jan 30 18:49:03 ota3 CRON[13055]: pam_unix(cron:session): session closed for user root

Jan 30 18:49:08 ota3 CRON[14054]: pam_unix(cron:session): session closed for user zzz

Jan 30 18:50:01 ota3 CRON[14108]: pam_unix(cron:session): session opened for user zzzr by (uid=0) 
share|improve this question
up vote 4 down vote accepted

Go to the /etc/pam.d directory. Open the file common-session-noninteractive in an editor. Look for the following line:

session required

Above this line, add the following:

session [success=1 default=ignore] service in cron quiet use_uid

Save the file and exit. Restart crond using something like service cron restart or /etc/init.d/cron restart.


share|improve this answer
Thanks Tiago - that did the job – RoyHB Apr 14 '13 at 10:48

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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