<div dir="ltr">Hello Daniele,<div><br></div><div>Looks like you are hitting the send_timeout. Try "varnishadm param.show | grep timeout", and see if you have something around 120s.</div><div><br></div><div>Cheers,</div><div><br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>-- <br></div>Guillaume Quintard<br></div></div></div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Mar 20, 2019 at 3:32 AM Daniele Piaggesi <<a href="mailto:daniele.piaggesi@bonsaimeme.com">daniele.piaggesi@bonsaimeme.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;"><div>Dear all</div><div><br></div><div>I have a problem with my Varnish installation when I try to stream mp3 files through Varnish Cache 4. This is the scenario.</div><div><br></div><div>I have a Drupal website in which editors can upload mp3s. These mp3s are listed in a section of website and the end user can listen using an HTML 5 player.</div><div>The stack is: Varnish 4 <-> Nginx 1.11<-> Drupal 7 on a GNU/Linux Debian Jessie. Varnish and Nginx are installed with Debian packages.</div><div><br></div><div>My Varnish configuration is here: <a href="https://pastebin.com/8Kw1b2mL" target="_blank">https://pastebin.com/8Kw1b2mL</a></div><div><br></div><div>When I try to listen an mp3 directly through Nginx all works well: player loads the file and I can listen the mp3. If I try to do the same through Varnish, the player remains in loading and mp3 doesn’t start. I tried to download the mp3 file using curl and my request goes in timeout.</div><div><br></div><div>I had a look at varnishlog and this is the output:</div><div><br></div><div>* << Request >> 1409738</div><div>- Begin req 1246052 rxreq</div><div>- Timestamp Start: 1552587068.541997 0.000000 0.000000</div><div>- Timestamp Req: 1552587068.541997 0.000000 0.000000</div><div>- ReqStart 93.147.150.135 15330</div><div>- ReqMethod GET</div><div>- ReqURL /sites/default/files/audio/radio_interviews/20180927-rds-gr_rds_1700-170602593m_1.mp3</div><div>- ReqProtocol HTTP/1.1</div><div>- ReqHeader Host: <a href="http://www.xxx.it" target="_blank">www.xxx.it</a></div><div>- ReqHeader Connection: keep-alive</div><div>- ReqHeader Pragma: no-cache</div><div>- ReqHeader Cache-Control: no-cache</div><div>- ReqHeader Accept-Encoding: identity;q=1, *;q=0</div><div>- ReqHeader User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.119 Safari/537.36</div><div>- ReqHeader chrome-proxy: frfr</div><div>- ReqHeader Accept: */*</div><div>- ReqHeader Referer: <a href="http://www.xxx.it/path/to/url" target="_blank">http://www.xxx.it/path/to/url</a></div><div>- ReqHeader Accept-Language: en-US,en;q=0.9,es;q=0.8,fr;q=0.7,it;q=0.6</div><div>- ReqHeader Cookie: SESScookieagreed=2; has_js=1; _ga=GA1.2.950111086.1552579260; _gid=GA1.2.112403313.1552579260; __atuvc=2%7C11; _gat_UA-57096474-1=1</div><div>- ReqHeader Range: bytes=0-</div><div>- ReqHeader X-Forwarded-For: 93.147.150.135</div><div>- VCL_call RECV</div><div>- VCL_acl NO_MATCH allowed_monitors</div><div>- ReqUnset X-Forwarded-For: 93.147.150.135</div><div>- ReqHeader X-Forwarded-For: 93.147.150.135, 93.147.150.135</div><div>- ReqURL /sites/default/files/audio/radio_interviews/20180927-rds-gr_rds_1700-170602593m_1.mp3</div><div>- ReqHeader x-range: bytes=0-</div><div>- ReqUnset Cookie: SESScookieagreed=2; has_js=1; _ga=GA1.2.950111086.1552579260; _gid=GA1.2.112403313.1552579260; __atuvc=2%7C11; _gat_UA-57096474-1=1</div><div>- VCL_return hash</div><div>- ReqUnset Accept-Encoding: identity;q=1, *;q=0</div><div>- VCL_call HASH</div><div>- ReqUnset Range: bytes=0-</div><div>- VCL_return lookup</div><div>- Hit 229378</div><div>- VCL_call HIT</div><div>- VCL_return fetch</div><div>- VCL_Error change return(fetch) to return(miss) in vcl_hit{}</div><div>- VCL_call MISS</div><div>- VCL_return fetch</div><div>- Link bereq 1409739 fetch</div><div>- Timestamp Fetch: 1552587068.542520 0.000523 0.000523</div><div>- RespProtocol HTTP/1.1</div><div>- RespStatus 200</div><div>- RespReason OK</div><div>- RespHeader Server: nginx/1.11.5</div><div>- RespHeader Date: Thu, 14 Mar 2019 18:11:08 GMT</div><div>- RespHeader Last-Modified: Fri, 28 Sep 2018 08:26:56 GMT</div><div>- RespHeader ETag: "5bade5d0-a0b94"</div><div>- RespHeader Content-Type: audio/mpeg</div><div>- RespHeader Content-Length: 658324</div><div>- RespHeader X-Cacheable: YES</div><div>- RespHeader X-Varnish: 1409738</div><div>- RespHeader Age: 0</div><div>- RespHeader Via: 1.1 varnish-v4</div><div>- VCL_call DELIVER</div><div>- RespHeader X-Cache: MISS</div><div>- RespHeader X-Cookie:</div><div>- RespHeader grace:</div><div>- RespHeader X-Varnish-Server: <a href="http://www.xxx.it" target="_blank">www.xxx.it</a></div><div>- VCL_return deliver</div><div>- Timestamp Process: 1552587068.542536 0.000539 0.000016</div><div>- RespHeader Accept-Ranges: bytes</div><div>- Debug "RES_MODE 2"</div><div>- RespHeader Connection: keep-alive</div><div>- Debug "Hit idle send timeout, wrote = 247608/658701; retrying"</div><div>- Debug "Write error, retval = -1, len = 411093, errno = Resource temporarily unavailable"</div><div>- Timestamp Resp: 1552587188.539239 119.997242 119.996703</div><div>- ReqAcct 733 0 733 377 658324 658701</div><div>- End</div><div><br></div><div>I’m not a Varnish “guru”, but it seems that the error is:</div><div><br></div><div><div><b>- Debug "Hit idle send timeout, wrote = 247608/658701; retrying"</b></div><div><b>- Debug "Write error, retval = -1, len = 411093, errno = Resource temporarily unavailable"</b></div></div><div><br></div><div>I search a lot on Google but I didn’t find anything about that, except for a timeout problem that doesn’t seem to me because timeout settings are set to 60s (first_byte), same as Nginx.</div><div><br></div><div>Any help is really appreciated. If you need some other infos, let me know.</div><div><br></div><div>Thanks in advance</div><div>Daniele</div><div>
<div dir="auto" style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration:none"><div style="overflow-wrap: break-word;"><div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant-caps:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><div><font color="#d5383b" face="HelveticaNeue-Medium" style="font-size:14px">Daniele Piaggesi</font></div><div><div><br></div><div><font face="HelveticaNeue-Light"><font color="#d5383b">Mobile</font><font color="#c8c8c8">:</font> +39 393 880 78 50</font></div><div><font face="HelveticaNeue-Light"><font color="#d5383b">Skype:</font> g0blin79</font></div><div><font color="#d5383b" style="font-family:HelveticaNeue-Light">E-mail:</font><span style="font-family:HelveticaNeue-Light"> <a href="mailto:daniele.piaggesi@bmeme.com" target="_blank">daniele.piaggesi@bmeme.com</a></span></div><div><font face="HelveticaNeue-Light" color="#929292">------------------------------------------</font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1">Bonsaimeme S.r.l.</font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1">Via del Porto Fluviale, 9</font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1">00154 Roma - Italy</font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1"><br></font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1">Phone: +39 06 98 26 04 39 </font></div><div><font face="HelveticaNeue-Light" color="#929292" size="1">Fax: +39 06 94 81 02 03</font></div><div><font face="HelveticaNeue-Light"><font color="#929292">------------------------------------------</font>-</font></div><div><font face="HelveticaNeue-Light" color="#000003" size="1"><a href="http://bmeme.com" target="_blank">bmeme.com</a></font></div></div><div><font face="HelveticaNeue-Light" color="#000003"><br></font></div><div><br></div><div><div><font face="HelveticaNeue-Medium" color="#008f00">*** Prima di stampare, pensa all'ambiente! ***</font></div><div><span style="color:rgb(0,143,0);font-family:HelveticaNeue-Medium">*** Before printing think about environment and costs ***</span></div><div><font face="HelveticaNeue-Medium" color="#008f00"><br></font></div><div style="color:rgb(0,0,3)"><font face="HelveticaNeue-Light" size="1"><br></font></div><div><font color="#a9a9a9" face="HelveticaNeue-Light" size="1">Le informazioni, i dati e le notizie contenute nella presente comunicazione e i relativi allegati sono di natura privata e come tali possono essere riservate e sono, comunque, destinate esclusivamente ai destinatari indicati in epigrafe. La diffusione, distribuzione e/o la copiatura del documento trasmesso da parte di qualsiasi soggetto diverso dal destinatario è proibita, sia ai sensi dell’art. 616 c.p., sia ai sensi del D.Lgs. n. 196/2003. Se avete ricevuto questo messaggio per errore, vi preghiamo di distruggerlo e di darcene immediata comunicazione anche inviando un messaggio all’indirizzo email: <a href="mailto:info@bonsaimeme.com" target="_blank">info@bonsaimeme.com</a>. </font><span style="color:rgb(169,169,169);font-family:HelveticaNeue-Light;font-size:x-small">Il testo della email potrebbe contenere opinioni personali e non necessariamente riconducibili a quelle di Bonsaimeme S.r.l.</span></div><div><font color="#a9a9a9" face="HelveticaNeue-Light" size="1"><br></font></div><div><font color="#a9a9a9" face="HelveticaNeue-Light" size="1">--- --- ---</font></div><div><font color="#a9a9a9" face="HelveticaNeue-Light" size="1"><br></font></div><div><font color="#a9a9a9" face="HelveticaNeue-Light" size="1">This e-mail (including attachments) is intended only for the recipient(s) named above. It may contain confidential or privileged information and should not be read, copied or otherwise used by any other person. If you are not the named recipient, please contact: <a href="mailto:info@bonsaimeme.com" target="_blank">info@bonsaimeme.com</a> and delete the e-mail from your system. Rif. D.L. 196/2003.</font></div></div></div></div></div>
</div>
<br></div>_______________________________________________<br>
varnish-misc mailing list<br>
<a href="mailto:varnish-misc@varnish-cache.org" target="_blank">varnish-misc@varnish-cache.org</a><br>
<a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" rel="noreferrer" target="_blank">https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc</a><br>
</blockquote></div>