<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.hoenzb
        {mso-style-name:hoenzb;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">I too am in favor of global setting. I prototype something that I will post later today but basically I created a xfer-idle-timeout setting that you can set
 in seconds and will then timeout the connection.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Thanks!<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">-Don<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><a name="_____replyseparator"></a><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> ipxe-devel-bounces@ipxe.org [mailto:ipxe-devel-bounces@ipxe.org]
<b>On Behalf Of </b>Kevin Landreth<br>
<b>Sent:</b> Monday, October 13, 2014 5:04 PM<br>
<b>To:</b> ipxe-devel@ipxe.org<br>
<b>Subject:</b> [External] Re: [ipxe-devel] HTTP Transfer does not timeout when transfer interrupted..<o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<div>
<p class="MsoNormal">On Mon, Oct 13, 2014 at 7:51 AM, Christian Hesse <<a href="mailto:list@eworm.de" target="_blank">list@eworm.de</a>> wrote:<o:p></o:p></p>
<p class="MsoNormal">Michael Brown <<a href="mailto:mcb30@ipxe.org">mcb30@ipxe.org</a>> on Mon, 2014/10/13 13:30:<o:p></o:p></p>
<div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt">> On 06/10/14 05:12, Post, Donald L UTAS wrote:<br>
> > In the following case it seems that an HTTP transfer does not time out<br>
> > and basically hangs forever (well a really long time).<br>
> ><br>
> > ·iPXE client is set up to perform for an HTTP of a Linux system.<br>
> ><br>
> > ·The root file system is fairly large and thus takes a bit to down load<br>
> > (say 15 seconds).<br>
> ><br>
> > ·If there is a loss of link during the transfer, the transfer does not<br>
> > timeout but seems to hang<br>
> ><br>
> > ·Even if the cable is reconnected (after a period of time long enough<br>
> > for the TCP connection to have timed out) the transfer does not continue.<br>
> ><br>
> > My questions are:<br>
> ><br>
> > 1.Is this the expected behavior?<br>
> ><br>
> > 2.If not, is there a setting I need to set to enable the timeout and<br>
> > restart of the connection?<br>
><br>
> The underlying problem is that the TCP connection is stable in this<br>
> situation.  The client has nothing to send, so will not be retrying<br>
> anything and will patiently wait forever until the server sends more data.<br>
><br>
> There is an overall --timeout option to all of the image-fetching<br>
> commands ("imgfetch", "chain", etc) which allows you to specify a<br>
> timeout for the complete download operation (including DNS lookup, etc).<br>
>   The timeout is an inactivity timeout: if the download fails to make<br>
> forward progress (as defined by a call to job_progress()) within the<br>
> specified time then the download job will be aborted.<br>
><br>
> For backwards compatiblity, if no timeout is specified then iPXE will<br>
> wait indefinitely.  We could potentially change this: what do people think?<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt">I would vote for a default timeout.<br>
<br>
Additionally... Is it possible to set a value that effects following fetch<br>
commands? So instead of<br>
<br>
imgfetch --timeout 5000 <a href="http://">http://</a>...<br>
<br>
use something like<br>
<br>
set timeout 5000<br>
imgfetch <a href="http://">http://</a>...<br>
<span class="hoenzb"><span style="color:#888888">--</span></span><span style="color:#888888"><br>
<span class="hoenzb">main(a){char*c=/*    Schoene Gruesse                         */"B?IJj;MEH"</span><br>
<span class="hoenzb">"CX:;",b;for(a/*    Chris           get my mail address:    */=0;b=c[a++];)</span><br>
<span class="hoenzb">putchar(b-1/(/*               gcc -o sig sig.c && ./sig    */b/42*2-3)*42);}</span><br>
</span><br>
_______________________________________________<br>
ipxe-devel mailing list<br>
<a href="mailto:ipxe-devel@lists.ipxe.org">ipxe-devel@lists.ipxe.org</a><br>
<a href="https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel" target="_blank">https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel</a><o:p></o:p></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">I too concur that there should be default timeout.  I would assume something reasonable (10 seconds?) would tell us that the connection/server is too unstable to actually boot from.  I personally would rather get an early failure than a
 4 hour boot iPXE imgfetch.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">- Kevin Landreth<o:p></o:p></p>
</div>
</div>
</div>
</body>
</html>