Regelmäßiger "Absturz" von squid

  • Thread starter Thread starter Managor
  • Start date Start date
M

Managor

Guest
Hallo,

in unserem Betrieb verwenden wir den squid als Proxy-Server. Seit einiger Zeit nun zeigt der squid ein recht seltsames Verhalten auf. Und zwar quittiert er in der Nacht von Donnerstag auf Freitag seinen Dienst, so dass er jeden Freitag morgen neu gestartet werden muss, was auch kein Problem darstellt. Und prinzipiell könnte man sicherlich einen Cronjob einrichten, der das automatisch erledigt, was aber leider nur die Symptome bekämpft und nicht das wesentliche Problem behebt.

Die Logfiles sagen aus, dass der Speicherplatz voll ist - das glaub ich auch gern, nur warum ist kann ich dann einige Stunden später den squid trotzdem wieder starten? Oder ist das ein normales Verhalten?

syslog:
Code:
Dec 14 02:10:39 lachs squid[18811]: diskHandleWrite: FD 13: disk write error: (28) No space left on device
Dec 14 02:10:39 lachs squid[18811]: storeUfsWriteDone: got failure (-6)
Dec 14 02:10:39 lachs squid[18811]: storeSwapOutFileClosed: dirno 1, swapfile 00011579, errflag=-6 ^I(28) No space left on device
Dec 14 02:10:39 lachs squid[18811]: WARNING: Shrinking cache_dir #1 to 1554940 KB
Dec 14 02:10:39 lachs squid[18811]: diskHandleWrite: FD 11: disk write error: (28) No space left on device
Dec 14 02:10:39 lachs squid[18811]: storeDirWriteCleanLogs: Starting...
Dec 14 02:10:39 lachs squid[18811]: storeDirWriteCleanLogs: /home/squid/cache/swap.state.clean: write: (28) No space left on device
Dec 14 02:10:39 lachs squid[18811]: storeDirWriteCleanLogs: Current swap logfile not replaced.
Dec 14 02:10:40 lachs squid[18808]: Squid Parent: child process 18811 exited due to signal 11
Dec 14 02:10:43 lachs squid[18808]: Squid Parent: child process 15917 started
Dec 14 02:10:43 lachs squid[15917]: Starting Squid Cache version 2.4.STABLE6 for i386-debian-linux-gnu...
Dec 14 02:10:43 lachs squid[15917]: Process ID 15917
Dec 14 02:10:43 lachs squid[15917]: With 1024 file descriptors available
Dec 14 02:10:43 lachs squid[15917]: DNS Socket created on FD 5
Dec 14 02:10:43 lachs squid[15917]: Adding nameserver 126.0.0.7 from /etc/resolv.conf
Dec 14 02:10:43 lachs squid[15917]: User-Agent logging is disabled.
Dec 14 02:10:43 lachs squid[15917]: Referer logging is disabled.
Dec 14 02:10:43 lachs squid[15917]: Unlinkd pipe opened on FD 10
Dec 14 02:10:43 lachs squid[15917]: Swap maxSize 2457600 KB, estimated 409600 objects
Dec 14 02:10:43 lachs squid[15917]: Target number of buckets: 20480
Dec 14 02:10:43 lachs squid[15917]: Using 32768 Store buckets
Dec 14 02:10:43 lachs squid[15917]: Max Mem  size: 307200 KB
Dec 14 02:10:43 lachs squid[15917]: Max Swap size: 2457600 KB
Dec 14 02:10:43 lachs squid[15917]: Local cache digest enabled; rebuild/rewrite every 3600/3600 sec
Dec 14 02:10:43 lachs squid[15917]: Rebuilding storage in /var/spool/squid (DIRTY)
Dec 14 02:10:43 lachs squid[15917]: Rebuilding storage in /home/squid/cache (DIRTY)
Dec 14 02:10:43 lachs squid[15917]: Using Least Load store dir selection
Dec 14 02:10:43 lachs squid[15917]: Set Current Directory to /var/spool/squid
Dec 14 02:10:44 lachs squid[15917]: diskHandleWrite: FD 14: disk write error: (28) No space left on device
Dec 14 02:10:44 lachs squid[15917]: storeUfsWriteDone: got failure (-6)
Dec 14 02:10:44 lachs squid[15917]: storeSwapOutFileClosed: dirno 1, swapfile 00000000, errflag=-6 ^I(28) No space left on device
Dec 14 02:10:44 lachs squid[15917]: WARNING: Shrinking cache_dir #1 to 0 KB
Dec 14 02:10:44 lachs squid[15917]: Loaded Icons.
Dec 14 02:10:44 lachs squid[15917]: Accepting HTTP connections at 0.0.0.0, port 3128, FD 14.
Dec 14 02:10:44 lachs squid[15917]: Accepting ICP messages at 0.0.0.0, port 3130, FD 15.
Dec 14 02:10:44 lachs squid[15917]: HTCP Disabled.
Dec 14 02:10:44 lachs squid[15917]: WCCP Disabled.
Dec 14 02:10:44 lachs squid[15917]: Ready to serve requests.
Dec 14 02:10:44 lachs squid[15917]: diskHandleWrite: FD 12: disk write error: (28) No space left on device
Dec 14 02:10:44 lachs squid[15917]: Write failure -- check your disk space and cache.log
Dec 14 02:10:44 lachs squid[18808]: Squid Parent: child process 15917 exited due to signal 6
Dec 14 02:10:47 lachs squid[18808]: Squid Parent: child process 15920 started
Dec 14 02:10:47 lachs squid[15920]: Starting Squid Cache version 2.4.STABLE6 for i386-debian-linux-gnu...
Dec 14 02:10:47 lachs squid[15920]: Process ID 15920
Dec 14 02:10:47 lachs squid[15920]: With 1024 file descriptors available
Dec 14 02:10:47 lachs squid[15920]: DNS Socket created on FD 5
Dec 14 02:10:47 lachs squid[15920]: Adding nameserver 126.0.0.7 from /etc/resolv.conf
Dec 14 02:10:47 lachs squid[15920]: User-Agent logging is disabled.
Dec 14 02:10:47 lachs squid[15920]: Referer logging is disabled.
Dec 14 02:10:47 lachs squid[15920]: Unlinkd pipe opened on FD 10
Dec 14 02:10:47 lachs squid[15920]: Swap maxSize 2457600 KB, estimated 409600 objects
Dec 14 02:10:47 lachs squid[15920]: Target number of buckets: 20480
Dec 14 02:10:47 lachs squid[15920]: Using 32768 Store buckets
Dec 14 02:10:47 lachs squid[15920]: Max Mem  size: 307200 KB
Dec 14 02:10:47 lachs squid[15920]: Max Swap size: 2457600 KB
Dec 14 02:10:47 lachs squid[15920]: Local cache digest enabled; rebuild/rewrite every 3600/3600 sec
Dec 14 02:10:47 lachs squid[15920]: Rebuilding storage in /var/spool/squid (DIRTY)
Dec 14 02:10:47 lachs squid[15920]: Rebuilding storage in /home/squid/cache (DIRTY)
Dec 14 02:10:47 lachs squid[15920]: Using Least Load store dir selection
Dec 14 02:10:47 lachs squid[15920]: Set Current Directory to /var/spool/squid

