[zebra 22133] logrotate does not work with zebra log file
shen mode
shenmode at yahoo.com.cn
Sat Jan 22 09:55:25 UTC 2005
Hi,
I tried to rotate ospf log file which is created by
ospfd in zebra.
I set up logrotate.conf like:
/data1/netflow/zebra/log/ospf.log {
daily
rotate 7
copytruncate
compress
}
and execute logrotate as:
/usr/sbin/logrotate -s /var/log/logrotate.status
/etc/logrotate.conf -f --debug
it shows :
rotating pattern: /data1/netflow/zebra/log/ospf.log
forced from command line (7 rotations)
empty log files are rotated, old logs are removed
considering log /data1/netflow/zebra/log/ospf.log
log needs rotating
rotating log /data1/netflow/zebra/log/ospf.log,
log->rotateCount is 7
renaming /data1/netflow/zebra/log/ospf.log.7.gz to
/data1/netflow/zebra/log/ospf.log.8.gz (rotatecount 7,
logstart 1, i 7),
renaming /data1/netflow/zebra/log/ospf.log.6.gz to
/data1/netflow/zebra/log/ospf.log.7.gz (rotatecount 7,
logstart 1, i 6),
renaming /data1/netflow/zebra/log/ospf.log.5.gz to
/data1/netflow/zebra/log/ospf.log.6.gz (rotatecount 7,
logstart 1, i 5),
renaming /data1/netflow/zebra/log/ospf.log.4.gz to
/data1/netflow/zebra/log/ospf.log.5.gz (rotatecount 7,
logstart 1, i 4),
renaming /data1/netflow/zebra/log/ospf.log.3.gz to
/data1/netflow/zebra/log/ospf.log.4.gz (rotatecount 7,
logstart 1, i 3),
renaming /data1/netflow/zebra/log/ospf.log.2.gz to
/data1/netflow/zebra/log/ospf.log.3.gz (rotatecount 7,
logstart 1, i 2),
renaming /data1/netflow/zebra/log/ospf.log.1.gz to
/data1/netflow/zebra/log/ospf.log.2.gz (rotatecount 7,
logstart 1, i 1),
renaming /data1/netflow/zebra/log/ospf.log.0.gz to
/data1/netflow/zebra/log/ospf.log.1.gz (rotatecount 7,
logstart 1, i 0),
copying /data1/netflow/zebra/log/ospf.log to
/data1/netflow/zebra/log/ospf.log.1
truncating /data1/netflow/zebra/log/ospf.log
compressing new log with: /bin/gzip
'/data1/netflow/zebra/log/ospf.log.1'
removing old log
/data1/netflow/zebra/log/ospf.log.8.gz
[root at net log]#
but when I check /data1/netflow/zebra/log, I noticed
there is nothing changed to ospf.log, and no
ospflog.gz is created.
Do I miss something with configuration?
thanks
Joe
_________________________________________________________
Do You Yahoo!?
150万曲MP3疯狂搜,带您闯入音乐殿堂
http://music.yisou.com/
美女明星应有尽有,搜遍美图、艳图和酷图
http://image.yisou.com
1G就是1000兆,雅虎电邮自助扩容!
http://cn.rd.yahoo.com/mail_cn/tag/1g/*http://cn.mail.yahoo.com/event/mail_1g/
-------------- next part --------------
_______________________________________________
Zebra mailing list
Zebra at ml.zebra.org
http://ml.zebra.org/mailman/listinfo/zebra
More information about the redhat-list
mailing list