Wireless from the Debian command line

Lennart Sorensen lsorense-1wCw9BSqJbv44Nm34jS7GywD8/FfD2ys at public.gmane.org
Mon May 10 16:22:17 UTC 2010


On Mon, May 10, 2010 at 10:36:46AM -0400, Giles Orr wrote:
> Following on to my post about a new USB wireless-N adapter ...
> 
> I've previously connected to the WPA-enabled wireless router in my
> house with a script like this:
> 
>    ifconfig wlan0 up
>    wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf -D wext &
>    iwconfig wlan0 essid mock
>    dhclient3 wlan0
> 
> /etc/wpa_supplicant.conf looks like this:
> 
> ctrl_interface=/var/run/wpa_supplicant
> ctrl_interface_group=0
> eapol_version=1
> ap_scan=1
> fast_reauth=1
> 
> network={
>   scan_ssid=1
>   psk="xxx xxxx"
>   ssid="mock"
>   priority=9
> }
> 
> Until recently, this has worked fine.  I believe some default
> configuration has changed recently in Debian squeeze, because now -
> across three laptops (two squeeze, one Ubuntu 10.04) with a variety of
> hardware (not just the wireless-N stick), I get continuous errors
> similar to this:
> 
> Trying to associate with NN:NN:NN:NN:NN:NN (SSID='mock' freq=2442 MHz)
> Associated with NN:NN:NN:NN:NN:NN
> Authentication with NN:NN:NN:NN:NN:NN timed out.
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> Trying to associate with NN:NN:NN:NN:NN:NN (SSID='mock' freq=2442 MHz)
> Associated with NN:NN:NN:NN:NN:NN
> Authentication with NN:NN:NN:NN:NN:NN timed out.
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> <repeat ad infinitum, ~5 second intervals>
> 
> (I admit that the above box has yet to achieve working wireless ...
> but the other two have and are now problematic.)
> 
> The Ubuntu Lucid Lynx box works beautifully with
> wireless-g/GNOME/NetworkManager , but when I try this script and
> configuration under Ubuntu, I get
> 
> Trying to associate with NN:NN:NN:NN:NN:NN (SSID='mock' freq=2442 MHz)
> Association request to the driver failed
> Associated with NN:NN:NN:NN:NN:NN
> CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
> <repeat ad infinitum>
> 
> It's different, but similar.  And perhaps the solution isn't the same,
> but the similarity is quite interesting.  I've googled like mad, but
> haven't found a good guide to command line wireless (well, several
> that recreate the script and config I already have that's failing).
> And believe me, a couple of the machines I'm using are NOT going to
> run well (or possibly at all) with GNOME, so that solution is out.
> "wicd" doesn't seem to be a solution either (it fails to connect).
> 
> Unencrypted wireless seems to be fine, I believe this is entirely
> wpa_supplicant-related.
> 
> As always, assistance is much appreciated.

Which wireless chip/driver and which kernel version?

There were some serious wifi problems for many chips in early 2.6.32
kernels that were fixed in later 2.6.32 updates.  The -11 package in
debian finally fixed my intel 5100 wifi, which worked fine with 2.6.31
and older but not with 2.6.32 until the -11 update.  It would connect,
transfer packets for a few seconds and die.  I could then force a
disconnect/reconnect and get a few more seconds of traffic.  Now it
works great again.

-- 
Len Sorensen
--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list