From: | Harry Putnam <reader@×××××××.com> |
---|---|
To: | gentoo-user@l.g.o |
Subject: | [gentoo-user] [lame logrotate Q] |
Date: | Mon, 21 Dec 2009 02:03:30 |
Message-Id: | 87skb5nqau.fsf@newsguy.com |
1 | Can anyone show me how to write a logrotate rule that will rotate on |
2 | either size or age? |
3 | |
4 | I use some very simple scripting for yrs but don't really see how to |
5 | rotate on more than one condition. |
6 | |
7 | I'd like to rotate a certain log weekly or over 7000k and keep no more |
8 | than 12 rotations for whatever reason. |
9 | |
10 | /var/log/debug.log { |
11 | create 0600 reader wheel |
12 | weekly || size=7000k |
13 | rotate 12 |
14 | postrotate |
15 | /etc/init.d/rsyslog reload > /dev/null 2>&1 || true |
16 | endscript |
17 | } |
18 | |
19 | Is clearly NOT the right way to go. |
20 | |
21 | Any know how to do it? |
Subject | Author |
---|---|
Re: [gentoo-user] [lame logrotate Q] | Dale <rdalek1967@×××××.com> |