[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cobalt-users] RE: Clearing Web Log



Jeff,

I do not believe a simple rm will not suffice for the following reason:

Apache will continue writing to the logfile at the same offset as before the
logfile moved. This results in a new logfile being created which is just as
big
as the old one, but it now contains thousands (or millions) of null
characters.

The correct procedure is to move the logfile, then signal Apache to tell it to
reopen the logfiles.
Apache is signaled using the SIGHUP (-1) signal. e.g. 

mv access_log access_log.old
kill -1 `cat httpd.pid` 

Note: httpd.pid is a file containing the process id of the Apache httpd
daemon,
Apache saves this in the same directory as the log files.
Many people use this method to replace (and backup) their logfiles on a
nightly
or weekly basis.

The above information was taken directly from the apach.org website.  Please
review the following URL for verification:

        http://www.apache.org/docs-1.2/misc/howto.html#logreset

Bram,

        Type 'man rm' at the command line.  This should tell you all you will
ever want to know about the command 'rm'.

-Jason L. Youmans
-Sys Admin
-Sage Web Design
-hostmaster@xxxxxxxxxxxxxxxxx


At 09:15 AM 5/20/00 -0700, you wrote:
>Okay Jeff...I give... what's rm?????  (nobaloney, I really don't have a clue)
>
>> Thanks for the help on Web Logs for a Raq2..."Analog" looks great.
>>
>> Now, what's the easiest way to get rid of the 19 meg log file I no longer
>> need...
>
>rm ?????
>
>Jeff
>
>
>
>_______________________________________________
>cobalt-users mailing list
>cobalt-users@xxxxxxxxxxxxxxx
>To Subscribe or Unsubscribe, please go to:
>http://list.cobalt.com/mailman/listinfo/cobalt-users
>