503 error after idle session

Caunter, Stefan scaunter at topscms.com
Fri Oct 1 19:13:40 CEST 2010


You are not waiting long enough for the backend. You need logic to
restart if the first request fails.

Use two directors, one "impatient" and one "patient", with a longer wait
time for first byte. Restart if the first request to the fast director
fails, and use the slow, patient director for that one.

 

Stefan Caunter :: Senior Systems Administrator :: TOPS

e: scaunter at topscms.com  ::  m: (416) 561-4871

www.thestar.com www.topscms.com

 

From: varnish-misc-bounces at varnish-cache.org
[mailto:varnish-misc-bounces at varnish-cache.org] On Behalf Of Jerais
Al-Jeraisy
Sent: July-24-10 6:12 AM
To: varnish-misc at varnish-cache.org
Subject: 503 error after idle session

 

Hello,
We started to implement varnish @ our infrastructure as a reverse proxy
in front of Sharepoint, and it's doing good.
but there's a strange problem, if i requested varnish for the first time
it works fine, but after, say 2 mins, if i hit the page again or refresh
it it takes too long to respond and throw 503 error.
it works the the default configurations, changes only on backend host.
server details:
host: CentOS release 5.5 (Final) x64.
varnish: varnish-2.0.6

here's varnishlog:
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963716 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963719 1.0
   13 SessionOpen  c 10.131.36.170 52969 :80
   13 ReqStart     c 10.131.36.170 52969 374027480
   13 RxRequest    c GET
   13 RxURL        c /default.aspx
   13 RxProtocol   c HTTP/1.1
   13 RxHeader     c Host: xx.xx.xx.xx
   13 RxHeader     c User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US;
rv:1.9.0.15) Gecko/2009102704 Fedora/3.0.15-1.fc10 Firefox/3.0.15
   13 RxHeader     c Accept:
text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
   13 RxHeader     c Accept-Language: en-us,en;q=0.5
   13 RxHeader     c Accept-Encoding: gzip,deflate
   13 RxHeader     c Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
   13 RxHeader     c Keep-Alive: 300
   13 RxHeader     c Connection: keep-alive
   13 RxHeader     c Cookie:
SESS253f3165f282ca21e0aff96094b2f186=4om57skb5bthlv12hno77nefg3;
SESS3c5368fdadd84553468b7aecbb6b8c56=m9okd8i89jeq777sn3c363cge7;
ISAWPLB{30E7D663-ACFC-44A1-A8C4-C17514BA8234}={20C55D85-138B-4814-9748-C
EA17E9D6759}
   13 VCL_call     c recv
   13 VCL_return   c pass
   13 VCL_call     c pass
   13 VCL_return   c pass
   13 Backend      c 22 default default
   22 TxRequest    - GET
   22 TxURL        - /default.aspx
   22 TxProtocol   - HTTP/1.1
   22 TxHeader     - Host: xx.xx.xx.xx
   22 TxHeader     - User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US;
rv:1.9.0.15) Gecko/2009102704 Fedora/3.0.15-1.fc10 Firefox/3.0.15
   22 TxHeader     - Accept:
text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
   22 TxHeader     - Accept-Language: en-us,en;q=0.5
   22 TxHeader     - Accept-Encoding: gzip,deflate
   22 TxHeader     - Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
   22 TxHeader     - Cookie:
SESS253f3165f282ca21e0aff96094b2f186=4om57skb5bthlv12hno77nefg3;
SESS3c5368fdadd84553468b7aecbb6b8c56=m9okd8i89jeq777sn3c363cge7;
ISAWPLB{30E7D663-ACFC-44A1-A8C4-C17514BA8234}={20C55D85-138B-4814-9748-C
EA17E9D6759}
   22 TxHeader     - X-Varnish: 374027480
   22 TxHeader     - X-Forwarded-For: 10.131.36.170
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963722 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963725 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963728 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963731 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963734 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963737 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963740 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963743 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963746 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963749 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963752 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963755 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963758 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963761 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963764 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963767 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963770 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963773 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963776 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963779 1.0
   13 FetchError   c http read error: 11
   22 BackendClose - default
   13 VCL_call     c error
   13 VCL_return   c deliver
   13 Length       c 471
   13 VCL_call     c deliver
   13 VCL_return   c deliver
   13 TxProtocol   c HTTP/1.1
   13 TxStatus     c 503
   13 TxResponse   c Service Unavailable
   13 TxHeader     c Server: Varnish
   13 TxHeader     c Retry-After: 0
   13 TxHeader     c Content-Type: text/html; charset=utf-8
   13 TxHeader     c Content-Length: 471
   13 TxHeader     c Date: Sat, 24 Jul 2010 09:29:40 GMT
   13 TxHeader     c X-Varnish: 374027480
   13 TxHeader     c Age: 60
   13 TxHeader     c Via: 1.1 varnish
   13 TxHeader     c Connection: close
   13 ReqEnd       c 374027480 1279963720.108640909 1279963780.108922005
0.000058889 60.000254154 0.000026941
   13 SessionClose c error
   13 StatSess     c 10.131.36.170 52969 60 1 1 0 1 0 235 471
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963782 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963785 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963788 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963791 1.0
    0 CLI          - Rd ping
    0 CLI          - Wr 0 200 PONG 1279963794 1.0

varnishstats:

          69         0.00         0.01 Client connections accepted
         605         0.00         0.10 Client requests received
          40         0.00         0.01 Backend conn. success
         565         0.00         0.09 Backend conn. reuses
          16         0.00         0.00 Backend conn. was closed
         582         0.00         0.10 Backend conn. recycles
         550         0.00         0.09 Fetch with Length
          28         0.00         0.00 Fetch chunked
           7          .            .   N struct sess_mem
           1          .            .   N struct sess
           0          .            .   N struct object
           8          .            .   N struct objecthead
           1          .            .   N struct smf
           1          .            .   N large free smf
           1          .            .   N struct vbe_conn
           6          .            .   N struct bereq
          10          .            .   N worker threads
          10         0.00         0.00 N worker threads created
           1          .            .   N backends
         125         0.00         0.02 Objects sent with write
          69         0.00         0.01 Total Sessions
         605         0.00         0.10 Total Requests
         605         0.00         0.10 Total pass
         594         0.00         0.10 Total fetch





-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20101001/af779bba/attachment-0003.html>


More information about the varnish-misc mailing list