[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#606654: Busybox should include arping applet



A Sexta 10 Dezembro 2010 20:08:58 Ferenc Wagner você escreveu:
> Floris Bos <bos@je-eigen-domein.nl> writes:
> > On Friday, December 10, 2010 05:12:39 pm Ferenc Wagner wrote:
> >> Floris Bos <bos@je-eigen-domein.nl> writes:
> >>> I think the arping applet should be enabled in the Busybox build.
> >>> It helps a great deal in debugging general network issues and could be
> >>> helpful to create a solution for some other bugs like:
> >>> 
> >>> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=537271 (network may
> >>> not be usable as soon as link is up)
> >>> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=606515 (Preseed
> >>> installation does not wait for network to be ready)
> >> 
> >> Please read
> >> http://wiki.debian.org/DebianInstaller/FAQ#Q.3AWhyispingnotavailableinth
> >> ede bugshell
> >> 
> >> Roughly the same applies to arping.  After all, you can cat
> >> /proc/net/arp to check whether the gateway has a complete entry.
> > 
> > But wouldn't you need to initiate network communication before an entry
> > in /proc/net/arp for the gateway appears?
> 
> Yes, sure.
> 
> > Right now PXE preseed installations are broken, making Debian unsuitable
> > for use by dedicated server providers.
> > The Debian installer does not wait for the network link to come up (can
> > take about 3 seconds on some NICs connected to a standard Gigabit
> > switch), nor does it take into account that it can take 30 seconds
> > before network activity is possible in spanning tree configurations.
> 
> I agree that this is a problem, I've been bitten by this recently.
> 
> > A simply 1-line fix if we had arping might be executing between netcfg
> > and network-preseed:
> > 
> > arping -f -c 35 $GATEWAY_IP
> > 
> > (wait until you get an ARP reply from the gateway, timeout after 35
> > seconds/tries).
> 
> Something like that should go *into* netcfg, between configuring the
> network statically and querying the DNS for the name of the configured
> IP address.
> 
> For DHCP, udhcpc should be invoked with -t 20 or similar, so that it
> doesn't just sleep most of the time but actually tries to get a license
> during the time allowed by the dialog timeout.
> 
> > I don't think calling wget 35 times, and grepping /proc/net/arp is a
> > clean alternative, just to save 4 KB of space.
> 
> wget isn't pretty, but one could do something like
> 
> while [ "$i" -lt 30 ] && ! nc -w 1 GATEWAY 80 -e /bin/true; do i=$(($i +
> 1)); done grep "^GATEWAY .* 00:00:00:00:00:00 " /proc/net/arp && echo fail
> 
> for example.  But netcfg is written in C, and this stuff belongs to
> there, where one could do even better.

So should this BR be reassigned to netcfg as wishlist?

-- 
Melhores cumprimentos/Best regards,

Miguel Figueiredo
http://www.DebianPT.org




Reply to: