Usenet comp.unix.tru64 (2000-2013)
 help / color / mirror / Atom feed
From: "Nico Kadel-Garcia" <nkadel@bellatlantic.net>
Subject: Re: trimming wtmp
Date: Wed, 15 Jan 2003 14:36:17 GMT	[thread overview]
Message-ID: <BleV9.33119$%V.9362@nwrddc02.gnilink.net> (raw)
In-Reply-To: hso20b.t55.ln@dadsys2.fuller.local


"Stuart Fuller" <stufuller@usa.net> wrote in message
news:hso20b.t55.ln@dadsys2.fuller.local...
> Nico Kadel-Garcia wrote:
>
> >
> > "Paul Szabo" <psz@maths.usyd.edu.au> wrote in message
> > news:3E2355D6.794B@maths.usyd.edu.au...
> >> Daniel Berger wrote:
> >> > Is there a way to trim wtmp? Mine goes back years and has gotten
huge.
> >>
> >> What we do, yearly, is (at a quiet time):
> >>
> >>   cp -ip /usr/adm/wtmp /usr/adm/wtmp.2002
> >>   echo -n '' > /usr/adm/wtmp
> >>
> >> so the system has a nice, small (empty) file to fill up again.
> >
> > Log rotation is an art form. Take a look at this approach:
> >
> >     mv /usr/adm/wtmp /usr/adm/wtmp.{backup name}
> >     kill -HUP {syslog process ID}
> >
> > This way, you restart the syslog daemon correctly and the data continues
> > to pour into the file descriptor of the original file even in its new
> > location until you restart it.
>
> Umm, does syslog write to /usr/adm/wtmp?  I don't think it does, so I
don't
> understand the purpose of restarting syslog

??? Damn, you're right. Still, moving aside is better.

There's a *reason* log rotation is an art form, each one is slightly
different.




      reply	other threads:[~2003-01-15 14:36 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-13 20:06 trimming wtmp Daniel Berger
2003-01-14  0:12 ` Paul Szabo
2003-01-15  4:28   ` Nico Kadel-Garcia
2003-01-15  4:42     ` Stuart Fuller
2003-01-15 14:36       ` Nico Kadel-Garcia [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox