* [gentoo-user] portage summary logs not rotated any more
@ 2015-04-04 19:35 Alexander Kapshuk
2015-04-04 22:18 ` Mick
0 siblings, 1 reply; 10+ messages in thread
From: Alexander Kapshuk @ 2015-04-04 19:35 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 1515 bytes --]
My portage summary logs don't seem to be rotated any more.
ls -lt `pwd`/summary.log*
-rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
/var/log/portage/elog/summary.log
-rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
/var/log/portage/elog/summary.log-20150112
-rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
/var/log/portage/elog/summary.log-20150104.gz
-rw-rw-r-- 1 portage portage 565 Dec 26 20:53
/var/log/portage/elog/summary.log-20141228.gz
-rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
/var/log/portage/elog/summary.log-20141222.gz
grep Messages summary.log | sed '1h;$!d;x;G;q'
>>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET for
package dev-python/reportlab-3.1.8-r2:
>>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST for
package net-print/hplip-3.14.1:
grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
>>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET for
package app-office/libreoffice-4.2.8.2:
>>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET for
package dev-libs/openssl-1.0.1k:
cat /etc/logrotate.d/elog-save-summary
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# Rotate the log created by the save_summary elog module.
/var/log/portage/elog/summary.log {
su portage portage
missingok
nocreate
delaycompress
}
/etc/logrotate.conf:6,8
# rotate log files weekly.
weekly
#daily
What could be wrong here? Or am I misreading something?
Thanks.
[-- Attachment #2: Type: text/html, Size: 1776 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-04 19:35 [gentoo-user] portage summary logs not rotated any more Alexander Kapshuk
@ 2015-04-04 22:18 ` Mick
2015-04-05 5:39 ` Alexander Kapshuk
0 siblings, 1 reply; 10+ messages in thread
From: Mick @ 2015-04-04 22:18 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: Text/Plain, Size: 1876 bytes --]
On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> My portage summary logs don't seem to be rotated any more.
>
> ls -lt `pwd`/summary.log*
> -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> /var/log/portage/elog/summary.log
> -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> /var/log/portage/elog/summary.log-20150112
> -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> /var/log/portage/elog/summary.log-20150104.gz
> -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> /var/log/portage/elog/summary.log-20141228.gz
> -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> /var/log/portage/elog/summary.log-20141222.gz
>
> grep Messages summary.log | sed '1h;$!d;x;G;q'
>
> >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET for
>
> package dev-python/reportlab-3.1.8-r2:
> >>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST for
>
> package net-print/hplip-3.14.1:
>
> grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
>
> >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET for
>
> package app-office/libreoffice-4.2.8.2:
> >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET for
>
> package dev-libs/openssl-1.0.1k:
>
> cat /etc/logrotate.d/elog-save-summary
> # Copyright 1999-2011 Gentoo Foundation
> # Distributed under the terms of the GNU General Public License v2
> # Rotate the log created by the save_summary elog module.
>
> /var/log/portage/elog/summary.log {
> su portage portage
> missingok
> nocreate
> delaycompress
> }
>
> /etc/logrotate.conf:6,8
> # rotate log files weekly.
> weekly
> #daily
>
> What could be wrong here? Or am I misreading something?
>
> Thanks.
Is your logrotate running regularly as expected? What do you get when from:
grep logrotate /var/log/cron.log
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-04 22:18 ` Mick
@ 2015-04-05 5:39 ` Alexander Kapshuk
2015-04-05 7:50 ` Mick
0 siblings, 1 reply; 10+ messages in thread
From: Alexander Kapshuk @ 2015-04-05 5:39 UTC (permalink / raw
To: Gentoo mailing list
[-- Attachment #1: Type: text/plain, Size: 2360 bytes --]
On Sun, Apr 5, 2015 at 1:18 AM, Mick <michaelkintzios@gmail.com> wrote:
> On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> > My portage summary logs don't seem to be rotated any more.
> >
> > ls -lt `pwd`/summary.log*
> > -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> > /var/log/portage/elog/summary.log
> > -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> > /var/log/portage/elog/summary.log-20150112
> > -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> > /var/log/portage/elog/summary.log-20150104.gz
> > -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> > /var/log/portage/elog/summary.log-20141228.gz
> > -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> > /var/log/portage/elog/summary.log-20141222.gz
> >
> > grep Messages summary.log | sed '1h;$!d;x;G;q'
> >
> > >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET for
> >
> > package dev-python/reportlab-3.1.8-r2:
> > >>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST for
> >
> > package net-print/hplip-3.14.1:
> >
> > grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
> >
> > >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET for
> >
> > package app-office/libreoffice-4.2.8.2:
> > >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET for
> >
> > package dev-libs/openssl-1.0.1k:
> >
> > cat /etc/logrotate.d/elog-save-summary
> > # Copyright 1999-2011 Gentoo Foundation
> > # Distributed under the terms of the GNU General Public License v2
> > # Rotate the log created by the save_summary elog module.
> >
> > /var/log/portage/elog/summary.log {
> > su portage portage
> > missingok
> > nocreate
> > delaycompress
> > }
> >
> > /etc/logrotate.conf:6,8
> > # rotate log files weekly.
> > weekly
> > #daily
> >
> > What could be wrong here? Or am I misreading something?
> >
> > Thanks.
>
> Is your logrotate running regularly as expected? What do you get when
> from:
>
> grep logrotate /var/log/cron.log
>
> --
> Regards,
> Mick
>
Thanks for your response.
I'm afraid I don't have the cron logging set up. I should probably go ahead
and do it, shouldn't I?
grep logrotate /var/log/cron.log
grep: /var/log/cron.log: No such file or directory
The cron daemon is running though.
ps auxwww|grep '[c]ron'
root 2418 0.0 0.1 5464 1868 ? Ss 08:33 0:00
/usr/sbin/crond
Thanks.
[-- Attachment #2: Type: text/html, Size: 3365 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 5:39 ` Alexander Kapshuk
@ 2015-04-05 7:50 ` Mick
2015-04-05 13:19 ` Alexander Kapshuk
0 siblings, 1 reply; 10+ messages in thread
From: Mick @ 2015-04-05 7:50 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: Text/Plain, Size: 3039 bytes --]
On Sunday 05 Apr 2015 06:39:31 Alexander Kapshuk wrote:
> On Sun, Apr 5, 2015 at 1:18 AM, Mick <michaelkintzios@gmail.com> wrote:
> > On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> > > My portage summary logs don't seem to be rotated any more.
> > >
> > > ls -lt `pwd`/summary.log*
> > > -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> > > /var/log/portage/elog/summary.log
> > > -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> > > /var/log/portage/elog/summary.log-20150112
> > > -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> > > /var/log/portage/elog/summary.log-20150104.gz
> > > -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> > > /var/log/portage/elog/summary.log-20141228.gz
> > > -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> > > /var/log/portage/elog/summary.log-20141222.gz
> > >
> > > grep Messages summary.log | sed '1h;$!d;x;G;q'
> > >
> > > >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET for
> > >
> > > package dev-python/reportlab-3.1.8-r2:
> > > >>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST for
> > >
> > > package net-print/hplip-3.14.1:
> > >
> > > grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
> > >
> > > >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET for
> > >
> > > package app-office/libreoffice-4.2.8.2:
> > > >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET for
> > >
> > > package dev-libs/openssl-1.0.1k:
> > >
> > > cat /etc/logrotate.d/elog-save-summary
> > > # Copyright 1999-2011 Gentoo Foundation
> > > # Distributed under the terms of the GNU General Public License v2
> > > # Rotate the log created by the save_summary elog module.
> > >
> > > /var/log/portage/elog/summary.log {
> > >
> > > su portage portage
> > > missingok
> > > nocreate
> > > delaycompress
> > >
> > > }
> > >
> > > /etc/logrotate.conf:6,8
> > > # rotate log files weekly.
> > > weekly
> > > #daily
> > >
> > > What could be wrong here? Or am I misreading something?
> > >
> > > Thanks.
> >
> > Is your logrotate running regularly as expected? What do you get when
> >
> > from:
> > grep logrotate /var/log/cron.log
> >
> > --
> > Regards,
> > Mick
>
> Thanks for your response.
>
> I'm afraid I don't have the cron logging set up. I should probably go ahead
> and do it, shouldn't I?
>
> grep logrotate /var/log/cron.log
> grep: /var/log/cron.log: No such file or directory
>
> The cron daemon is running though.
>
> ps auxwww|grep '[c]ron'
> root 2418 0.0 0.1 5464 1868 ? Ss 08:33 0:00
> /usr/sbin/crond
>
> Thanks.
Ah! I must have set this up myself. In /etc/syslog-ng/syslog-ng.conf I have
among other settings:
destination cron { file("/var/log/cron.log"); };
filter f_cron { facility(cron); };
log { source(src); filter(f_cron); destination(cron); };
This is not necessary though. You can search /var/log/messages for logrotate.
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 7:50 ` Mick
@ 2015-04-05 13:19 ` Alexander Kapshuk
2015-04-05 14:36 ` Mick
0 siblings, 1 reply; 10+ messages in thread
From: Alexander Kapshuk @ 2015-04-05 13:19 UTC (permalink / raw
To: Gentoo mailing list
[-- Attachment #1: Type: text/plain, Size: 6566 bytes --]
On Sun, Apr 5, 2015 at 10:50 AM, Mick <michaelkintzios@gmail.com> wrote:
> On Sunday 05 Apr 2015 06:39:31 Alexander Kapshuk wrote:
> > On Sun, Apr 5, 2015 at 1:18 AM, Mick <michaelkintzios@gmail.com> wrote:
> > > On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> > > > My portage summary logs don't seem to be rotated any more.
> > > >
> > > > ls -lt `pwd`/summary.log*
> > > > -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> > > > /var/log/portage/elog/summary.log
> > > > -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> > > > /var/log/portage/elog/summary.log-20150112
> > > > -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> > > > /var/log/portage/elog/summary.log-20150104.gz
> > > > -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> > > > /var/log/portage/elog/summary.log-20141228.gz
> > > > -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> > > > /var/log/portage/elog/summary.log-20141222.gz
> > > >
> > > > grep Messages summary.log | sed '1h;$!d;x;G;q'
> > > >
> > > > >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET for
> > > >
> > > > package dev-python/reportlab-3.1.8-r2:
> > > > >>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST
> for
> > > >
> > > > package net-print/hplip-3.14.1:
> > > >
> > > > grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
> > > >
> > > > >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET for
> > > >
> > > > package app-office/libreoffice-4.2.8.2:
> > > > >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET for
> > > >
> > > > package dev-libs/openssl-1.0.1k:
> > > >
> > > > cat /etc/logrotate.d/elog-save-summary
> > > > # Copyright 1999-2011 Gentoo Foundation
> > > > # Distributed under the terms of the GNU General Public License v2
> > > > # Rotate the log created by the save_summary elog module.
> > > >
> > > > /var/log/portage/elog/summary.log {
> > > >
> > > > su portage portage
> > > > missingok
> > > > nocreate
> > > > delaycompress
> > > >
> > > > }
> > > >
> > > > /etc/logrotate.conf:6,8
> > > > # rotate log files weekly.
> > > > weekly
> > > > #daily
> > > >
> > > > What could be wrong here? Or am I misreading something?
> > > >
> > > > Thanks.
> > >
> > > Is your logrotate running regularly as expected? What do you get when
> > >
> > > from:
> > > grep logrotate /var/log/cron.log
> > >
> > > --
> > > Regards,
> > > Mick
> >
> > Thanks for your response.
> >
> > I'm afraid I don't have the cron logging set up. I should probably go
> ahead
> > and do it, shouldn't I?
> >
> > grep logrotate /var/log/cron.log
> > grep: /var/log/cron.log: No such file or directory
> >
> > The cron daemon is running though.
> >
> > ps auxwww|grep '[c]ron'
> > root 2418 0.0 0.1 5464 1868 ? Ss 08:33 0:00
> > /usr/sbin/crond
> >
> > Thanks.
>
> Ah! I must have set this up myself. In /etc/syslog-ng/syslog-ng.conf I
> have
> among other settings:
>
> destination cron { file("/var/log/cron.log"); };
> filter f_cron { facility(cron); };
> log { source(src); filter(f_cron); destination(cron); };
>
> This is not necessary though. You can search /var/log/messages for
> logrotate.
>
> --
> Regards,
> Mick
>
Understood. Thanks.
Messages doesn't seem to have anything out of the ordinary to say about
logrotate though.
sed '/logrotate/!d' /var/log/messages
Jan 13 17:50:02 localhost run-crons[7443]: (root) CMD
(/etc/cron.daily/logrotate)
Jan 14 18:00:02 localhost run-crons[4576]: (root) CMD
(/etc/cron.daily/logrotate)
Jan 15 18:10:02 localhost run-crons[1692]: (root) CMD
(/etc/cron.daily/logrotate)
Jan 16 18:20:01 localhost run-crons[4448]: (root) CMD
(/etc/cron.daily/logrotate)
An observation I've made, is that my log rotation seems to have effected
all other logs in /var/log as well. It seems to have stopped working around
January this year.
ls -lt /var/log/messages*
-rw------- 1 root root 9986127 Apr 5 16:10 /var/log/messages
-rw------- 1 root root 173843 Jan 12 10:20 /var/log/messages-20150112.gz
-rw------- 1 root root 277867 Jan 4 22:00 /var/log/messages-20150104.gz
-rw------- 1 root root 132157 Dec 28 20:30 /var/log/messages-20141228.gz
-rw------- 1 root root 142911 Dec 22 19:30 /var/log/messages-20141222.gz
sed '1h;$!d;x;G;q' /var/log/messages
Jan 12 10:20:02 localhost syslog-ng[2321]: Configuration reload request
received, reloading configuration;
Apr 5 16:10:01 box1 CROND[2265]: pam_unix(crond:session): session closed
for user root
ls -lt /var/log/|sort -k9
total 16064
drwxr-xr-x 2 root root 4096 Feb 15 00:42 ConsoleKit
-rw-r--r-- 1 root sasha 33914 Apr 5 08:34 Xorg.0.log
-rw-r--r-- 1 root sasha 34515 Apr 4 23:17 Xorg.0.log.old
-rw-r--r-- 1 root sasha 28290 Sep 22 2014 Xorg.1.log
drwxr-xr-x 2 root root 4096 Jan 12 10:20 chrony
drwxr-xr-x 2 root root 4096 Feb 7 12:26 cups
-rw-r----- 1 root root 50378 Apr 5 08:33 dmesg
-rw-rw---- 1 portage portage 6268 Apr 1 19:35 emerge-fetch.log
-rw-rw---- 1 portage portage 2687784 Apr 5 09:04 emerge.log
-rw-r--r-- 1 root root 292292 Apr 5 08:34 lastlog
-rw------- 1 root root 9986127 Apr 5 16:10 messages
-rw------- 1 root root 142911 Dec 22 19:30 messages-20141222.gz
-rw------- 1 root root 132157 Dec 28 20:30 messages-20141228.gz
-rw------- 1 root root 277867 Jan 4 22:00 messages-20150104.gz
-rw------- 1 root root 173843 Jan 12 10:20 messages-20150112.gz
drwxr-xr-x 2 root root 4096 Dec 22 2013 openconnect
-rw-r--r-- 1 root root 188788 Apr 5 08:34 pm-powersave.log
-rw-r--r-- 1 root root 4837 Sep 30 2014
pm-powersave.log-20141001.gz
-rw-r--r-- 1 root root 785 Oct 31 07:35
pm-powersave.log-20141101.gz
-rw-r--r-- 1 root root 848 Dec 1 17:00
pm-powersave.log-20141201.gz
-rw-r--r-- 1 root root 67852 Jan 1 18:34 pm-powersave.log-20150101
drwxrwsr-x 3 portage portage 4096 Oct 29 2013 portage
-rw-r--r-- 1 root root 660096 Apr 5 08:33 rc.log
-rw-r--r-- 1 root root 2705 Dec 22 17:37 rc.log-20141222.gz
-rw-r--r-- 1 root root 2493 Dec 28 08:33 rc.log-20141228.gz
-rw-r--r-- 1 root root 4003 Jan 4 19:51 rc.log-20150104.gz
-rw-r--r-- 1 root root 3026 Jan 12 08:57 rc.log-20150112.gz
drwxrwx--- 2 root portage 4096 Oct 29 2013 sandbox
-rw------- 1 root root 64064 Apr 5 08:34 tallylog
-rw-rw-r-- 1 root utmp 1792896 Apr 5 10:30 wtmp
-rw-rw-r-- 1 root utmp 32029 Dec 25 17:04 wtmp-20141225.gz
Any input on how to fix this would be much appreciated.
[-- Attachment #2: Type: text/html, Size: 8610 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 13:19 ` Alexander Kapshuk
@ 2015-04-05 14:36 ` Mick
2015-04-05 15:31 ` Alexander Kapshuk
0 siblings, 1 reply; 10+ messages in thread
From: Mick @ 2015-04-05 14:36 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: Text/Plain, Size: 7897 bytes --]
On Sunday 05 Apr 2015 14:19:16 Alexander Kapshuk wrote:
> On Sun, Apr 5, 2015 at 10:50 AM, Mick <michaelkintzios@gmail.com> wrote:
> > On Sunday 05 Apr 2015 06:39:31 Alexander Kapshuk wrote:
> > > On Sun, Apr 5, 2015 at 1:18 AM, Mick <michaelkintzios@gmail.com> wrote:
> > > > On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> > > > > My portage summary logs don't seem to be rotated any more.
> > > > >
> > > > > ls -lt `pwd`/summary.log*
> > > > > -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> > > > > /var/log/portage/elog/summary.log
> > > > > -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> > > > > /var/log/portage/elog/summary.log-20150112
> > > > > -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> > > > > /var/log/portage/elog/summary.log-20150104.gz
> > > > > -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> > > > > /var/log/portage/elog/summary.log-20141228.gz
> > > > > -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> > > > > /var/log/portage/elog/summary.log-20141222.gz
> > > > >
> > > > > grep Messages summary.log | sed '1h;$!d;x;G;q'
> > > > >
> > > > > >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET
> > > > > >>> for
> > > > >
> > > > > package dev-python/reportlab-3.1.8-r2:
> > > > > >>> Messages generated by process 4080 on 2015-04-03 19:47:54 EEST
> >
> > for
> >
> > > > > package net-print/hplip-3.14.1:
> > > > >
> > > > > grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
> > > > >
> > > > > >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET
> > > > > >>> for
> > > > >
> > > > > package app-office/libreoffice-4.2.8.2:
> > > > > >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET
> > > > > >>> for
> > > > >
> > > > > package dev-libs/openssl-1.0.1k:
> > > > >
> > > > > cat /etc/logrotate.d/elog-save-summary
> > > > > # Copyright 1999-2011 Gentoo Foundation
> > > > > # Distributed under the terms of the GNU General Public License v2
> > > > > # Rotate the log created by the save_summary elog module.
> > > > >
> > > > > /var/log/portage/elog/summary.log {
> > > > >
> > > > > su portage portage
> > > > > missingok
> > > > > nocreate
> > > > > delaycompress
> > > > >
> > > > > }
> > > > >
> > > > > /etc/logrotate.conf:6,8
> > > > > # rotate log files weekly.
> > > > > weekly
> > > > > #daily
> > > > >
> > > > > What could be wrong here? Or am I misreading something?
> > > > >
> > > > > Thanks.
> > > >
> > > > Is your logrotate running regularly as expected? What do you get
> > > > when
> > > >
> > > > from:
> > > > grep logrotate /var/log/cron.log
> > > >
> > > > --
> > > > Regards,
> > > > Mick
> > >
> > > Thanks for your response.
> > >
> > > I'm afraid I don't have the cron logging set up. I should probably go
> >
> > ahead
> >
> > > and do it, shouldn't I?
> > >
> > > grep logrotate /var/log/cron.log
> > > grep: /var/log/cron.log: No such file or directory
> > >
> > > The cron daemon is running though.
> > >
> > > ps auxwww|grep '[c]ron'
> > > root 2418 0.0 0.1 5464 1868 ? Ss 08:33 0:00
> > > /usr/sbin/crond
> > >
> > > Thanks.
> >
> > Ah! I must have set this up myself. In /etc/syslog-ng/syslog-ng.conf I
> > have
> > among other settings:
> >
> > destination cron { file("/var/log/cron.log"); };
> > filter f_cron { facility(cron); };
> > log { source(src); filter(f_cron); destination(cron); };
> >
> > This is not necessary though. You can search /var/log/messages for
> > logrotate.
> >
> > --
> > Regards,
> > Mick
>
> Understood. Thanks.
>
> Messages doesn't seem to have anything out of the ordinary to say about
> logrotate though.
> sed '/logrotate/!d' /var/log/messages
> Jan 13 17:50:02 localhost run-crons[7443]: (root) CMD
> (/etc/cron.daily/logrotate)
> Jan 14 18:00:02 localhost run-crons[4576]: (root) CMD
> (/etc/cron.daily/logrotate)
> Jan 15 18:10:02 localhost run-crons[1692]: (root) CMD
> (/etc/cron.daily/logrotate)
> Jan 16 18:20:01 localhost run-crons[4448]: (root) CMD
> (/etc/cron.daily/logrotate)
>
> An observation I've made, is that my log rotation seems to have effected
> all other logs in /var/log as well. It seems to have stopped working around
> January this year.
>
> ls -lt /var/log/messages*
> -rw------- 1 root root 9986127 Apr 5 16:10 /var/log/messages
> -rw------- 1 root root 173843 Jan 12 10:20 /var/log/messages-20150112.gz
> -rw------- 1 root root 277867 Jan 4 22:00 /var/log/messages-20150104.gz
> -rw------- 1 root root 132157 Dec 28 20:30 /var/log/messages-20141228.gz
> -rw------- 1 root root 142911 Dec 22 19:30 /var/log/messages-20141222.gz
>
> sed '1h;$!d;x;G;q' /var/log/messages
> Jan 12 10:20:02 localhost syslog-ng[2321]: Configuration reload request
> received, reloading configuration;
> Apr 5 16:10:01 box1 CROND[2265]: pam_unix(crond:session): session closed
> for user root
>
> ls -lt /var/log/|sort -k9
> total 16064
> drwxr-xr-x 2 root root 4096 Feb 15 00:42 ConsoleKit
> -rw-r--r-- 1 root sasha 33914 Apr 5 08:34 Xorg.0.log
> -rw-r--r-- 1 root sasha 34515 Apr 4 23:17 Xorg.0.log.old
> -rw-r--r-- 1 root sasha 28290 Sep 22 2014 Xorg.1.log
> drwxr-xr-x 2 root root 4096 Jan 12 10:20 chrony
> drwxr-xr-x 2 root root 4096 Feb 7 12:26 cups
> -rw-r----- 1 root root 50378 Apr 5 08:33 dmesg
> -rw-rw---- 1 portage portage 6268 Apr 1 19:35 emerge-fetch.log
> -rw-rw---- 1 portage portage 2687784 Apr 5 09:04 emerge.log
> -rw-r--r-- 1 root root 292292 Apr 5 08:34 lastlog
> -rw------- 1 root root 9986127 Apr 5 16:10 messages
> -rw------- 1 root root 142911 Dec 22 19:30 messages-20141222.gz
> -rw------- 1 root root 132157 Dec 28 20:30 messages-20141228.gz
> -rw------- 1 root root 277867 Jan 4 22:00 messages-20150104.gz
> -rw------- 1 root root 173843 Jan 12 10:20 messages-20150112.gz
> drwxr-xr-x 2 root root 4096 Dec 22 2013 openconnect
> -rw-r--r-- 1 root root 188788 Apr 5 08:34 pm-powersave.log
> -rw-r--r-- 1 root root 4837 Sep 30 2014
> pm-powersave.log-20141001.gz
> -rw-r--r-- 1 root root 785 Oct 31 07:35
> pm-powersave.log-20141101.gz
> -rw-r--r-- 1 root root 848 Dec 1 17:00
> pm-powersave.log-20141201.gz
> -rw-r--r-- 1 root root 67852 Jan 1 18:34 pm-powersave.log-20150101
> drwxrwsr-x 3 portage portage 4096 Oct 29 2013 portage
> -rw-r--r-- 1 root root 660096 Apr 5 08:33 rc.log
> -rw-r--r-- 1 root root 2705 Dec 22 17:37 rc.log-20141222.gz
> -rw-r--r-- 1 root root 2493 Dec 28 08:33 rc.log-20141228.gz
> -rw-r--r-- 1 root root 4003 Jan 4 19:51 rc.log-20150104.gz
> -rw-r--r-- 1 root root 3026 Jan 12 08:57 rc.log-20150112.gz
> drwxrwx--- 2 root portage 4096 Oct 29 2013 sandbox
> -rw------- 1 root root 64064 Apr 5 08:34 tallylog
> -rw-rw-r-- 1 root utmp 1792896 Apr 5 10:30 wtmp
> -rw-rw-r-- 1 root utmp 32029 Dec 25 17:04 wtmp-20141225.gz
>
> Any input on how to fix this would be much appreciated.
It seems to me that logrotate stopped rotating your logs back in Jan. Did you
change something in its configuration back then?
This is what I have in /etc/cron.daily/logrotate:
================================================
#!/bin/sh
/usr/sbin/logrotate /etc/logrotate.conf
EXITVALUE=$?
if [ $EXITVALUE != 0 ]; then
/usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]"
fi
exit 0
=================================================
PS. I leave previous message content untrimmed in case someone else spots
something of significance on what you have posted to date and can chime in
with a solution.
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 14:36 ` Mick
@ 2015-04-05 15:31 ` Alexander Kapshuk
2015-04-05 15:49 ` Mick
2015-04-05 16:49 ` Alex Corkwell
0 siblings, 2 replies; 10+ messages in thread
From: Alexander Kapshuk @ 2015-04-05 15:31 UTC (permalink / raw
To: Gentoo mailing list
[-- Attachment #1: Type: text/plain, Size: 16822 bytes --]
On Sun, Apr 5, 2015 at 5:36 PM, Mick <michaelkintzios@gmail.com> wrote:
> On Sunday 05 Apr 2015 14:19:16 Alexander Kapshuk wrote:
> > On Sun, Apr 5, 2015 at 10:50 AM, Mick <michaelkintzios@gmail.com> wrote:
> > > On Sunday 05 Apr 2015 06:39:31 Alexander Kapshuk wrote:
> > > > On Sun, Apr 5, 2015 at 1:18 AM, Mick <michaelkintzios@gmail.com>
> wrote:
> > > > > On Saturday 04 Apr 2015 20:35:31 Alexander Kapshuk wrote:
> > > > > > My portage summary logs don't seem to be rotated any more.
> > > > > >
> > > > > > ls -lt `pwd`/summary.log*
> > > > > > -rw-rw-r-- 1 portage portage 96581 Apr 3 19:47
> > > > > > /var/log/portage/elog/summary.log
> > > > > > -rw-rw-r-- 1 portage portage 5927 Jan 10 07:50
> > > > > > /var/log/portage/elog/summary.log-20150112
> > > > > > -rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
> > > > > > /var/log/portage/elog/summary.log-20150104.gz
> > > > > > -rw-rw-r-- 1 portage portage 565 Dec 26 20:53
> > > > > > /var/log/portage/elog/summary.log-20141228.gz
> > > > > > -rw-rw-r-- 1 portage portage 1842 Dec 22 17:52
> > > > > > /var/log/portage/elog/summary.log-20141222.gz
> > > > > >
> > > > > > grep Messages summary.log | sed '1h;$!d;x;G;q'
> > > > > >
> > > > > > >>> Messages generated by process 3399 on 2015-01-13 17:47:47 EET
> > > > > > >>> for
> > > > > >
> > > > > > package dev-python/reportlab-3.1.8-r2:
> > > > > > >>> Messages generated by process 4080 on 2015-04-03 19:47:54
> EEST
> > >
> > > for
> > >
> > > > > > package net-print/hplip-3.14.1:
> > > > > >
> > > > > > grep Messages summary.log-20150112 | sed '1h;$!d;x;G;q'
> > > > > >
> > > > > > >>> Messages generated by process 2637 on 2015-01-04 22:02:00 EET
> > > > > > >>> for
> > > > > >
> > > > > > package app-office/libreoffice-4.2.8.2:
> > > > > > >>> Messages generated by process 3483 on 2015-01-10 07:50:04 EET
> > > > > > >>> for
> > > > > >
> > > > > > package dev-libs/openssl-1.0.1k:
> > > > > >
> > > > > > cat /etc/logrotate.d/elog-save-summary
> > > > > > # Copyright 1999-2011 Gentoo Foundation
> > > > > > # Distributed under the terms of the GNU General Public License
> v2
> > > > > > # Rotate the log created by the save_summary elog module.
> > > > > >
> > > > > > /var/log/portage/elog/summary.log {
> > > > > >
> > > > > > su portage portage
> > > > > > missingok
> > > > > > nocreate
> > > > > > delaycompress
> > > > > >
> > > > > > }
> > > > > >
> > > > > > /etc/logrotate.conf:6,8
> > > > > > # rotate log files weekly.
> > > > > > weekly
> > > > > > #daily
> > > > > >
> > > > > > What could be wrong here? Or am I misreading something?
> > > > > >
> > > > > > Thanks.
> > > > >
> > > > > Is your logrotate running regularly as expected? What do you get
> > > > > when
> > > > >
> > > > > from:
> > > > > grep logrotate /var/log/cron.log
> > > > >
> > > > > --
> > > > > Regards,
> > > > > Mick
> > > >
> > > > Thanks for your response.
> > > >
> > > > I'm afraid I don't have the cron logging set up. I should probably go
> > >
> > > ahead
> > >
> > > > and do it, shouldn't I?
> > > >
> > > > grep logrotate /var/log/cron.log
> > > > grep: /var/log/cron.log: No such file or directory
> > > >
> > > > The cron daemon is running though.
> > > >
> > > > ps auxwww|grep '[c]ron'
> > > > root 2418 0.0 0.1 5464 1868 ? Ss 08:33 0:00
> > > > /usr/sbin/crond
> > > >
> > > > Thanks.
> > >
> > > Ah! I must have set this up myself. In /etc/syslog-ng/syslog-ng.conf I
> > > have
> > > among other settings:
> > >
> > > destination cron { file("/var/log/cron.log"); };
> > > filter f_cron { facility(cron); };
> > > log { source(src); filter(f_cron); destination(cron); };
> > >
> > > This is not necessary though. You can search /var/log/messages for
> > > logrotate.
> > >
> > > --
> > > Regards,
> > > Mick
> >
> > Understood. Thanks.
> >
> > Messages doesn't seem to have anything out of the ordinary to say about
> > logrotate though.
> > sed '/logrotate/!d' /var/log/messages
> > Jan 13 17:50:02 localhost run-crons[7443]: (root) CMD
> > (/etc/cron.daily/logrotate)
> > Jan 14 18:00:02 localhost run-crons[4576]: (root) CMD
> > (/etc/cron.daily/logrotate)
> > Jan 15 18:10:02 localhost run-crons[1692]: (root) CMD
> > (/etc/cron.daily/logrotate)
> > Jan 16 18:20:01 localhost run-crons[4448]: (root) CMD
> > (/etc/cron.daily/logrotate)
> >
> > An observation I've made, is that my log rotation seems to have effected
> > all other logs in /var/log as well. It seems to have stopped working
> around
> > January this year.
> >
> > ls -lt /var/log/messages*
> > -rw------- 1 root root 9986127 Apr 5 16:10 /var/log/messages
> > -rw------- 1 root root 173843 Jan 12 10:20 /var/log/messages-20150112.gz
> > -rw------- 1 root root 277867 Jan 4 22:00 /var/log/messages-20150104.gz
> > -rw------- 1 root root 132157 Dec 28 20:30 /var/log/messages-20141228.gz
> > -rw------- 1 root root 142911 Dec 22 19:30 /var/log/messages-20141222.gz
> >
> > sed '1h;$!d;x;G;q' /var/log/messages
> > Jan 12 10:20:02 localhost syslog-ng[2321]: Configuration reload request
> > received, reloading configuration;
> > Apr 5 16:10:01 box1 CROND[2265]: pam_unix(crond:session): session closed
> > for user root
> >
> > ls -lt /var/log/|sort -k9
> > total 16064
> > drwxr-xr-x 2 root root 4096 Feb 15 00:42 ConsoleKit
> > -rw-r--r-- 1 root sasha 33914 Apr 5 08:34 Xorg.0.log
> > -rw-r--r-- 1 root sasha 34515 Apr 4 23:17 Xorg.0.log.old
> > -rw-r--r-- 1 root sasha 28290 Sep 22 2014 Xorg.1.log
> > drwxr-xr-x 2 root root 4096 Jan 12 10:20 chrony
> > drwxr-xr-x 2 root root 4096 Feb 7 12:26 cups
> > -rw-r----- 1 root root 50378 Apr 5 08:33 dmesg
> > -rw-rw---- 1 portage portage 6268 Apr 1 19:35 emerge-fetch.log
> > -rw-rw---- 1 portage portage 2687784 Apr 5 09:04 emerge.log
> > -rw-r--r-- 1 root root 292292 Apr 5 08:34 lastlog
> > -rw------- 1 root root 9986127 Apr 5 16:10 messages
> > -rw------- 1 root root 142911 Dec 22 19:30 messages-20141222.gz
> > -rw------- 1 root root 132157 Dec 28 20:30 messages-20141228.gz
> > -rw------- 1 root root 277867 Jan 4 22:00 messages-20150104.gz
> > -rw------- 1 root root 173843 Jan 12 10:20 messages-20150112.gz
> > drwxr-xr-x 2 root root 4096 Dec 22 2013 openconnect
> > -rw-r--r-- 1 root root 188788 Apr 5 08:34 pm-powersave.log
> > -rw-r--r-- 1 root root 4837 Sep 30 2014
> > pm-powersave.log-20141001.gz
> > -rw-r--r-- 1 root root 785 Oct 31 07:35
> > pm-powersave.log-20141101.gz
> > -rw-r--r-- 1 root root 848 Dec 1 17:00
> > pm-powersave.log-20141201.gz
> > -rw-r--r-- 1 root root 67852 Jan 1 18:34
> pm-powersave.log-20150101
> > drwxrwsr-x 3 portage portage 4096 Oct 29 2013 portage
> > -rw-r--r-- 1 root root 660096 Apr 5 08:33 rc.log
> > -rw-r--r-- 1 root root 2705 Dec 22 17:37 rc.log-20141222.gz
> > -rw-r--r-- 1 root root 2493 Dec 28 08:33 rc.log-20141228.gz
> > -rw-r--r-- 1 root root 4003 Jan 4 19:51 rc.log-20150104.gz
> > -rw-r--r-- 1 root root 3026 Jan 12 08:57 rc.log-20150112.gz
> > drwxrwx--- 2 root portage 4096 Oct 29 2013 sandbox
> > -rw------- 1 root root 64064 Apr 5 08:34 tallylog
> > -rw-rw-r-- 1 root utmp 1792896 Apr 5 10:30 wtmp
> > -rw-rw-r-- 1 root utmp 32029 Dec 25 17:04 wtmp-20141225.gz
> >
> > Any input on how to fix this would be much appreciated.
>
> It seems to me that logrotate stopped rotating your logs back in Jan. Did
> you
> change something in its configuration back then?
>
> This is what I have in /etc/cron.daily/logrotate:
> ================================================
> #!/bin/sh
>
> /usr/sbin/logrotate /etc/logrotate.conf
> EXITVALUE=$?
> if [ $EXITVALUE != 0 ]; then
> /usr/bin/logger -t logrotate "ALERT exited abnormally with
> [$EXITVALUE]"
> fi
> exit 0
> =================================================
>
>
> PS. I leave previous message content untrimmed in case someone else spots
> something of significance on what you have posted to date and can chime in
> with a solution.
>
> --
> Regards,
> Mick
>
The contents of my logrotate cron job file seems to be the same as yours.
cat /etc/cron.daily/logrotate
#!/bin/sh
/usr/sbin/logrotate /etc/logrotate.conf
EXITVALUE=$?
if [ $EXITVALUE != 0 ]; then
/usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]"
fi
exit 0
On further troubleshooting, I found that running logrotate in debugging
mode did not reveal anything amiss with the logrotate configuration as far
as I could tell.
/usr/sbin/logrotate -dv /etc/logrotate.conf
reading config file /etc/logrotate.conf
including /etc/logrotate.d
reading config file chrony
reading config file consolekit
reading config file elog-save-summary
reading config file openconnect
reading config file openrc
reading config file pm-utils
reading config file rsyncd
reading config file syslog-ng
Handling 10 logs
rotating pattern: /var/log/chrony/*.log weekly (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/chrony/measurements.log
log needs rotating
considering log /var/log/chrony/statistics.log
log needs rotating
considering log /var/log/chrony/tracking.log
log needs rotating
rotating log /var/log/chrony/measurements.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
rotating log /var/log/chrony/statistics.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
rotating log /var/log/chrony/tracking.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
renaming /var/log/chrony/measurements.log to
/var/log/chrony/measurements.log-20150405
creating new /var/log/chrony/measurements.log mode = 0644 uid = 0 gid = 0
renaming /var/log/chrony/statistics.log to
/var/log/chrony/statistics.log-20150405
creating new /var/log/chrony/statistics.log mode = 0644 uid = 0 gid = 0
renaming /var/log/chrony/tracking.log to
/var/log/chrony/tracking.log-20150405
creating new /var/log/chrony/tracking.log mode = 0644 uid = 0 gid = 0
running postrotate script
running script with arg /var/log/chrony/*.log : "
PASSWORD=`awk '$1 ~ /^1$/ {print $2; exit}'
/etc/chrony/chrony.keys`
cat << EOF | /usr/bin/chronyc | sed '/^200 OK$/d'
password $PASSWORD
cyclelogs
EOF
"
compressing log with: /bin/gzip
removing old log /var/log/chrony/measurements.log-20141222.gz
compressing log with: /bin/gzip
removing old log /var/log/chrony/statistics.log-20141222.gz
compressing log with: /bin/gzip
removing old log /var/log/chrony/tracking.log-20141222.gz
rotating pattern: /var/log/ConsoleKit/history monthly (6 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/ConsoleKit/history
log does not need rotating
rotating pattern: /var/log/portage/elog/summary.log weekly (4 rotations)
empty log files are not rotated, old logs are removed
switching euid to 250 and egid to 250
considering log /var/log/portage/elog/summary.log
log needs rotating
rotating log /var/log/portage/elog/summary.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
compressing log with: /bin/gzip
renaming /var/log/portage/elog/summary.log to
/var/log/portage/elog/summary.log-20150405
switching euid to 0 and egid to 0
rotating pattern: /var/log/openconnect/*/* 5242880 bytes (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/openconnect/*/*
rotating pattern: /var/log/rc.log weekly (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/rc.log
log needs rotating
rotating log /var/log/rc.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
renaming /var/log/rc.log to /var/log/rc.log-20150405
creating new /var/log/rc.log mode = 0644 uid = 0 gid = 0
compressing log with: /bin/gzip
removing old log /var/log/rc.log-20141222.gz
rotating pattern: /var/log/pm-suspend.log /var/log/pm-powersave.log
monthly (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/pm-suspend.log
log /var/log/pm-suspend.log does not exist -- skipping
considering log /var/log/pm-powersave.log
log needs rotating
rotating log /var/log/pm-powersave.log, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
compressing log with: /bin/gzip
renaming /var/log/pm-powersave.log to /var/log/pm-powersave.log-20150405
creating new /var/log/pm-powersave.log mode = 0644 uid = 0 gid = 0
rotating pattern: /var/log/rsync.log 1048576 bytes (7 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/rsync.log
log /var/log/rsync.log does not exist -- skipping
rotating pattern: /var/log/messages weekly (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/messages
log needs rotating
rotating log /var/log/messages, log->rotateCount is 4
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
renaming /var/log/messages to /var/log/messages-20150405
creating new /var/log/messages mode = 0600 uid = 0 gid = 0
running postrotate script
running script with arg /var/log/messages : "
/etc/init.d/syslog-ng reload > /dev/null 2>&1 || true
"
compressing log with: /bin/gzip
removing old log /var/log/messages-20141222.gz
rotating pattern: /var/log/wtmp monthly (1 rotations)
empty log files are not rotated, only log files >= 1048576 bytes are
rotated, old logs are removed
considering log /var/log/wtmp
log needs rotating
rotating log /var/log/wtmp, log->rotateCount is 1
dateext suffix '-20150405'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
renaming /var/log/wtmp to /var/log/wtmp-20150405
creating new /var/log/wtmp mode = 0664 uid = 0 gid = 406
compressing log with: /bin/gzip
removing old log /var/log/wtmp-20141225.gz
rotating pattern: /var/log/btmp monthly (1 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/btmp
log /var/log/btmp does not exist -- skipping
I then went ahead and ran logrotate by hand, which resulted in the
following output:
/usr/sbin/logrotate /etc/logrotate.conf
501 Not authorised --- Reply not authenticated
501 Not authorised --- Reply not authenticated
# echo $?
0
As a result, log-rotation did work:
ls -lt /var/log/*{log,[0-9],gz} /var/log/portage/elog/summary.log* | sort
-k9
-rw-r--r-- 1 root sasha 33914 Apr 5 08:34 /var/log/Xorg.0.log
-rw-r--r-- 1 root sasha 28290 Sep 22 2014 /var/log/Xorg.1.log
-rw-rw---- 1 portage portage 6268 Apr 1 19:35 /var/log/emerge-fetch.log
-rw-rw---- 1 portage portage 2687784 Apr 5 09:04 /var/log/emerge.log
-rw-r--r-- 1 root root 292292 Apr 5 08:34 /var/log/lastlog
-rw------- 1 root root 132157 Dec 28 20:30
/var/log/messages-20141228.gz
-rw------- 1 root root 277867 Jan 4 22:00
/var/log/messages-20150104.gz
-rw------- 1 root root 173843 Jan 12 10:20
/var/log/messages-20150112.gz
-rw------- 1 root root 1678586 Apr 5 18:10
/var/log/messages-20150405.gz
-rw-r--r-- 1 root root 0 Apr 5 18:14 /var/log/pm-powersave.log
-rw-r--r-- 1 root root 785 Oct 31 07:35
/var/log/pm-powersave.log-20141101.gz
-rw-r--r-- 1 root root 848 Dec 1 17:00
/var/log/pm-powersave.log-20141201.gz
-rw-r--r-- 1 root root 870 Jan 1 18:34
/var/log/pm-powersave.log-20150101.gz
-rw-r--r-- 1 root root 188788 Apr 5 08:34
/var/log/pm-powersave.log-20150405
-rw-rw-r-- 1 portage portage 565 Dec 26 20:53
/var/log/portage/elog/summary.log-20141228.gz
-rw-rw-r-- 1 portage portage 2281 Jan 4 21:14
/var/log/portage/elog/summary.log-20150104.gz
-rw-rw-r-- 1 portage portage 775 Jan 10 07:50
/var/log/portage/elog/summary.log-20150112.gz
-rw-rw-r-- 1 portage portage 96928 Apr 5 08:44
/var/log/portage/elog/summary.log-20150405
-rw-r--r-- 1 root root 0 Apr 5 18:14 /var/log/rc.log
-rw-r--r-- 1 root root 2493 Dec 28 08:33
/var/log/rc.log-20141228.gz
-rw-r--r-- 1 root root 4003 Jan 4 19:51
/var/log/rc.log-20150104.gz
-rw-r--r-- 1 root root 3026 Jan 12 08:57
/var/log/rc.log-20150112.gz
-rw-r--r-- 1 root root 16974 Apr 5 08:33
/var/log/rc.log-20150405.gz
-rw------- 1 root root 64064 Apr 5 08:34 /var/log/tallylog
-rw-rw-r-- 1 root utmp 54903 Apr 5 10:30 /var/log/wtmp-20150405.gz
I guess I have to figure out what the error message shown below is all
about:
501 Not authorised --- Reply not authenticated
[-- Attachment #2: Type: text/html, Size: 20976 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 15:31 ` Alexander Kapshuk
@ 2015-04-05 15:49 ` Mick
2015-04-05 16:49 ` Alex Corkwell
1 sibling, 0 replies; 10+ messages in thread
From: Mick @ 2015-04-05 15:49 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: Text/Plain, Size: 422 bytes --]
On Sunday 05 Apr 2015 16:31:43 Alexander Kapshuk wrote:
> I guess I have to figure out what the error message shown below is all
> about:
> 501 Not authorised --- Reply not authenticated
This is most likely chrony:
http://www.gossamer-threads.com/lists/gentoo/user/289231
If logrotate works as expected when run manually, the question remains why
cronjobs don't run more regularly.
--
Regards,
Mick
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 15:31 ` Alexander Kapshuk
2015-04-05 15:49 ` Mick
@ 2015-04-05 16:49 ` Alex Corkwell
2015-04-05 17:21 ` Alexander Kapshuk
1 sibling, 1 reply; 10+ messages in thread
From: Alex Corkwell @ 2015-04-05 16:49 UTC (permalink / raw
To: gentoo-user
[-- Attachment #1: Type: text/plain, Size: 3722 bytes --]
On Sun, Apr 05, 2015 at 06:31:43PM +0300, Alexander Kapshuk wrote:
> On Sun, Apr 5, 2015 at 5:36 PM, Mick <michaelkintzios@gmail.com> wrote:
>
> On Sunday 05 Apr 2015 14:19:16 Alexander Kapshuk wrote:
> > On Sun, Apr 5, 2015 at 10:50 AM, Mick <michaelkintzios@gmail.com> wrote:
> > An observation I've made, is that my log rotation seems to have effected
> > all other logs in /var/log as well. It seems to have stopped working
> around
> > January this year.
> >
> > ls -lt /var/log/messages*
> > -rw------- 1 root root 9986127 Apr 5 16:10 /var/log/messages
> > -rw------- 1 root root 173843 Jan 12 10:20 /var/log/messages-20150112.gz
> > -rw------- 1 root root 277867 Jan 4 22:00 /var/log/messages-20150104.gz
> > -rw------- 1 root root 132157 Dec 28 20:30 /var/log/messages-20141228.gz
> > -rw------- 1 root root 142911 Dec 22 19:30 /var/log/messages-20141222.gz
>
> It seems to me that logrotate stopped rotating your logs back in Jan. Did
> you
> change something in its configuration back then?
>
> This is what I have in /etc/cron.daily/logrotate:
> ================================================
> #!/bin/sh
>
> /usr/sbin/logrotate /etc/logrotate.conf
> EXITVALUE=$?
> if [ $EXITVALUE != 0 ]; then
> /usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]
> "
> fi
> exit 0
> =================================================
> I then went ahead and ran logrotate by hand, which resulted in the following
> output:
>
> /usr/sbin/logrotate /etc/logrotate.conf
> 501 Not authorised --- Reply not authenticated
> 501 Not authorised --- Reply not authenticated
> # echo $?
> 0
>
> I guess I have to figure out what the error message shown below is all about:
> 501 Not authorised --- Reply not authenticated
>
>
I don't know about the "501 Not authorised", but I remember having a
similar issue with logrotate not running beginning around the same time
(the last rotated log was the week of 20141221). I can't remember
exactly what I did, but I believe around then Gentoo (and my system)
switched from vixie-cron to cronie as default. If I remember correctly,
it was anacron that caused the problem.
Take a look at these lines from the default (at least, on my system) for
/etc/crontab:
# check scripts in cron.hourly, cron.daily, cron.weekly and cron.monthly
# if anacron is not present
59 * * * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
/var/spool/cron/lastrun/cron.hourly
9 3 * * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
/var/spool/cron/lastrun/cron.daily
19 4 * * 6 root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
/var/spool/cron/lastrun/cron.weekly
29 5 1 * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
/var/spool/cron/lastrun/cron.monthly
*/10 * * * * root [ ! -x /etc/cron.hourly/0anacron ] && { test -x
/usr/sbin/run-crons && /usr/sbin/run-crons ; }
Essentially, cron.{hourly,daily,weekly,monthly} only get run if
/etc/cron.hourly/0anacron is not executable. On my system, if I remember
correctly, /etc/cron.hourly/0anacron had the executable bit set after I
emerged cronie, but I never set up anacron. I don't know if it properly
runs all the cron.* scripts regularly by default, but after a quick
"chmod -x /etc/cron.hourly/0anacron" logrotate returned to running
regularly.
I really don't know what's going on with the 501, but I hope that helps
with getting it to run regularly (at least, unless you actually know how
to use anacron, in which you probably know whether or not this makes
some sense).
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 1026 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [gentoo-user] portage summary logs not rotated any more
2015-04-05 16:49 ` Alex Corkwell
@ 2015-04-05 17:21 ` Alexander Kapshuk
0 siblings, 0 replies; 10+ messages in thread
From: Alexander Kapshuk @ 2015-04-05 17:21 UTC (permalink / raw
To: Gentoo mailing list
[-- Attachment #1: Type: text/plain, Size: 3928 bytes --]
On Sun, Apr 5, 2015 at 7:49 PM, Alex Corkwell <i.am.the.memory@gmail.com>
wrote:
> On Sun, Apr 05, 2015 at 06:31:43PM +0300, Alexander Kapshuk wrote:
> > On Sun, Apr 5, 2015 at 5:36 PM, Mick <michaelkintzios@gmail.com> wrote:
> >
> > On Sunday 05 Apr 2015 14:19:16 Alexander Kapshuk wrote:
> > > On Sun, Apr 5, 2015 at 10:50 AM, Mick <michaelkintzios@gmail.com>
> wrote:
> > > An observation I've made, is that my log rotation seems to have
> effected
> > > all other logs in /var/log as well. It seems to have stopped
> working
> > around
> > > January this year.
> > >
> > > ls -lt /var/log/messages*
> > > -rw------- 1 root root 9986127 Apr 5 16:10 /var/log/messages
> > > -rw------- 1 root root 173843 Jan 12 10:20
> /var/log/messages-20150112.gz
> > > -rw------- 1 root root 277867 Jan 4 22:00
> /var/log/messages-20150104.gz
> > > -rw------- 1 root root 132157 Dec 28 20:30
> /var/log/messages-20141228.gz
> > > -rw------- 1 root root 142911 Dec 22 19:30
> /var/log/messages-20141222.gz
> >
> > It seems to me that logrotate stopped rotating your logs back in
> Jan. Did
> > you
> > change something in its configuration back then?
> >
> > This is what I have in /etc/cron.daily/logrotate:
> > ================================================
> > #!/bin/sh
> >
> > /usr/sbin/logrotate /etc/logrotate.conf
> > EXITVALUE=$?
> > if [ $EXITVALUE != 0 ]; then
> > /usr/bin/logger -t logrotate "ALERT exited abnormally with
> [$EXITVALUE]
> > "
> > fi
> > exit 0
> > =================================================
> > I then went ahead and ran logrotate by hand, which resulted in the
> following
> > output:
> >
> > /usr/sbin/logrotate /etc/logrotate.conf
> > 501 Not authorised --- Reply not authenticated
> > 501 Not authorised --- Reply not authenticated
> > # echo $?
> > 0
> >
> > I guess I have to figure out what the error message shown below is all
> about:
> > 501 Not authorised --- Reply not authenticated
> >
> >
>
> I don't know about the "501 Not authorised", but I remember having a
> similar issue with logrotate not running beginning around the same time
> (the last rotated log was the week of 20141221). I can't remember
> exactly what I did, but I believe around then Gentoo (and my system)
> switched from vixie-cron to cronie as default. If I remember correctly,
> it was anacron that caused the problem.
>
> Take a look at these lines from the default (at least, on my system) for
> /etc/crontab:
>
> # check scripts in cron.hourly, cron.daily, cron.weekly and cron.monthly
> # if anacron is not present
> 59 * * * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
> /var/spool/cron/lastrun/cron.hourly
> 9 3 * * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
> /var/spool/cron/lastrun/cron.daily
> 19 4 * * 6 root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
> /var/spool/cron/lastrun/cron.weekly
> 29 5 1 * * root [ ! -x /etc/cron.hourly/0anacron ] && rm -f
> /var/spool/cron/lastrun/cron.monthly
> */10 * * * * root [ ! -x /etc/cron.hourly/0anacron ] && { test -x
> /usr/sbin/run-crons && /usr/sbin/run-crons ; }
>
> Essentially, cron.{hourly,daily,weekly,monthly} only get run if
> /etc/cron.hourly/0anacron is not executable. On my system, if I remember
> correctly, /etc/cron.hourly/0anacron had the executable bit set after I
> emerged cronie, but I never set up anacron. I don't know if it properly
> runs all the cron.* scripts regularly by default, but after a quick
> "chmod -x /etc/cron.hourly/0anacron" logrotate returned to running
> regularly.
>
> I really don't know what's going on with the 501, but I hope that helps
> with getting it to run regularly (at least, unless you actually know how
> to use anacron, in which you probably know whether or not this makes
> some sense).
>
That was it. Thanks a lot for the tip.
[-- Attachment #2: Type: text/html, Size: 5096 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2015-04-05 17:22 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-04 19:35 [gentoo-user] portage summary logs not rotated any more Alexander Kapshuk
2015-04-04 22:18 ` Mick
2015-04-05 5:39 ` Alexander Kapshuk
2015-04-05 7:50 ` Mick
2015-04-05 13:19 ` Alexander Kapshuk
2015-04-05 14:36 ` Mick
2015-04-05 15:31 ` Alexander Kapshuk
2015-04-05 15:49 ` Mick
2015-04-05 16:49 ` Alex Corkwell
2015-04-05 17:21 ` Alexander Kapshuk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox