SQUID PARANDO

1. SQUID PARANDO

eduardo
cprvendas

(usa Conectiva)

Enviado em 24/01/2009 - 08:12h

Olá, a tds do VOL.
Estou com um problema meio eskisito aki na empresa. Colokei um CL10 com squid + iptables, tava funcionando belezinha. Dê uns dias pra cá, começou a travar o squid do nada, o msn funciona! mas os sites NAO!

Se eu der um "service squid restart" volta a funcionar! Deve ser algo com a cache, mas não sei onde mexer e tenho medo de dar pau em tudo!
Obs: ele volta a funcionar sozinho depois de um tempo.. Muito estranho!

Se alguem tiver alguma dica, eu agradeço...
Obrigado.

CACHE.LOG
2009/01/21 15:40:16| Starting Squid Cache version 2.5.STABLE5 for i686-pc-linux-gnu...
2009/01/21 15:40:16| Process ID 3565
2009/01/21 15:40:16| With 1024 file descriptors available
2009/01/21 15:40:16| Performing DNS Tests...
2009/01/21 15:40:16| Successful DNS name lookup tests...
2009/01/21 15:40:16| DNS Socket created at 0.0.0.0, port 32768, FD 4
2009/01/21 15:40:16| Adding nameserver 200.175.5.139 from /etc/resolv.conf
2009/01/21 15:40:16| Adding nameserver 200.175.89.139 from /etc/resolv.conf
2009/01/21 15:40:16| Unlinkd pipe opened on FD 9
2009/01/21 15:40:16| Swap maxSize 102400 KB, estimated 7876 objects
2009/01/21 15:40:16| Target number of buckets: 393
2009/01/21 15:40:16| Using 8192 Store buckets
2009/01/21 15:40:16| Max Mem size: 8192 KB
2009/01/21 15:40:16| Max Swap size: 102400 KB
2009/01/21 15:40:16| Rebuilding storage in /var/cache/squid (DIRTY)
2009/01/21 15:40:16| Using Least Load store dir selection
2009/01/21 15:40:16| Current Directory is /
2009/01/21 15:40:16| Loaded Icons.
2009/01/21 15:40:17| Accepting HTTP connections at 0.0.0.0, port 3128, FD 11.
2009/01/21 15:40:17| Accepting ICP messages at 0.0.0.0, port 3130, FD 12.
2009/01/21 15:40:17| Accepting HTCP messages on port 4827, FD 13.
2009/01/21 15:40:17| Accepting SNMP messages on port 3401, FD 14.
2009/01/21 15:40:17| WCCP Disabled.
2009/01/21 15:40:17| Pinger socket opened on FD 16
2009/01/21 15:40:17| Ready to serve requests.
2009/01/21 15:40:17| Store rebuilding is 33.1% complete
2009/01/21 15:40:17| Done reading /var/cache/squid swaplog (12362 entries)
2009/01/21 15:40:17| Finished rebuilding storage from disk.
2009/01/21 15:40:17| 11082 Entries scanned
2009/01/21 15:40:17| 0 Invalid entries.
2009/01/21 15:40:17| 0 With invalid flags.
2009/01/21 15:40:17| 11082 Objects loaded.
2009/01/21 15:40:17| 0 Objects expired.
2009/01/21 15:40:17| 0 Objects cancelled.
2009/01/21 15:40:17| 0 Duplicate URLs purged.
2009/01/21 15:40:17| 0 Swapfile clashes avoided.
2009/01/21 15:40:17| Took 0.9 seconds (12898.2 objects/sec).
2009/01/21 15:40:17| Beginning Validation Procedure
2009/01/21 15:40:17| Completed Validation Procedure
2009/01/21 15:40:17| Validated 11082 Entries
2009/01/21 15:40:17| store_swap_size = 139000k
2009/01/21 15:40:18| storeLateRelease: released 0 objects
2009/01/21 15:40:18| WARNING: Disk space over limit: 138628 KB > 102400 KB
2009/01/21 15:40:19| icmpRecv: recv: (111) Connection refused
2009/01/21 15:40:19| Closing Pinger socket on FD 16
2009/01/21 15:40:29| WARNING: Disk space over limit: 129536 KB > 102400 KB
2009/01/21 15:40:40| WARNING: Disk space over limit: 123468 KB > 102400 KB
2009/01/21 15:40:51| WARNING: Disk space over limit: 119004 KB > 102400 KB
2009/01/21 15:41:03| WARNING: Disk space over limit: 110388 KB > 102400 KB
2009/01/21 15:42:25| sslReadServer: FD 56: read failure: (104) Connection reset by peer
2009/01/21 15:42:26| sslReadServer: FD 54: read failure: (104) Connection reset by peer
2009/01/21 15:42:30| sslReadServer: FD 62: read failure: (104) Connection reset by peer
2009/01/21 15:43:25| sslReadServer: FD 27: read failure: (104) Connection reset by peer
2009/01/21 15:58:08| WARNING: 1 swapin MD5 mismatches
2009/01/21 16:07:13| urlParse: Illegal character in hostname '%25257bd30c1661-cdaf-11d0-8a3e-00c04fc9e26e%25257d'
2009/01/21 16:12:42| sslReadServer: FD 35: read failure: (104) Connection reset by peer
2009/01/21 16:12:42| sslReadServer: FD 31: read failure: (104) Connection reset by peer
2009/01/21 16:17:49| sslReadServer: FD 30: read failure: (104) Connection reset by peer
2009/01/21 16:17:49| sslReadServer: FD 35: read failure: (104) Connection reset by peer
2009/01/21 16:17:56| sslReadServer: FD 26: read failure: (104) Connection reset by peer
2009/01/21 16:17:56| sslReadServer: FD 32: read failure: (104) Connection reset by peer
2009/01/21 16:20:17| NETDB state saved; 0 entries, 0 msec
2009/01/21 17:01:57| NETDB state saved; 0 entries, 0 msec
2009/01/21 17:27:30| sslReadServer: FD 38: read failure: (104) Connection reset by peer
2009/01/21 17:27:43| sslReadServer: FD 42: read failure: (104) Connection reset by peer
2009/01/21 17:41:26| sslReadServer: FD 30: read failure: (104) Connection reset by peer
2009/01/21 17:41:34| sslReadServer: FD 29: read failure: (104) Connection reset by peer
2009/01/21 17:43:15| sslReadServer: FD 28: read failure: (104) Connection reset by peer
2009/01/21 17:43:24| sslReadServer: FD 30: read failure: (104) Connection reset by peer
2009/01/21 17:56:32| NETDB state saved; 0 entries, 0 msec
2009/01/21 18:56:03| NETDB state saved; 0 entries, 589 msec
2009/01/21 19:00:37| sslReadServer: FD 30: read failure: (104) Connection reset by peer
2009/01/21 19:00:39| sslReadServer: FD 65: read failure: (104) Connection reset by peer
2009/01/21 19:00:40| sslReadServer: FD 68: read failure: (104) Connection reset by peer
2009/01/21 19:00:41| sslReadServer: FD 67: read failure: (104) Connection reset by peer
2009/01/21 19:00:43| sslReadServer: FD 60: read failure: (104) Connection reset by peer
2009/01/21 19:00:43| sslReadServer: FD 62: read failure: (104) Connection reset by peer
2009/01/21 19:43:18| sslReadServer: FD 21: read failure: (104) Connection reset by peer
2009/01/21 19:54:14| NETDB state saved; 0 entries, 727 msec
2009/01/21 21:07:30| NETDB state saved; 0 entries, 0 msec
2009/01/21 22:10:14| NETDB state saved; 0 entries, 0 msec
2009/01/21 22:52:17| NETDB state saved; 0 entries, 0 msec
2009/01/21 23:10:14| sslReadServer: FD 20: read failure: (104) Connection reset by peer
2009/01/22 03:57:53| NETDB state saved; 0 entries, 839 msec
2009/01/22 05:02:36| NETDB state saved; 0 entries, 620 msec
2009/01/22 05:53:25| NETDB state saved; 0 entries, 0 msec
2009/01/22 06:56:33| NETDB state saved; 0 entries, 584 msec
2009/01/22 07:41:04| sslReadServer: FD 38: read failure: (104) Connection reset by peer
2009/01/22 07:41:17| sslReadServer: FD 35: read failure: (104) Connection reset by peer
2009/01/22 07:43:38| NETDB state saved; 0 entries, 0 msec
2009/01/22 07:51:08| sslReadServer: FD 34: read failure: (104) Connection reset by peer
2009/01/22 08:04:28| urlParse: Illegal character in hostname 'smartcobran%e7a'
2009/01/22 08:15:48| sslReadServer: FD 41: read failure: (104) Connection reset by peer
2009/01/22 08:28:07| NETDB state saved; 0 entries, 0 msec
2009/01/22 08:31:11| sslReadServer: FD 36: read failure: (104) Connection reset by peer
2009/01/22 08:59:22| sslReadServer: FD 34: read failure: (104) Connection reset by peer
2009/01/22 09:40:34| NETDB state saved; 0 entries, 0 msec
2009/01/22 09:51:16| sslReadServer: FD 25: read failure: (104) Connection reset by peer
2009/01/22 10:02:18| sslReadServer: FD 43: read failure: (104) Connection reset by peer
2009/01/22 10:56:44| NETDB state saved; 0 entries, 0 msec
2009/01/22 11:02:54| sslReadServer: FD 47: read failure: (104) Connection reset by peer
2009/01/22 11:41:01| sslReadServer: FD 32: read failure: (104) Connection reset by peer
2009/01/22 11:41:23| sslReadServer: FD 36: read failure: (104) Connection reset by peer
2009/01/22 12:04:11| NETDB state saved; 0 entries, 0 msec
2009/01/22 12:29:03| urlParse: Illegal character in hostname '%25257bd30c1661-cdaf-11d0-8a3e-00c04fc9e26e%25257d'
2009/01/22 12:44:12| NETDB state saved; 0 entries, 32 msec
2009/01/22 12:48:04| sslReadServer: FD 29: read failure: (104) Connection reset by peer
2009/01/22 12:51:44| sslReadServer: FD 26: read failure: (104) Connection reset by peer
2009/01/22 12:53:07| sslReadServer: FD 26: read failure: (104) Connection reset by peer
2009/01/22 13:06:01| sslReadServer: FD 39: read failure: (104) Connection reset by peer
2009/01/22 13:33:24| sslReadServer: FD 28: read failure: (104) Connection reset by peer
2009/01/22 13:41:02| sslReadServer: FD 29: read failure: (104) Connection reset by peer
2009/01/22 13:41:10| sslReadServer: FD 33: read failure: (104) Connection reset by peer
2009/01/22 13:47:40| NETDB state saved; 0 entries, 40 msec
2009/01/22 13:52:42| sslReadServer: FD 44: read failure: (104) Connection reset by peer
2009/01/22 14:28:46| NETDB state saved; 0 entries, 19 msec



  


