Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

On Debian I have Varnish cache in front of apache and get 503 error when I try to get urls which are rarely fetched.

I've put 10 min timeout in default.vlc:

backend default {
  .host = "";
  .port = "81";
  .connect_timeout = 600s;
  .first_byte_timeout = 600s;
  .between_bytes_timeout = 600s;

Also I have in /etc/default/varnish

DAEMON_OPTS="-a :80 \
              -T localhost:6082 \
             -b localhost:81 \
             -u varnish -g varnish \
            -S /etc/varnish/secret \

                -p thread_pools=7 \
                -p thread_pool_min=200  \
                -p thread_pool_max=5000 \
                -p listen_depth=2048 \
                -p thread_pool_add_delay=2\
                -p lru_interval=1800 \
                -h classic,169313 \
             -p session_linger=100 \
             -p sess_workspace=262144 \

             -p connect_timeout=600 \
             -p max_restarts=6 \
                -s malloc,7G"

I appreciate your hints to resove this problem.

share|improve this question
Can you fire up varnishlog and capture the relevant log entries when the 503 occurs? And is there any more to your VCL, or is that it? –  Shane Madden Sep 19 '12 at 6:19
How should I find the log messages the 9 digit error? The varnish log bash command here did not work on Debian (it says -m is unkonwn) serverfault.com/a/330989/58595 –  alfish Sep 19 '12 at 20:23
Just run varnishlog with no options. It'll spit out every event to your console as they occur; grab the relevant ones to the request that fails. –  Shane Madden Sep 19 '12 at 21:00
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.