udhcpc option question
Michael D. Setzer II
mikes at kuentos.guam.net
Wed Aug 7 17:37:46 UTC 2013
On 7 Aug 2013 at 17:31, Denys Vlasenko wrote:
From: Denys Vlasenko <vda.linux at googlemail.com>
Date sent: Wed, 7 Aug 2013 17:31:03 +0200
Subject: Re: udhcpc option question
To: "Michael D. Setzer II"
<mikes at kuentos.guam.net>
Copies to: busybox at busybox.net
> On Mon, Aug 5, 2013 at 3:23 AM, Michael D. Setzer II
> <mikes at kuentos.guam.net> wrote:
> >> > I've just gotten a report from an user that he is having an issue
> >> > with it not getting the ip address during the initial boot
> >> > process, but running it again succeeds? Not sure what is causing
> >> > the initial failure. The original attempt is a script that is
> >> > called from the rcS script, and it has the udhcpc with options
> >> > -n, -i and -s. Was thinking of adding a -t 4 option to see if
> >> > that would have it try 4 times, but am not sure if -t and -n work
> >> > together.
> >>
> >> They should: even if -t N isn't specified,
> >> it is implicitly set to 3.
> >
> > First, Thanks for the quick reply.
> > The help screen show any default value for the -t option?
> > But perhaps there is another option.
> >
> >> > There may also
> >> > be users that don't have a dhcpd server setup, so can't just have
> >> > it keep trying.
> >> >
> >> > The user is not local, so it is difficult to work remotely on the
> >> > issue. Perhaps someone has a more complete understanding of the
> >> > options for udhcpc than I do. Using busybox 1.21.1.
> >>
> >> Ask user to crank up debug output using -vv[v]
> >> and set CONFIG_UDHCP_DEBUG.
> >> to 9.
> >
> > Unfortuantely, this is running from a cd image of my g4l project, so
> > the end user or I would have to modify it at the source. The issue
> > is that the script is called as part of the /etc/init.d/rcS file in
> > which it is failing to get the IP from the dhcpd, but running the
> > script after the boot process works?
>
> Please provide more information.
> What udhcpc says when it fails?
The script that is called to check for the ip address filters the
output of the udhcpc and just checks for the success, so the direct
output is not show on screen.
The script with the addition of -t 8 -T 5 was added to see if that
would correct the issue.
ftp://amd64gcc.dyndns.org/ifcheck2.sh
The users last response on Aug 1 was.
Not sure if this helps or not. When I start, it does the initial check
and SAYS that it has found eth0 with Active link and running
DHCP client. I believe it then says it couldn't acquire an IP via
dhcp, so perhaps the issue is on my end, and seems to be wholly
contained within the ifcheck2 script. Just odd that if I run it
manually right after that it seems to get the IP.
I have made the changes with the -t 8 -T 5 and made an new
image of my g4l project, and made it available for the user to test,
but have not heard back.
> Can you post a tcpdump of this event?
>
I'm located on Island of Guam, GMT +1000, and have no ideal
where this user might be. Email is via users.sf.net, so could be
anywhere. Don't know users ability to run a tcpdump or not.
> > It sees the nic, and sees that it has a link, but the getting of the
> > IP address fails at that point of the rcS. Could be that having it
> > runnign the whole script again if it failed would solve the issue.
>
> I think it's better to diagnose the problem first,
> *then* think about ways to fix it.
>
> > Perhaps the -A option??
>
> "-A SEC" is ignored if -n is given.
I did some testing, and with the usage the -n is required and the
-A would not anyway. I don't know the network setup is, or what
type of dhcp server is used.
+----------------------------------------------------------+
Michael D. Setzer II - Computer Science Instructor
Guam Community College Computer Center
mailto:mikes at kuentos.guam.net
mailto:msetzerii at gmail.com
http://www.guam.net/home/mikes
Guam - Where America's Day Begins
G4L Disk Imaging Project maintainer
http://sourceforge.net/projects/g4l/
+----------------------------------------------------------+
http://setiathome.berkeley.edu (Original)
Number of Seti Units Returned: 19,471
Processing time: 32 years, 290 days, 12 hours, 58 minutes
(Total Hours: 287,489)
BOINC at HOME CREDITS
SETI 15662608.853207 | EINSTEIN 12631615.299852
ROSETTA 8161199.389977 | ABC 16207622.111209
More information about the busybox
mailing list