DHCP kills connection
dimitris at gmail.com
Wed Aug 10 13:49:52 EDT 2005
> Yeah now it works with dhcpcd. Thanks a lot Roy!
> After trying out several ideas I suspected that dhclient, pump and
> probably most other DHCP clients take down the interface as I noticed
> when making a WEP connection.
> I really wonder why I havent't found anything about this issue neither
> in the mailinglist nor in the documentation. I think this should be
> mentioned somewhere as most 'regular' users use DHCP with their wlan
> routers and have no idea about the DHCP process.
Disclaimer: I'm not at all familiar with the internals of the dhclient
I've been using wpasupplicant and dhcp3-client - both from Debian
unstable - on a WPA-PSK wlan for 2+ months. I've never seen this problem.
As far as I can tell, the /etc/dhcp3/dhclient-script explicitly brings
the interface up during the PREINIT stage:
# The DHCP client is requesting that an interface be
# configured as required in order to send packets prior to
# receiving an actual address. - dhclient-script(8)
if [ -n "$alias_ip_address" ]; then
# Bring down alias interface. Its routes will disappear too.
ifconfig $interface:0- inet 0
ifconfig $interface 0 up
# We need to give the kernel some time to get the interface up.
Occasionally the first DHCP request will time out, which I take to mean
that the 1+ second delay is not enough for wpasupplicant and my AP to
complete the authentication.
FWIW the DHCP server is not the AP itself but a box on its wired side,
running dhcp3-server also from Debian unstable.
In general this setup has been very robust, including through swsusp.
More information about the HostAP