2. Re: SQUID PARANDO

Jefferson Diego
Diede

(usa Debian)

Enviado em 24/01/2009 - 10:44h

Vendo este seu log, recomendo resetar o cache. Pelo que sei, no Squid 2.5, o "WARNING: Disk space over limit", está relacionado à arquivos grandes no cache e um cache pequeno para estes.
Pelo que entendi, seu cache é de apenas 100MB, e isto é de fato muito pouco para uma empresa. Pior se aí o pessoal fizer downloads de programas e músicas.
Tente extender este cache para pelo menos 2 GB de início.

E... por estas duas linhas:

2009/01/21 15:40:16| Adding nameserver 200.175.5.139 from /etc/resolv.conf
2009/01/21 15:40:16| Adding nameserver 200.175.89.139 from /etc/resolv.conf

Se o squid não estiver satisfatoriamente rápido, tente adicionar um servidor DNS para aumentar a velocidade da resolução de nomes.


3. Re: SQUID PARANDO

Matheus Soveral
matheusoveral

(usa Ubuntu)

Enviado em 24/01/2009 - 10:48h

Se for no cache, é no paramentro cache_dir:

cache_dir ufs /var/spool/squid 100 16 256

UFS: É o sistema de arquivos que será usado.
/var/spool/squid: Diretório usado pela cache.
100: Referente ao tamanho em MB a ser usado pela cache.
16: Referente aos diretórios que serão criados no primeiro nível.
256: Referente aos diretórios que serão criados no segundo nível.

