LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-13-2005, 03:10 PM   #1
raybcher
LQ Newbie
 
Registered: Aug 2003
Location: Fredericton NB
Posts: 4

Rep: Reputation: 0
Question How can I configure the cron log?


Hello all,

I'm running Mandrake Linux 9.2 and I have a small problem with the cron logs.
Cron works and logs perfectly but the logs are of a circular type and only cover about 1.5 day (after which the oldest entries are overwritten).
Logrotate cycles them weekly so I'm missing 5 of every 7 days.

How can I make the cron logs (/var/log/cron/info etc) sequential with unlimited space?

I looked in syslog.conf and checked every man page I could think of but no cigar!

Thanks

RayB
 
Old 12-13-2005, 03:35 PM   #2
jlinkels
LQ Guru
 
Registered: Oct 2003
Location: Bonaire, Leeuwarden
Distribution: Debian /Jessie/Stretch/Sid, Linux Mint DE
Posts: 5,195

Rep: Reputation: 1044Reputation: 1044Reputation: 1044Reputation: 1044Reputation: 1044Reputation: 1044Reputation: 1044Reputation: 1044
This might not be THE solution, but maybe it gives you a hint in the right direction.

Syslogd takes care of logging, but logrotate takes care of daily renaming and replacement of log files.

In syslog.conf you configure what is written in which log file, e.q. cron messages go into /var/log/cron/whatever.log.

However, logrotate determines when a file is to be rotated, based on size(!) or frequency. You should be able to specify that in logrotate.conf. Have you checked that file?

Furthermore, logrotate is run daily by cron, it is possible that additional parameters are specified on the commandline. Usually, log files are overwritten each week from the beginning, meaning that you should have 7 log files of each kind. If logrotate is configured like that it is pretty impossible that you loose 5 out of 7 days.

In Debian /etc/cron.daily contains a number of scripts being run daily, but that might be different in Mandrake.

jlinkels
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Does cron have a log I can read? ivj Linux - Software 2 08-18-2005 06:23 PM
cron log empty plisken Slackware 2 11-17-2004 09:00 AM
Cron Log filling up barnzenen AIX 3 10-09-2004 06:04 PM
Can't get Cron to log anything t3___ Linux - Newbie 3 05-19-2004 10:14 AM
dual entries in cron log for cron.daily cpharvey Linux - General 3 02-27-2003 02:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:49 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration