Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Feb 1998 23:57:22 -0200 (EDT)
From:      Joao Carlos Mendes Luis <jonny@coppe.ufrj.br>
To:        danny@panda.hilink.com.au (Daniel O'Callaghan)
Cc:        jonny@coppe.ufrj.br, freebsd-hackers@FreeBSD.ORG
Subject:   Re: logrotate, a proposal
Message-ID:  <199802110157.XAA18233@gaia.coppe.ufrj.br>
In-Reply-To: <Pine.BSF.3.91.980211095602.294J-100000@panda.hilink.com.au> from Daniel O'Callaghan at "Feb 11, 98 09:59:59 am"

next in thread | previous in thread | raw e-mail | index | archive | help
#define quoting(Daniel O'Callaghan)
// On Wed, 11 Feb 1998, I wrote:

Talking to yourself already ?  :)

// > On Tue, 10 Feb 1998, Joao Carlos Mendes Luis wrote:
// 
// > > Worst, how would I know from the format how to "walk" through the old
// > > logs and select the older one to delete ?  I cannot believe in the file
// > > date for this.
// > 
// > In my bourne shell version, I say 'daily' 'weekly' 'monthly' and 
// > calculate the number of days to keep the logs, based on find(1) and mtime.
// > In a perl version, it walks the directory looking for similarly named 
// > files, and stat(2)s them, looking for files X seconds old, X being 
// > calculated from the number of seconds in a day, and the number of days to 
// > keep the files.

As I said before, I don't like the idea of logrotate messing with file
dates to find the file cicle.  I'd like to play just on names.

// The other possibility is to take expiretime = now - expiryseconds, and
// strftime(3) using expiretime to contruct the name of the file to delete.
// Try for both plain and .gz forms.

expiretime ?

I'm talking about logrotate, not newsyslog.  And haven't we already
finished the discussion that newsyslog should not do cron's job ?

IMHO, logrotate should not be aware of time, at all.  If we find some
way to give strftime() style names, without having to mess with current
or file time, maybe it could be used.  But I think this is not possible.

BTW: -stable cron does not yet has an option to retry running something
it should have run but it could not (for any reason, like machine powered
off).  I don't know if -current already does this, but even if it doesn't,
I think of it as a good idea (hint, hint :) ).  This would break an option
for using fixed time differences in name generation.

					Jonny

PS: I am all against using time references, and we all know you are in
favor of it.  Maybe it's time to listen somebody else.

--
Joao Carlos Mendes Luis			jonny@gta.ufrj.br
+55 21 290-4698				jonny@coppe.ufrj.br
Universidade Federal do Rio de Janeiro	UFRJ/COPPE/CISI
PGP fingerprint: 29 C0 50 B9 B6 3E 58 F2  83 5F E3 26 BF 0F EA 67

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199802110157.XAA18233>