das wiederholt sich noch zwei/drei mal bis dann mit folgender Meldung abgeschlossen wird:
Code:
Dec 14 02:10:58 lachs squid[18808]: Squid Parent: child process 15929 exited due to signal 6
Dec 14 02:10:58 lachs squid[18808]: Exiting due to repeated, frequent failures

cache.log:
Code:
2007/12/14 02:10:39| diskHandleWrite: FD 13: disk write error: (28) No space left on device
2007/12/14 02:10:39| storeUfsWriteDone: got failure (-6)
2007/12/14 02:10:39| storeSwapOutFileClosed: dirno 1, swapfile 00011579, errflag=-6
        (28) No space left on device
2007/12/14 02:10:39| WARNING: Shrinking cache_dir #1 to 1554940 KB
2007/12/14 02:10:39| diskHandleWrite: FD 11: disk write error: (28) No space left on device
2007/12/14 02:10:39| storeDirWriteCleanLogs: Starting...
2007/12/14 02:10:39| storeDirWriteCleanLogs: /home/squid/cache/swap.state.clean: write: (28) No space left on device
2007/12/14 02:10:39| storeDirWriteCleanLogs: Current swap logfile not replaced.
2007/12/14 02:10:43| Starting Squid Cache version 2.4.STABLE6 for i386-debian-linux-gnu...
2007/12/14 02:10:43| Process ID 15917
2007/12/14 02:10:43| With 1024 file descriptors available
2007/12/14 02:10:43| DNS Socket created on FD 5
2007/12/14 02:10:43| Adding nameserver 126.0.0.7 from /etc/resolv.conf
2007/12/14 02:10:43| User-Agent logging is disabled.
2007/12/14 02:10:43| Referer logging is disabled.
2007/12/14 02:10:43| Unlinkd pipe opened on FD 10
2007/12/14 02:10:43| Swap maxSize 2457600 KB, estimated 409600 objects
2007/12/14 02:10:43| Target number of buckets: 20480
2007/12/14 02:10:43| Using 32768 Store buckets
2007/12/14 02:10:43| Max Mem  size: 307200 KB
2007/12/14 02:10:43| Max Swap size: 2457600 KB
2007/12/14 02:10:43| Local cache digest enabled; rebuild/rewrite every 3600/3600 sec
2007/12/14 02:10:43| Rebuilding storage in /var/spool/squid (DIRTY)
2007/12/14 02:10:43| Rebuilding storage in /home/squid/cache (DIRTY)
2007/12/14 02:10:43| Using Least Load store dir selection
2007/12/14 02:10:43| Set Current Directory to /var/spool/squid
2007/12/14 02:10:43| diskHandleWrite: FD 14: disk write error: (28) No space left on device
2007/12/14 02:10:43| storeUfsWriteDone: got failure (-6)
2007/12/14 02:10:43| storeSwapOutFileClosed: dirno 1, swapfile 00000000, errflag=-6
        (28) No space left on device
