[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Confusion on log rotating



On Sun, 2005-01-30 at 10:48 +0100, Bob Alexander wrote:
> I would like most if not all of my logs to contain just the current day 
> data and then archive them compressed for 7 days back.
> 
> To give an example:
> 
> syslog = today
> 
> syslog.0 = yesterday
> ....
> syslog.6 = a week ago
> 
> and then erase the older than .6
> 
> I must confess that the logrotate stuff got me totally lost :(
> 
> Any help please ?

That's what happens automatically when I installed sysklogd.

$ dir /var/log/syslog*
-rw-r-----  1 root adm 868892 2005-01-30 04:12 /var/log/syslog
-rw-r-----  1 root adm 896752 2005-01-29 06:25 /var/log/syslog.0
-rw-r-----  1 root adm 104385 2005-01-28 06:25 /var/log/syslog.1.gz
-rw-r-----  1 root adm 111704 2005-01-27 06:25 /var/log/syslog.2.gz
-rw-r-----  1 root adm 134459 2005-01-26 06:25 /var/log/syslog.3.gz
-rw-r-----  1 root adm 150227 2005-01-25 06:25 /var/log/syslog.4.gz
-rw-r-----  1 root adm 105431 2005-01-24 06:25 /var/log/syslog.5.gz
-rw-r-----  1 root adm  86099 2005-01-23 06:25 /var/log/syslog.6.gz

-- 
-----------------------------------------------------------------
Ron Johnson, Jr.
Jefferson, LA USA
PGP Key ID 8834C06B I prefer encrypted mail.

"Peace won by compromise is usually a short-lived achievement."
Winfield Scott (?)

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: