Search squid archive

Re: Reverse proxies...

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

 



Indeed, my unique server has 3 IP aliases.

Apaches:
 127.0.0.1:8081
 127.0.0.1:8082
 127.0.0.1:8083
Squids:
 192.168.17.11:80
 192.168.17.12:80
 192.168.17.13:80

I added udp_incoming_address 192.168.17.[11|12|13] respectively in each squid confs
I don't need to change udp_outgoing_address, do I?  (See netstat at the end of this post)

squid1:
 2008/06/27 10:39:20| Accepting accelerated HTTP connections at 192.168.17.11, port 80, FD 12.
 2008/06/27 10:39:20| Accepting ICP messages at 192.168.17.11, port 3130, FD 13.
 2008/06/27 10:39:20| Configuring Parent 127.0.0.1/8081/0
 2008/06/27 10:39:20| Configuring Sibling 192.168.17.12/80/3130
 2008/06/27 10:39:20| Configuring Sibling 192.168.17.13/80/3130

squid2:
 2008/06/27 10:39:23| Accepting accelerated HTTP connections at 192.168.17.12, port 80, FD 12.
 2008/06/27 10:39:23| Accepting ICP messages at 192.168.17.12, port 3130, FD 13.
 2008/06/27 10:39:23| Configuring Parent 127.0.0.1/8082/0
 2008/06/27 10:39:23| Configuring Sibling 192.168.17.11/80/3130
 2008/06/27 10:39:23| Configuring Sibling 192.168.17.13/80/3130

squid3:
 2008/06/27 10:39:27| Accepting accelerated HTTP connections at 192.168.17.13, port 80, FD 12.
 2008/06/27 10:39:27| Accepting ICP messages at 192.168.17.13, port 3130, FD 13.
 2008/06/27 10:39:27| Configuring Parent 127.0.0.1/8083/0
 2008/06/27 10:39:27| Configuring Sibling 192.168.17.11/80/3130
 2008/06/27 10:39:27| Configuring Sibling 192.168.17.12/80/3130

###############################################################################
Purge everything on all squids and browse squid1...
###############################################################################

squid1:
 1214557685.718      2 192.168.17.11 TCP_MISS/200 2329 GET http://192.168.17.11/ - FIRST_UP_PARENT/127.0.0.1 text/html
 1214557685.891      2 192.168.17.11 TCP_MISS/200 4378 GET http://192.168.17.11/img/apache_header.gif - FIRST_UP_PARENT/127.0.0.1 image/gif

 1214557685.716 RELEASE 00 00000029 32AC333767667E106447F39486BD2C7F    0        -1        -1        -1 unknown -1/0 NONE http://192.168.17.12/squid- internal-periodic/store_digest
 1214557685.716 SWAPOUT 00 00000000 1BDEF453F2C0A866DD905F6C79CF1002  200 1214557685 1214555963 1214559563 application/cache-digest 147/147 GET  http://192.168.17.12/squid-internal-periodic/store_digest
 1214557685.717 SWAPOUT 00 00000001 8A4E6E4ABE750B9AFCBBE4277ADA20FA  200 1214557685 1214468758 1214557985 text/html 2020/2020 GET http://192.168.17.11/
 1214557685.889 SWAPOUT 00 00000002 8BC2233ECEF0C976FDD190FF1A652998  200 1214557685 1214468039 1214557985 image/gif 4084/4084 GET http://192.168.17.11/ img/apache_header.gif

squid2:
 1214557685.187      0 192.168.17.11 UDP_MISS/000 42 ICP_QUERY http://192.168.17.11/ - NONE/- -
 1214557685.716      0 192.168.17.12 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest
 1214557685.716      0 192.168.17.11 UDP_MISS/000 63 ICP_QUERY http://192.168.17.11/img/apache_header.gif - NONE/- -

squid3:
 1214557685.331      0 192.168.17.11 UDP_MISS/000 42 ICP_QUERY http://192.168.17.11/ - NONE/- -
 1214557685.716      0 192.168.17.11 UDP_MISS/000 63 ICP_QUERY http://192.168.17.11/img/apache_header.gif - NONE/- -
 1214557745.716      0 192.168.17.13 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest

apache1:
 127.0.0.1 - - [27/Jun/2008:11:08:05 +0200] "GET / HTTP/1.0" 200 2020
 127.0.0.1 - - [27/Jun/2008:11:08:05 +0200] "GET /img/apache_header.gif HTTP/1.0" 200 4084

###############################################################################
Browse squid1 again...
###############################################################################

squid1:
 1214557857.361      0 192.168.17.11 TCP_IMS_HIT/304 254 GET http://192.168.17.11/ - NONE/- text/html
 1214557857.484    122 192.168.17.11 TCP_IMS_HIT/304 239 GET http://192.168.17.11/img/apache_header.gif - NONE/- image/gif

 1214557857.361 RELEASE -1 FFFFFFFF F935846DBCC888FE053A2D9A6E8B529B  304 1214557685 1214468758 1214561285 text/html -1/0 GET http://192.168.17.11/
 1214557857.484 RELEASE -1 FFFFFFFF 8262DA350A386275C1F0FFE25DEDFD1F  304 1214557685 1214468039 1214561285 image/gif -1/0 GET http://192.168.17.11/img/apache_header.gif

###############################################################################
Browse squid2...
###############################################################################

squid1:
 1214558005.099      0 192.168.17.12 UDP_MISS/000 42 ICP_QUERY http://192.168.17.12/ - NONE/- -
 1214558005.774      0 192.168.17.11 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest
 1214558005.860      0 192.168.17.12 UDP_MISS/000 63 ICP_QUERY http://192.168.17.12/img/apache_header.gif - NONE/- -

squid2:
 1214558005.955    181 192.168.17.12 TCP_MISS/200 2329 GET http://192.168.17.12/ - TIMEOUT_FIRST_UP_PARENT/127.0.0.1 text/html
 1214558006.124    169 192.168.17.12 TCP_MISS/200 4378 GET http://192.168.17.12/img/apache_header.gif - TIMEOUT_FIRST_UP_PARENT/127.0.0.1 image/gif

 1214558005.774 RELEASE 00 00000026 2208AA65FB6395754F10242FCE0C760C    0        -1        -1        -1 unknown -1/0 NONE http://192.168.17.11/squid- internal-periodic/store_digest
 1214558005.774 SWAPOUT 00 00000000 5C8101E583714DCD007FF2095C0FF6D2  200 1214558005 1214555960 1214559560 application/cache-digest 147/147 GET  http://192.168.17.11/squid-internal-periodic/store_digest
 1214558005.775 SWAPOUT 00 00000001 9F304B5AEDD1581603CDC4C6320AEE1F  200 1214558005 1214468758 1214558305 text/html 2020/2020 GET http://192.168.17.12/
 1214558005.979 SWAPOUT 00 00000003 9D1D5C3B8E020FA5AB7749E469BF5D6E  200 1214558006 1214468039 1214558306 image/gif 4084/4084 GET http://192.168.17.12/img/apache_header.gif
 1214558065.774 RELEASE 00 00000027 FCA9B4DFE086DF6692F9EC0CCE585B66    0        -1        -1        -1 unknown -1/0 NONE http://192.168.17.13/squid-internal-periodic/store_digest
 1214558065.774 SWAPOUT 00 00000004 6BB5F118D5D548296562668556E2FF74  200 1214558065 1214555967 1214559567 application/cache-digest 147/147 GET http://192.168.17.13/squid-internal-periodic/store_digest

squid3:
 1214558005.400      0 192.168.17.12 UDP_MISS/000 42 ICP_QUERY http://192.168.17.12/ - NONE/- -
 1214558005.774      0 192.168.17.12 UDP_MISS/000 63 ICP_QUERY http://192.168.17.12/img/apache_header.gif - NONE/- -
 1214558065.774      0 192.168.17.13 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest

apache2:
 127.0.0.1 - - [27/Jun/2008:11:13:25 +0200] "GET / HTTP/1.0" 200 2020
 127.0.0.1 - - [27/Jun/2008:11:13:26 +0200] "GET /img/apache_header.gif HTTP/1.0" 200 4084

###############################################################################
Browse squid2 again...
###############################################################################

Idem squid1...

###############################################################################
Browse squid3...
###############################################################################

squid1:
 1214558293.183      0 192.168.17.13 UDP_MISS/000 42 ICP_QUERY http://192.168.17.13/ - NONE/- -
 1214558293.470      0 192.168.17.11 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest
 1214558293.470      0 192.168.17.13 UDP_MISS/000 63 ICP_QUERY http://192.168.17.13/img/apache_header.gif - NONE/- -

squid2:
 1214558293.295      0 192.168.17.13 UDP_MISS/000 42 ICP_QUERY http://192.168.17.13/ - NONE/- -
 1214558293.470      0 192.168.17.13 UDP_MISS/000 63 ICP_QUERY http://192.168.17.13/img/apache_header.gif - NONE/- -
 1214558353.470      0 192.168.17.12 TCP_MEM_HIT/200 374 GET internal://pc-03/squid-internal-periodic/store_digest - NONE/- application/cache-digest

