[squid-users] Re: tcp timeout issue

From: Frank Ruiz <[email protected]>
Date: Tue, 2 Oct 2007 11:53:15 -0700

Also,

Here is what was patched based on a diff performed:

server01# diff neighbors.c neighbors.c~
1016a1017
> p->tcp_up = PEER_TCP_MAGIC_COUNT;
1022,1023d1022
< if (!p->tcp_up)
< peerProbeConnect((peer *) p);
server01# diff cache_cf.c cache_cf.c~
1629d1628
< p->tcp_up = PEER_TCP_MAGIC_COUNT;
server01#

On 10/2/07, Frank Ruiz <frank.ruiz@gmail.com> wrote:
> Greetings,
>
> I patched squid2.6 stable 14 with the tcp probe patch.
>
> It patched two files:
>
> cache_cf.c
> neighbors.c
>
> However, After about 14 hours of good runtime, my response times,
> began to suck, and began to see errors again indicative of the tcp
> probe issue:
>
> 2007/10/02 01:57:15| Detected REVIVED Parent: 10.10.10.20
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
> 2007/10/02 01:57:16| Detected DEAD Parent: 10.10.10.20
> 2007/10/02 01:57:16| TCP connection to 10.10.10.20/80 failed
>
>
> The origin server is available, however I keep getting
> revivied/connectionfailed/dead
>
> It seems that the only way to recover from this is a restart.
>
> I am running solaris 10, and I had to download the gnu patch utility
> in order to patch the src.
>
> Here was the patch applied.
>
> Index: src/cache_cf.c
> ===================================================================
> RCS file: /cvsroot/squid/squid/src/cache_cf.c,v
> retrieving revision 1.470
> diff -u -p -r1.470 cache_cf.c
> --- src/cache_cf.c 20 Jul 2007 21:08:47 -0000 1.470
> +++ src/cache_cf.c 28 Aug 2007 23:46:47 -0000
> @@ -1621,6 +1621,7 @@ parse_peer(peer ** head)
> p->stats.logged_state = PEER_ALIVE;
> p->monitor.state = PEER_ALIVE;
> p->monitor.interval = 300;
> + p->tcp_up = PEER_TCP_MAGIC_COUNT;
> if ((token = strtok(NULL, w_space)) == NULL)
> self_destruct();
> p->host = xstrdup(token);
> Index: src/neighbors.c
> ===================================================================
> RCS file: /cvsroot/squid/squid/src/neighbors.c,v
> retrieving revision 1.318
> diff -u -p -r1.318 neighbors.c
> --- src/neighbors.c 20 Jul 2007 21:08:47 -0000 1.318
> +++ src/neighbors.c 28 Aug 2007 23:46:47 -0000
> @@ -1010,12 +1010,13 @@ peerDNSConfigure(const ipcache_addrs * i
> debug(0, 0) ("WARNING: No IP address found for '%s'!\n", p->host);
> return;
> }
> - p->tcp_up = PEER_TCP_MAGIC_COUNT;
> for (j = 0; j < (int) ia->count && j < PEER_MAX_ADDRESSES; j++) {
> p->addresses[j] = ia->in_addrs[j];
> debug(15, 2) ("--> IP address #%d: %s\n", j, inet_ntoa(p->addresses[j]))
> ;
> p->n_addresses++;
> }
> + if (!p->tcp_up)
> + peerProbeConnect((peer *) p);
> ap = &p->in_addr;
> memset(ap, '\0', sizeof(struct sockaddr_in));
> ap->sin_family = AF_INET;
>
> Any ideas is much appreciated. Any special debug info you need, please
> let me know.
>
> Also, as I side note, I have monitorurl set as well
>
> cache_peer 10.10.10.20 parent 80 0 no-query no-digest originserver
> monitorinterval=30 monitorurl=http://10.10.10.20/test.jpg
>
> Thank you!
>
Received on Tue Oct 02 2007 - 12:53:23 MDT

This archive was generated by hypermail pre-2.1.9 : Thu Nov 01 2007 - 13:00:00 MDT