Heya All,
I have tried to implement pflogsumm on my CentOS 5 box. I have followed the how-to exactly. Now what happens is:
1. Where there used to be 4 maillog files in /var/log (maillog, maillog.0, maillog.1, etc) there is only 1 huge maillog file.
2. I get a mailing every day from the cron daemon that says:
"/etc/cron.daily/logrotate:
error: syslog:1 duplicate log entry for /var/log/messages"
Logwatch is installed and running per the default for CentOS 5 (I didn't install it, it was installed with the OS).
So it seems that logrotate is failing but I cannot find where or why. Here is my logrotate.conf:
[root@mail etc]# more logrotate.conf
# see "man logrotate" for details
# rotate log files weekly
weekly
# keep 4 weeks worth of backlogs
rotate 4
# create new (empty) log files after rotating old ones
create
# uncomment this if you want your log files compressed
#compress
# RPM packages drop log rotation information into this directory
include /etc/logrotate.d
# no packages own wtmp -- we'll rotate them here
/var/log/wtmp {
monthly
minsize 1M
create 0664 root utmp
rotate 1
}
# system-specific logs may be also be configured here.
/var/log/maillog {
missingok
daily
rotate 7
create
compress
start 0
postrotate
/bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
endscript
}
I did no mods to the cron job for the logrotate. Here is my /usr/local/sbin/postfix_report.sh:
[root@mail etc]# more /usr/local/sbin/postfix_report.sh
exit 0TH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
gunzip /var/log/maillog.0.gz
pflogsumm /var/log/maillog.0 | formail -c -I"Subject: Mail Statistics" -I"From: pflogsumm@<mydomain>.net" -I"To:
systems@<mydomain>.net" -I"Received: from mail.<mydomain>.net ([192.168.1.11])" | sendmail systems@<mydomain>.net
gzip /var/log/maillog.0
exit 0
The message from the cron seems no help at all but def something I did affected it as I didn't get it until the night I tried to implement pflogsumm...
Any help would be greatly appreciated! I will prvide any other info you might need.
Regards,
Chumley
Edited: Removed my real domain before some crawler grabs my email for spam use
Recent comments
2 days 6 hours ago
2 days 15 hours ago
2 days 18 hours ago
2 days 19 hours ago
2 days 20 hours ago
2 days 22 hours ago
3 days 3 min ago
3 days 1 hour ago
3 days 17 hours ago
3 days 18 hours ago