[PATCH 06/19] udhcpc: add support for -t 0 (infinite retries)
Frank TEO
frank128 at ymail.com
Fri Sep 28 15:53:03 UTC 2012
The new option "-t 0" which will infinite retries every 3 seconds (default timeout) has almost
the same effect and behaviour of the existing option using "-A 3" by shortening the
tryagain_timeout from default 20s to 3s.
Do not use the "-b" fork to background option, If you want to simplified by blocking until a lease is obtained.
-FT
----- Original Message -----
From: Rich Felker <dalias at aerifal.cx>
On Fri, Sep 28, 2012 at 01:06:55PM +0800, Frank TEO wrote:
> What is the reason of support for -t 0 (infinite retries)?
> Didn't the tryagain_timeout -A option serve the same purpose?
> You can shorten tryagain_timeout to 3 seconds and udhcpc will behave the same as -t 0 by retries every 3 second.
>
> If you use -t 0, code in "leasefail:" will not run.
> In that way, don't you think udhcpc would have no chance to forking
> to background for other process to continue during system bootup?
I'm pretty sure there are usage cases where the device is utterly
useless until it can obtain a lease. In such cases, the rest of the
init process might be simplified by blocking until a lease is
obtained.
Rich
More information about the busybox
mailing list