squid problem
hi i have squid running in my network the problem i am facing is that once a week the squid service is dead, i checked the log files bu could not figure out what the problem is it gives me the error
squid dead but pid file exist squid error no running copy i have written a script that just moves the compressed log files from the /var/log/squid files to /media/usbdisk the script is as follows i suspect that this problem arises because of the script coz the script runs every week and the next day i get this problem #!/bin/bash cd /var/log/squid YMD="`date +%d%b%y`" echo "------------------------------------------------" >> ~/squid_script/log echo -e "backup of squid logs on $YMD\n" >> ~/squid_script/log echo "------------------------------------------------" >> ~/squid_script/log for file in a*.gz do echo -e "renamed file $file to $file$YMD " >> ~/squid_script/log mv $file /media/usbdisk/squid/access/$file$YMD echo -e "file $file$YMD transfered to /media/usbdisk/squid/access/ \n" >> ~/squid_script/log done for file in c*.gz do echo -e "renamed file $file to $file$YMD " >> ~/squid_script/log mv $file /media/usbdisk/squid/$file$YMD echo -e "file $file$YMD transfered to /media/usbdisk/squid/cache/ \n" >> ~/squid_script/log done for file in s*.gz do echo $file echo -e "renamed file $file to $file$YMD " >> ~/squid_script/log mv $file /media/usbdisk/squid/store/$file$YMD echo -e "file $file$YMD transfered to /media/usbdisk/squid/store/ \n" >> ~/squid_script/log done echo "------------------------------------------------" >> ~/squid_script/log please if anyone find something that is causing the problem in the script please rectify it for me me. |
please help me on this issue
|
Maybe it is because you move the log file so squid dont find it anymore and freezes? Just a gues though . .
|
What is the purpose of your script?
Is this in an aide to reduce disk usage? I would agree withmarkotitel as it seems you move the file to the new location which in effect breaks the connection that squid has to all these logs. I would be guessing but it appears you would have to do something like empty the contents into a file on your USB drive rather than break than connection |
yes your absolutely right, the script is to reduce disk utilization
how do i overcome this , actually i move the files which are rotated weekly not the current log files , even i had the same feeling but was not sure, any way to overcome this as my hard drive gets full with the squid logs weekly |
All times are GMT -5. The time now is 03:40 PM. |