Gentlemen, As stated last friday, I'd like enhance syslog-ng with some features in order to get rid of some log rotation scripts: "For some of our systems, we log to a centralised system, but also store the logs locally. These local logs only need limited availability, say a week or so. The file() destination currently is already able to use the target $WEEKDAYS, but in that case, logs from both Jan 17 and Jan 24 are logged in messages.Thu.log Therefore, I'd like to add a new option remove_if_older(X) which removes a logfile with a timestamp older than X days prior to writing the new message to that file. (default should be 0 (=never), which means that for a disabled feauture only one C 'if' statement additional overhead is caused)" I've finished implementing the above feature, which is attached as a patch. I patched against 1.4.14, the latest stable version, and it probably will work for the unstable tree, too. The patch compiles and is verified to work for SuSE Linux 6.4 (Linux 2.2.19 kernel, gcc 2.95.2, libc 2.1.3 ). I hope everybody thinks it's a nice feature and that this patch is soon added to a new stable syslog-ng release... (Please, Balazs???) Groetjes, Klaas van Gend
On Fri, Feb 01, 2002 at 02:30:15PM +0100, klaas.vangend@philips.com wrote:
Gentlemen,
As stated last friday, I'd like enhance syslog-ng with some features in order to get rid of some log rotation scripts:
Applied. Changed a bit to use seconds as the time (since everything in syslog-ng uses seconds (time_reap, time_reopen, etc)) -- Bazsi PGP info: KeyID 9AF8D0A9 Fingerprint CD27 CFB0 802C 0944 9CFD 804E C82C 8EB1
participants (2)
-
Balazs Scheidler
-
klaas.vangend@philips.com