Date: Tue, 29 May 2007 16:26:47 -0400 From: Garance A Drosihn <drosih@rpi.edu> To: Andreas Klemm <andreas@freebsd.org>, stable@freebsd.org Subject: Re: 6.2: maillog grows, newsyslog's misbehaving ? Message-ID: <p06240805c2823a29bc2f@[128.113.24.47]> In-Reply-To: <20070528110858.GA1656@titan.klemm.apsfilter.org> References: <20070528110858.GA1656@titan.klemm.apsfilter.org>
next in thread | previous in thread | raw e-mail | index | archive | help
At 1:08 PM +0200 5/28/07, Andreas Klemm wrote: >Hi, > >discovered that the maillog file on my freebsd Desktop >grows and grows (now at 50MB). > >According to the newsyslog.conf file it should be trimmed >every night at midnight. > >/var/log/maillog 640 7 * @T00 JC > >Is it a prerequisite, that the system then runs 24x7 so >that the newsyslog default settings work ? As mentioned in the man page for newsyslog.conf : If a time is specified, the log file will only be trimmed if newsyslog(8) is run within one hour of the specified time. You could force a rotate by running newsyslog yourself: /usr/sbin/newsyslog -F /var/log/maillog but that would be a one-time fix. There is a startup file for newsyslog in /etc/rc.d which runs the program one-time at startup. You could set an alternate value for the variable 'newsyslog_flags' in your /etc/rc.conf file, and use that to do the checks you want at startup. This would probably mean creating a duplicate newsyslog.conf file. So, to answer your question: Yes, the default settings for newsyslog.conf do assume that your system is running 24x7. -- Garance Alistair Drosehn = gad@gilead.netel.rpi.edu Senior Systems Programmer or gad@freebsd.org Rensselaer Polytechnic Institute or drosih@rpi.edu
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?p06240805c2823a29bc2f>