2007/12/14 02:10:43| WARNING: Shrinking cache_dir #1 to 0 KB
2007/12/14 02:10:43| Loaded Icons.
2007/12/14 02:10:44| Accepting HTTP connections at 0.0.0.0, port 3128, FD 14.
2007/12/14 02:10:44| Accepting ICP messages at 0.0.0.0, port 3130, FD 15.
2007/12/14 02:10:44| HTCP Disabled.
2007/12/14 02:10:44| WCCP Disabled.
2007/12/14 02:10:44| Ready to serve requests.
2007/12/14 02:10:44| diskHandleWrite: FD 12: disk write error: (28) No space left on device
FATAL: Write failure -- check your disk space and cache.log
Squid Cache (Version 2.4.STABLE6): Terminated abnormally.
CPU Usage: 0.120 seconds = 0.070 user + 0.050 sys
Maximum Resident Size: 0 KB
Page faults with physical i/o: 377
Memory usage for squid via mallinfo():
        total space in arena:    3797 KB
        Ordinary blocks:         3786 KB      2 blks
        Small blocks:               0 KB      0 blks
        Holding blocks:           560 KB      3 blks
        Free Small blocks:          0 KB
        Free Ordinary blocks:      10 KB
        Total in use:            4346 KB 114%
        Total free:                10 KB 0%
 
Ich hab se ein wenig anonymisiert ;)

Code:
cache_mem  300 MB

maximum_object_size 502000 KB
cache_dir ufs /var/spool/squid 700 16 256
cache_dir ufs /home/squid/cache 1700 16 256

log_fqdn on
forwarded_for off

refresh_pattern http://*.windowsupdate.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://office.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://windowsupdate.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://wxpsp2.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://xpsp1.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://w2ksp4.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://download.microsoft.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://download.macromedia.com/ 0 80% 20160 reload-into-ims
refresh_pattern ftp://ftp.nai.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://ftp.software.ibm.com/ 0 80% 20160 reload-into-ims
refresh_pattern http://swcdn.apple.com/ 0 80% 20160 reload-into-ims


request_body_max_size 500 MB
#Examples:
#acl myexample dst_as 1241
#acl password proxy_auth REQUIRED
#
#Defaults:
acl all src 0.0.0.0/0.0.0.0
acl Intranet src 126.0.0.0/255.0.0.0
acl VPN src xxx.xxx.xxx.xxx/255.255.255.0
acl VPNASA src xxx.xxx.xxx.xxx/255.255.255.0
acl VPN2 src 192.168.0.0/255.255.255.0
acl XXNET src xxx.xxx.xxx.xxx/255.255.255.224
acl porn srcdomain "/etc/squid/domains.deny"
acl porn_rev dstdomain "/etc/squid/domains.deny"
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl SSL_ports port 443 563 8090 9090 8443 9000 2222
acl Safe_ports port 80 21 443 563 70 210 1025-65535
acl purge method PURGE
acl CONNECT method CONNECT

#Default configuration:
http_access allow manager localhost
http_access deny manager
http_access allow purge localhost
http_access deny purge
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports

http_access deny porn
http_access deny porn_rev
http_access allow Intranet
http_access allow VPN
http_access allow VPN2
http_access allow VPNASA
http_access allow XXNET
http_access deny all

icp_access allow all

miss_access allow all
cache_mgr <...>

visible_hostname <...>

cachemgr_passwd <...> all
store_avg_object_size 6 KB

# For SVN we need some further HTTP methods
extension_methods REPORT MERGE MKACTIVITY CHECKOUT
 
Back
Top