Gentoo Archives: gentoo-user

From: Michael <confabulate@××××××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Logrotate ignores standard log files
Date: Wed, 05 Aug 2020 07:24:15
Message-Id: 2542949.mvXUDI8C0e@lenovo.localdomain
In Reply to: [gentoo-user] Logrotate ignores standard log files by Bertram Scharpf
1 On Monday, 3 August 2020 07:58:03 BST Bertram Scharpf wrote:
2 > Hi,
3 >
4 > I detected that since mid-May my main log files
5 > /var/log/{messages,auth.log,daemon.log,...}
6 > don't get rotated any more.
7 >
8 > I tried to solve this by making an entry in
9 > /etc/logrotate.conf, but that doesn't work.
10 > "maxsize" works, but not "weekly" nor "daily".
11 >
12 > What happened in May and what do I have to try?
13 >
14 > Thanks in advance.
15 >
16 > Bertram
17
18 Is the default cron job there, or did you remove it?
19
20 $ ls -la /etc/cron.daily/logrotate
21 -rwxr-xr-x 1 root root 188 Jun 13 2019 /etc/cron.daily/logrotate
22
23 $ cat /etc/cron.daily/logrotate
24 #!/bin/sh
25
26 /usr/bin/logrotate /etc/logrotate.conf
27 EXITVALUE=$?
28 if [ $EXITVALUE != 0 ]; then
29 /usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]"
30 fi
31 exit $EXITVALUE

Attachments

File name MIME type
signature.asc application/pgp-signature