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

AW: [cobalt-users] Re: RAQ4 web.cache files getting HUGE



wouldn' that affect the domain access statistics? 

-----Ursprüngliche Nachricht-----
Von: cobalt-users-admin@xxxxxxxxxxxxxxx
[mailto:cobalt-users-admin@xxxxxxxxxxxxxxx] Im Auftrag von William J.A.
Brillinger
Gesendet: Dienstag, 4. Mai 2004 16:57
An: cobalt-users@xxxxxxxxxxxxxxx
Betreff: RE: [cobalt-users] Re: RAQ4 web.cache files getting HUGE

At 08:59 AM 04/05/2004 -0500, you wrote:
>With many domains, it isn't practical to manually go through and delete 
>these files. Is there a setting for maximum size or some way to 
>automate the process that would be simple to maintain, as I add and 
>remove domains from the RAQ4?

You can use this script, run from a monthly cron job to clear the logs.

Name the script something like "delete_logs.sh" and make it executable.

Here is the script:
--------------------------
#!/bin/bash
# clear all logs for each site

for URL in $( find /home/sites -type l -maxdepth 1 | sed -e
's/\/home\/sites\///g' ); do
         echo --Removing logs for $URL...
         ls -lah /home/sites/$URL/logs
         rm /home/sites/$URL/logs/*
         echo
done

echo Completed
--------------------------

The script is everything between the --- lines.

Cheers,
- Bill






---------------------------------
William J.A. Brillinger
Precision Design Co.

E-Mail:   mailto:billy@xxxxxxxxxx
Web site: http://www.pdcweb.net


---------------------------------
DO *NOT* SEND EMAIL TO THIS ADDRESS
UNLESS YOU ARE A SPA*MMER: mailto:stmail@xxxxxxxxxx
---------------------------------


_____________________________________
cobalt-users mailing list
cobalt-users@xxxxxxxxxxxxxxx
To subscribe/unsubscribe, or to SEARCH THE ARCHIVES, go to:
http://list.cobalt.com/mailman/listinfo/cobalt-users