Cara tenho um script de limpeza de cache se te ajudar, posso te enviar...


4. Re: SQUID PARANDO

jroberto
lordsnc

(usa Mandriva)

Enviado em 24/01/2009 - 10:54h

eu tambem estou tendo problemas com o squid...

eu instalei e configurei so q quando tento coloccar ele para rodar aparece a seguinte mensssagem de erro..

* Restarting Squid HTTP proxy squid 2009/01/24 01:24:46| aclParseIpData: WARNING: Netmask masks away part of the specified IP in '192.168.0.1/24'

PS:so não dá erro se eu trocar o numero de ip 198.168.0.1 para 198.168.1.0

só q o Ip eth0(rede local) é 198.168.0.1 e não 198.168.1.0 ..

oq faço?


5. Re: SQUID PARANDO

Matheus Soveral
matheusoveral

(usa Ubuntu)

Enviado em 24/01/2009 - 11:02h

lordsnc;

Como estam suas acls; posta ai para poder-mos analizar:

Se vc que o range? Pode deixar assim:

acl redeinterna src 192.168.0.0/24


6. Re: SQUID PARANDO

jroberto
lordsnc

(usa Mandriva)

Enviado em 24/01/2009 - 11:09h

abaixo segue o meu squid.conf


*****************************************
http_port 3129
visible_hostname servidorx-marimba

