*BSD News Article 13755


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!elroy.jpl.nasa.gov!swrinde!gatech!usenet.ins.cwru.edu!jake.EEAP.CWRU.Edu!david
From: david@jake.EEAP.CWRU.Edu (David Nerenberg)
Newsgroups: comp.os.386bsd.questions
Subject: Re: Rotating the syslogs
Date: 31 Mar 1993 04:43:42 GMT
Organization: Case Western Reserve University
Lines: 25
Message-ID: <1pb7hv$t1o@usenet.INS.CWRU.Edu>
References: <1p77tt$rq3@usenet.INS.CWRU.Edu> <1993Mar30.194840.5890@sci34hub.sci.com>
NNTP-Posting-Host: jake.eeap.cwru.edu

In article <1993Mar30.194840.5890@sci34hub.sci.com> gary@sci34hub.sci.com (Gary Heston) writes:
>In article <1p77tt$rq3@usenet.INS.CWRU.Edu> david@jake.EEAP.CWRU.Edu (David Nerenberg) writes:
>>I am trying to rotate my syslogs from cron.  The cron side of things
>>is fine.  Fir example, I move messages to messages.OLD and touch a 
>>new messages file.
>
>Don't. Copy messages to messages.OLD, then copy /dev/null into messages.
>
>This leaves the permissions, ownership, and inode number of the messages
>file intact; once copied, you can move messages.OLD any way you want
>without problems.

Nice idea!  I didn't think of that.  I am off to try it....

				Thanks...

					-Dave



-- 
david@elwood.eeap.cwru.edu             David Nerenberg
73107,177 CompuServe                   Electrical Engineering & Applied Physics
NY:  H-516-751-6344                    Case Western Reserve University
     W-516-751-8111                    W-216-368-2982   H-216-754-2085