View previous topic :: View next topic |
Author |
Message |
PWD -
Joined: 04 Jan 2005 Posts: 34 Location: trying to conquer these fears I thought were GONE
|
Posted: Wed Jul 06, 2005 5:32 pm Post subject: How to clear access.log file |
|
|
I remember seeing a question posted on how to clear the access.log file and can no longer find it using 'search'.
Can anyone tell me how to clear my access.log file the CORRECT way?
Forever Grateful,
PWD _________________ if (my($_GRATITUDE = 0)) {
kick_me(in the head);
} |
|
Back to top |
|
 |
Moxxnixx -
Joined: 21 Jun 2003 Posts: 1226 Location: Florida
|
Posted: Wed Jul 06, 2005 5:45 pm Post subject: |
|
|
Easiest way is to stop the server, delete the file, then restart the server.
A new one will be automatically created.
Aprelium, a "clear log" option within the console would be nice to have. (hint, hint) |
|
Back to top |
|
 |
TRUSTAbyss -
Joined: 29 Oct 2003 Posts: 3752 Location: USA, GA
|
Posted: Wed Jul 06, 2005 6:39 pm Post subject: |
|
|
You could write a batch script that can do this for you. Their is also a batch
script that Anonymoose wrote that can split your log depending on the type
of keyword , I provide an example at the bottom on splitting a log.
Anonymoose's Log Splitting script
http://www.aprelium.com/forum/viewtopic.php?p=28029#28028
Note: You could use keywords such as jul/2005 to split the log by month.
Here's an example of splitting the entire month of july into a new file. :-)
Batch Code Example:
Code: |
cd "C:\Program Files\Abyss Web Server\log"
find /i "jul/2005" access.log > access_jul05.log |
Sincerely , TRUSTpunk
Last edited by TRUSTAbyss on Wed Jul 06, 2005 7:01 pm; edited 1 time in total |
|
Back to top |
|
 |
PWD -
Joined: 04 Jan 2005 Posts: 34 Location: trying to conquer these fears I thought were GONE
|
Posted: Wed Jul 06, 2005 7:00 pm Post subject: |
|
|
Wow! Thank you for the quick and concise responses!
As always,
Forever Grateful,
PWD _________________ if (my($_GRATITUDE = 0)) {
kick_me(in the head);
} |
|
Back to top |
|
 |
|