Overflowing wtmp

mike at bria.UUCP mike at bria.UUCP
Thu Jan 24 18:17:56 AEST 1991


In article <92 at tdatirv.UUCP> sarima at tdatirv.UUCP (Stanley Friesen) writes:
>I have found that my wtmp file tends to grow without bound.
>This is annoying.  Is there any clean way to trim it, short of the rather
>crude 'cat /dev/null > /etc/wtmp' approach.  (I *do* know about cron,
>I just need to know what to put in it).

To do it with elegance and grace, how 'bout a little script:

mv /usr/adm/wtmp /usr/adm/owtmp
/usr/lib/acct/fwtmp </usr/adm/owtmp | tail | \
/usr/lib/acct/fwtmp -ic >/usr/adm/wtmp

If you don't have fwtmp(1), then send me mail and I'll mail you
back source.
-- 
Michael Stefanik, Systems Engineer (JOAT), Briareus Corporation
UUCP: ...!uunet!bria!mike
--
technoignorami (tek'no-ig'no-ram`i) a group of individuals that are constantly
found to be saying things like "Well, it works on my DOS machine ..."



More information about the Comp.unix.admin mailing list