* [gentoo-user] "New elog functionality" Log rotation?
@ 2006-06-17 22:14 Richard Broersma Jr
2006-06-17 23:06 ` Teresa and Dale
0 siblings, 1 reply; 3+ messages in thread
From: Richard Broersma Jr @ 2006-06-17 22:14 UTC (permalink / raw
To: gentoo-user
I was wondering if anyone could point me to the conf file to turn on log rotation for my
emerge.log.
Regards,
Richard Broersma Jr.
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [gentoo-user] "New elog functionality" Log rotation?
2006-06-17 22:14 [gentoo-user] "New elog functionality" Log rotation? Richard Broersma Jr
@ 2006-06-17 23:06 ` Teresa and Dale
2006-06-18 9:41 ` Mick
0 siblings, 1 reply; 3+ messages in thread
From: Teresa and Dale @ 2006-06-17 23:06 UTC (permalink / raw
To: gentoo-user
Richard Broersma Jr wrote:
>I was wondering if anyone could point me to the conf file to turn on log rotation for my
>emerge.log.
>
>Regards,
>
>Richard Broersma Jr.
>
>
I use logrotate and it is here.
/etc/logrotate.d
Here is a sample of the file:
> /var/log/http-replicator.log {
> size 10k
> missingok
> copytruncate
> compress
> }
That is for http-replicator and the file is named the same. I guess the
name doesn't matter really.
I'm not sure but I think you need a cron job to run it to. Not real sure.
Hope that helps.
Dale
:-)
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [gentoo-user] "New elog functionality" Log rotation?
2006-06-17 23:06 ` Teresa and Dale
@ 2006-06-18 9:41 ` Mick
0 siblings, 0 replies; 3+ messages in thread
From: Mick @ 2006-06-18 9:41 UTC (permalink / raw
To: gentoo-user
On 17/06/06, Teresa and Dale <teendale@vista-express.com> wrote:
> Richard Broersma Jr wrote:
>
> >I was wondering if anyone could point me to the conf file to turn on log rotation for my
> >emerge.log.
> Here is a sample of the file:
>
> > /var/log/http-replicator.log {
> > size 10k
> > missingok
> > copytruncate
> > compress
> > }
>
>
> That is for http-replicator and the file is named the same. I guess the
> name doesn't matter really.
Well, the name has to reflect *exactly* the path and file you intend to rotate.
> I'm not sure but I think you need a cron job to run it to. Not real sure.
There's two entries in logrotate.conf, a generic one:
==========================
# rotate log files weekly
#monthly
weekly
#daily
==========================
and a per file one, e.g.:
==========================
# when /var/log/user.log gets big
/var/log/user.log
{
rotate 1
monthly
size=1M
}
==========================
Now, if you add logrotate in you /etc/make.conf it will be taken into
account when new apps are created and relevant files and entries will
be added in /etc/logrotate.d by those apps that are logrotate aware.
This is from mine:
==========================
# ls -la /etc/logrotate.d
total 21
drwxr-xr-x 2 root root 184 Jun 4 12:37 .
drwxr-xr-x 73 root root 5144 Jun 18 10:38 ..
-rw-r--r-- 1 root root 0 Jan 21 02:33 .keep
-rw-r--r-- 1 root root 145 Feb 14 19:59 acpid
-rw-r--r-- 1 root root 79 May 6 12:13 hibernate-script
-rw-r----- 1 root root 191 Mar 2 20:26 privoxy
-rw-r--r-- 1 root root 342 Jan 22 20:21 syslog-ng
==========================
Of course, if there is a file created for an application in
/etc/logrotate.d there's no need for a manual entry in
/etc/logrotate.conf as it will be a duplicate and lead to errors which
will invariably appear in /root/dead.letter.
HTH.
--
Regards,
Mick
--
gentoo-user@gentoo.org mailing list
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2006-06-18 9:48 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-17 22:14 [gentoo-user] "New elog functionality" Log rotation? Richard Broersma Jr
2006-06-17 23:06 ` Teresa and Dale
2006-06-18 9:41 ` Mick
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox