Delay needed between setting WEP key and ESSID

James Clark jjc
Mon Mar 17 01:11:34 PST 2003


I am using HostAP on RedHat 8.0 (redhat kernel 2.4.18-24.8.0) with a 
Prism 2.5 Mini-PCI card (nicid 0x8013), firmware 1.1.0/1.4.9 on a 
notebook with a 1GHz Pentium III Mobile.  I get the same results with 
the 2002-10-12 version and the current CVS version.

When I do

   ifup wlan0

I almost always get the error

Error for wireless request "Set ESSID" (8B1A) :
     SET failed on device wlan0 ; Invalid argument.

dmesg contains

wlan0: hfa384x_setup_bap - timeout after
wlan0: hfa384x_set_rid (rid=fc02, len=34) - failed - res=-110

and wlan0 is non-functional.

This seems the same problem as

http://lists.shmoo.com/pipermail/hostap/2002-November/000482.html

ifup wlan0 ends up calling /etc/sysconfig/network-scripts/ifup-wireless, 
which ends up calling iwconfig to set the key and the essid.

If I create a script

iwconfig wlan0 key $KEY
iwconfig wlan0 essid $ESSID

and run that script (as root) I get the same error.  However, I found 
that if I enter the commands individually I get no such error and 
everything works.

It turns out that inserting a small delay in between the two iwconfigs 
is sufficient.  If I modify ifup-wireless to add

   sleep 0.1

before the final iwconfig, everything seems to work just fine.

James






More information about the Hostap mailing list