squid3:
 1214558293.622    152 192.168.17.13 TCP_MISS/200 2329 GET http://192.168.17.13/ - TIMEOUT_FIRST_UP_PARENT/127.0.0.1 text/html
 1214558293.778    156 192.168.17.13 TCP_MISS/200 4378 GET http://192.168.17.13/img/apache_header.gif - TIMEOUT_FIRST_UP_PARENT/127.0.0.1 image/gif

 1214558293.470 RELEASE 00 00000000 2208AA65FB6395754F10242FCE0C760C    0        -1        -1        -1 unknown -1/0 NONE http://192.168.17.11/squid-internal-periodic/store_digest
 1214558293.470 SWAPOUT 00 00000000 5C8101E583714DCD007FF2095C0FF6D2  200 1214558293 1214555960 1214559560 application/cache-digest 147/147 GET http://192.168.17.11/squid-internal-periodic/store_digest
 1214558293.470 SWAPOUT 00 00000001 8775D18057460601412E392A08AF00C3  200 1214558293 1214468758 1214558593 text/html 2020/2020 GET http://192.168.17.13/
 1214558293.640 SWAPOUT 00 00000003 F50FEB8ED84D3A721B952ED63D5D966D  200 1214558293 1214468039 1214558593 image/gif 4084/4084 GET http://192.168.17.13/img/apache_header.gif
 1214558353.470 RELEASE 00 00000004 B6A98B09C389F6C66A92A26189CCACFB    0        -1        -1        -1 unknown -1/0 NONE http://192.168.17.12/squid-internal-periodic/store_digest
 1214558353.470 SWAPOUT 00 00000004 1BDEF453F2C0A866DD905F6C79CF1002  200 1214558353 1214555963 1214559563 application/cache-digest 147/147 GET http://192.168.17.12/squid-internal-periodic/store_digest

apache3:
 127.0.0.1 - - [27/Jun/2008:11:18:13 +0200] "GET / HTTP/1.0" 200 2020
 127.0.0.1 - - [27/Jun/2008:11:18:13 +0200] "GET /img/apache_header.gif HTTP/1.0" 200 4084

###############################################################################
Browse squid3 again...
###############################################################################

Idem squid1...

###############################################################################
Access all squids to be sure all cached, purge 1 object from squid1 and browse squid1...
###############################################################################

squid1:
 1214558978.412      1 192.168.17.11 TCP_REFRESH_HIT/200 2329 GET http://192.168.17.11/ - FIRST_UP_PARENT/127.0.0.1 text/html
 1214558978.583      1 192.168.17.11 TCP_MISS/200 4378 GET http://192.168.17.11/img/apache_header.gif - FIRST_UP_PARENT/127.0.0.1 image/gif

squid2:
 1214558978.431      0 192.168.17.11 UDP_MISS/000 63 ICP_QUERY http://192.168.17.11/img/apache_header.gif - NONE/- -

squid3:
 1214558977.594      0 192.168.17.11 UDP_MISS/000 63 ICP_QUERY http://192.168.17.11/img/apache_header.gif - NONE/- -

apache1:
 127.0.0.1 - - [27/Jun/2008:11:29:38 +0200] "GET / HTTP/1.0" 304 -
 127.0.0.1 - - [27/Jun/2008:11:29:38 +0200] "GET /img/apache_header.gif HTTP/1.0" 200 4084

###############################################################################
Summary
###############################################################################

Siblings are contacted but do not want to share their cache...
Could it be by example because squid1 IP, appearing in the ICP_QUERY, confuses squid2 and squid3, or is it normal behavior...?

Also, even if I have the following:
2008/06/27 10:39:23| Local cache digest enabled; rebuild/rewrite every 600/3600 
The digests don't seem to be rebuild every 10 minutes (or is it silent?).
And they seem to exchange digests after the ICP_QUERY...

pc-03, my test server hostname with an IP of 192.168.16.23 (not used in the squid confs) appears in the logs...
It should not, right?

netstat gives:

tcp        0      0 192.168.16.23:8000          0.0.0.0:*                   LISTEN      

tcp        0      0 192.168.17.13:80            0.0.0.0:*                   LISTEN      
tcp        0      0 192.168.17.12:80            0.0.0.0:*                   LISTEN      
tcp        0      0 192.168.17.11:80            0.0.0.0:*                   LISTEN      
tcp        0      0 127.0.0.1:8081              0.0.0.0:*                   LISTEN      
tcp        0      0 127.0.0.1:8082              0.0.0.0:*                   LISTEN      
tcp        0      0 127.0.0.1:8083              0.0.0.0:*                   LISTEN      

udp        0      0 192.168.17.13:3130          0.0.0.0:*                               
udp        0      0 192.168.17.12:3130          0.0.0.0:*                               
udp        0      0 192.168.17.11:3130          0.0.0.0:*                               
udp        0      0 192.168.17.11:33134         0.0.0.0:*                               
udp        0      0 192.168.17.12:33136         0.0.0.0:*                               
udp        0      0 192.168.17.13:33137         0.0.0.0:*                               

Thx,
JD


      


[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux