[ipxe-devel] HTTP Transfer does not timeout when transfer interrupted..

Christian Hesse list at eworm.de
Mon Oct 13 12:51:19 UTC 2014


Michael Brown <mcb30 at ipxe.org> on Mon, 2014/10/13 13:30:
> On 06/10/14 05:12, Post, Donald L UTAS wrote:
> > In the following case it seems that an HTTP transfer does not time out
> > and basically hangs forever (well a really long time).
> >
> > ·iPXE client is set up to perform for an HTTP of a Linux system.
> >
> > ·The root file system is fairly large and thus takes a bit to down load
> > (say 15 seconds).
> >
> > ·If there is a loss of link during the transfer, the transfer does not
> > timeout but seems to hang
> >
> > ·Even if the cable is reconnected (after a period of time long enough
> > for the TCP connection to have timed out) the transfer does not continue.
> >
> > My questions are:
> >
> > 1.Is this the expected behavior?
> >
> > 2.If not, is there a setting I need to set to enable the timeout and
> > restart of the connection?
> 
> The underlying problem is that the TCP connection is stable in this 
> situation.  The client has nothing to send, so will not be retrying 
> anything and will patiently wait forever until the server sends more data.
> 
> There is an overall --timeout option to all of the image-fetching 
> commands ("imgfetch", "chain", etc) which allows you to specify a 
> timeout for the complete download operation (including DNS lookup, etc). 
>   The timeout is an inactivity timeout: if the download fails to make 
> forward progress (as defined by a call to job_progress()) within the 
> specified time then the download job will be aborted.
> 
> For backwards compatiblity, if no timeout is specified then iPXE will 
> wait indefinitely.  We could potentially change this: what do people think?

I would vote for a default timeout.

Additionally... Is it possible to set a value that effects following fetch
commands? So instead of

imgfetch --timeout 5000 http://...

use something like

set timeout 5000
imgfetch http://...
-- 
main(a){char*c=/*    Schoene Gruesse                         */"B?IJj;MEH"
"CX:;",b;for(a/*    Chris           get my mail address:    */=0;b=c[a++];)
putchar(b-1/(/*               gcc -o sig sig.c && ./sig    */b/42*2-3)*42);}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <http://lists.ipxe.org/pipermail/ipxe-devel/attachments/20141013/06b2f54e/attachment.sig>


More information about the ipxe-devel mailing list