Syslog-ng port and newsyslog
freebsd-ports
freebsd-ports at socruel.nu
Fri Dec 3 11:50:03 PST 2004
Hello,
I have installed the Syslog-ng port and I do not seem to get the
rotation of the logfiles right.
Newsyslog has /var/run/syslog.pid hardcoded as it's pid file, so I
already configured this as the pid file for syslog-ng. But at rotation
newsyslog doesn't zip the logfiles as stated in my /etc/newsyslog.conf
file.
Does anyone have a clue what is wrong here?
When I used the syslog daemon from FreeBSD eveything worked ok (that
means with the rotation the logfiles were zipped).
root at charlie OLD # uname -a
FreeBSD charlie.socruel.nu 4.9-RELEASE-p10 FreeBSD 4.9-RELEASE-p10 #0:
Sun Jun 20 20:59:05 CEST 2004
root at charlie.socruel.nu:/usr/obj/usr/src/sys/CHARLIE i386
root at charlie OLD # less /etc/newsyslog.conf
########################################################################
#
#
# Filename : /etc/newsyslog.conf
# Description : Configuration file for newsyslog
#
#-----------------------------------------------------------------------
-
# Revision History
#
# Date Initiator Description
# 04/11/27 Lars Changed stuff, v. 0.11
# 03/06/14 Lars Creation, v. 0.1
#
########################################################################
#
# Format :
# logfilename [owner.group] mode count size when [ZB]
[/pid_file] [sig_num]
/var/log/messages root.wheel 600 12 * $M1D0 Z
/var/log/cron.log root.wheel 600 28 * $D0 Z
/var/log/su.log root.wheel 600 28 * $D0 Z
/var/log/mail.log root.wheel 600 12 * $M1D0 Z
/var/log/daemon.log root.wheel 600 12 * $M1D0 Z
########################################################################
#
#
# File : /etc/crontab
# Description : root's crontab for FreeBSD.
#
#-----------------------------------------------------------------------
-
# Revision History
#
# Date Initiator Description
# 04/10/24 Lars Added freshclam, v. 0.11
# 03/06/14 Lars Creation, v. 0.1
#
########################################################################
#
#
#-----------------------------------------------------------------------
-
# Define some variables
#-----------------------------------------------------------------------
-
SHELL=/bin/sh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin
HOME=/var/log
MAILTO=""
#
#-----------------------------------------------------------------------
-
# The default FreeBSD stuff ...
#-----------------------------------------------------------------------
-
#
#minute hour mday month wday who command
#
*/5 * * * * root /usr/libexec/atrun
#
# rotate log files every hour, if necessary
0 * * * * root newsyslog -a
/var/log/OLD
#
# do daily/weekly/monthly maintenance
#1 3 * * * root periodic daily
#15 4 * * 6 root periodic weekly
#30 5 1 * * root periodic monthly
#
# time zone change adjustment for wall cmos clock,
# does nothing, if you have UTC cmos clock.
# See adjkerntz(8) for details.
1,31 0-5 * * * root adjkerntz -a
#
#-----------------------------------------------------------------------
-
########################################################################
#
#
# File : charlie:/etc/rc.conf
# Description : Startup configuration file. This file contains the
# overrides from /etc/defaults/rc.conf.
#
#-----------------------------------------------------------------------
-
# Revision History
#
# Date Initiator Description
# 04/12/02 Lars Changed syslog-ng pidfile, v.0.16
# 04/11/27 Lars Changed syslogd, v. 0.15
# 04/10/24 Lars Added Clam AV daemon, v. 0.14
# 04/06/06 Lars Added alias on xl0 interface, v. 0.12
# 04/04/05 Lars Changed ip address, v. 0.11
# 03/06/14 Lars Creation, v. 0.1
#
########################################################################
#
#-----------------------------------------------------------------------
-
# Basic network options.
#-----------------------------------------------------------------------
-
ifconfig_xl0="inet 172.16.1.1 netmask 255.255.255.0"
ifconfig_xl0_alias0="inet a.b.c.d netmask 255.255.255.255"
hostname="charlie.socruel.nu"
#-----------------------------------------------------------------------
-
# Network routing options.
#-----------------------------------------------------------------------
-
defaultrouter="172.16.1.254"
#-----------------------------------------------------------------------
-
# Local startup
#-----------------------------------------------------------------------
-
#####local_startup="/etc/rc.d"
#-----------------------------------------------------------------------
-
# Network daemons.
#-----------------------------------------------------------------------
-
syslogd_enable="YES"
syslogd_program="/usr/local/sbin/syslog-ng"
syslogd_flags="-f /usr/local/etc/syslog-ng/syslog-ng.conf -p
/var/run/syslog.pid"
Regards,
Lars.
More information about the freebsd-ports
mailing list