cache_mem 64 MB
maximum_object_size_in_memory 64 KB
maximum_object_size 750 MB
minimum_object_size 0 KB
cache_swap_low 90
cache_swap_high 95
cache_dir ufs /var/spool/squid 2048 16 256
cache_access_log /var/log/squid/access.log
refresh_pattern ^ftp: 15 20% 2280
refresh_pattern ^gopher: 15 0% 2280
refresh_pattern . 15 20% 2280

acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl SSL_ports port 443 563
acl Safe_ports port 21 80 443 563 70 210 280 488 59 777 901 1025-65535
acl purge method PURGE
acl CONNECT method CONNECT

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


acl redeloca src 192.168.0.1/24
http_access allow localhost
http_access allow redelocal
http_access deny all

************************************
ai está


7. Re: SQUID PARANDO

Matheus Soveral
matheusoveral

(usa Ubuntu)

Enviado em 24/01/2009 - 11:33h

Arquivo modificado

##################################

http_port 3129
visible_hostname servidorx-marimba

cache_mem 64 MB
maximum_object_size_in_memory 64 KB
maximum_object_size 750 MB
minimum_object_size 0 KB
cache_swap_low 90
cache_swap_high 95
cache_dir ufs /var/spool/squid 2048 16 256
cache_access_log /var/log/squid/access.log
refresh_pattern ^ftp: 15 20% 2280
refresh_pattern ^gopher: 15 0% 2280
refresh_pattern . 15 20% 2280

acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1/255.255.255.255
acl SSL_ports port 443 563
acl Safe_ports port 21 80 443 563 70 210 280 488 59 777 901 1025-65535
acl purge method PURGE
acl CONNECT method CONNECT

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

acl redelocal src 192.168.0.0/24
http_access allow localhost
http_access allow redelocal
http_access deny all



8. Re: SQUID PARANDO

jroberto
lordsnc

(usa Mandriva)

Enviado em 24/01/2009 - 11:43h

pronto fiz as modificações q vc me indincou...

mas ainda assim não abro pagina de internet nas outras maquinas..

ja coloquei o o ip da eth0 servidor como proxy e nada....



9. Arquivos de Log

Emerson Léo Ferreira
erminhoferreira

(usa Debian)

Enviado em 30/01/2009 - 23:10h

Cara..

tive problema similar... do nada o squid parava.

No meu caso eram os arquivos de log que estavam gigantes. De uma olhada na pasta /var/log/squid se existem arquivos muito grandes. (access.log, store.log, etc..) Dê um ls -la -h e verifique o tamanho dos mesmos.
Se vc utiliza o Sarg para monitorar os acessos, gere os relatorios do SARG e depois pode apagar os arquivos de log sem dó... rsrs
Se for este o caso fique atento que caso os arquivos comecem a ficar grandes novamente, possivelmente vc está com spyware em alguma maquina da sua rede.

FLW!






Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts