You are not logged in.

#1 2009-08-06 20:35:41

Mr.Cat
Member
Registered: 2008-09-27
Posts: 79

Netcfg down ... then up

When trying to put the interface up shortly after putting it down, I get the following:

sudo netcfg -d KS; sleep 60; sudo netcfg KS
:: KS down                                                               [DONE]
:: KS up                                                                 [BUSY]
wlan0     Interface doesn't support scanning : Device or resource busy

wlan0     Interface doesn't support scanning : Device or resource busy

                                                                         [DONE]

Is it ok?

Offline

#2 2009-08-06 20:51:21

Profjim
Member
From: NYC
Registered: 2008-03-24
Posts: 658

Re: Netcfg down ... then up

I've been having this problem too; it's not an issue with netcfg per se but with your wireless driver. You've got to get the card to reset to a clean state, and for some reason the standard commands for doing that, which netcfg is issuing, aren't enough.

I just recently spent some time trying to figure out what's a reliable way to do this, so that we could netcfg to issue those commands automatically. (I've been contributing some patches to netcfg.) But for my card, at least, I just couldn't find the magic words. Sometimes doing a "ifconfig wlan0 down; iwconfig wlan0 ap off; ifconfig wlan0 up" worked; most often it didn't. Sometimes doing it three times in a row worked; sometimes it didn't. Sometimes doing something else worked; sometimes it didn't. The problem may be timing-dependent.

My wireless driver is iwlagn.

If you can figure out what commands X are such that _you_ can do "netcfg -d KC; X; sudo ifconfig wlan0 up; sudo iwlist wlan0 scan" (substitute your wireless interface for 'wlan0', and whatever you can think of for 'X') and not get these errors, that would help and maybe we can get netcfg to do that by default.

I did find one X that worked reliably: "modprobe -r iwlagn; modprobe iwlagn." Removing and reloading the driver always refreshed the card and then I could ifconfig up it and do a scan immediately, without any errors. But it would be best to know how to get the card back into a clean state, ready to scan, without resorting to that.

Offline

#3 2009-08-06 23:01:15

Mr.Cat
Member
Registered: 2008-09-27
Posts: 79

Re: Netcfg down ... then up

Thanks.
My driver is ath5k. And the problem seems to be phase-of-moon-and-timing-dependent for me as well.
I was developing a simple app which used netcfg (http://bbs.archlinux.org/viewtopic.php?pid=596520) and first thought that I was calling netcfg in a wrong way. But even netcfg-tray causes the same issue.

Last edited by Mr.Cat (2009-08-06 23:02:00)

Offline

#4 2009-08-07 09:12:05

xduugu
Member
Registered: 2008-10-16
Posts: 292

Re: Netcfg down ... then up

I recently found a bug report and a patch for iwlcore which should fix this issue, but I had no chance to test it until now.

http://bugzilla.intellinuxwireless.org/ … gi?id=1927

Offline

#5 2009-08-07 13:11:48

Profjim
Member
From: NYC
Registered: 2008-03-24
Posts: 658

Re: Netcfg down ... then up

Thanks for the pointer!

EDIT: But the patch just seems to suppress the problem (changes the response to SCAN COMPLETED) rather than fix it.

Anyway...if I understand correctly this is a patch against the iwlwifi driver in the kernel, so we'll have to wait for it to work its way into the kernel, right? (Or compile our own kernel.)

Last edited by Profjim (2009-08-07 13:24:39)

Offline

#6 2009-08-29 12:58:53

uastasi
Member
From: Salento - Italy
Registered: 2007-11-27
Posts: 247

Re: Netcfg down ... then up

I've the same issue with ath9k and previously with iwl3945. The only thing that worked for both modules was

rmmod <module> && modprobe <module>

Till the last battle, till the last bottle.
aur - twitter

Offline

#7 2009-08-29 13:44:32

rson451
Member
From: Annapolis, MD USA
Registered: 2007-04-15
Posts: 1,233
Website

Re: Netcfg down ... then up

uastasi wrote:

I've the same issue with ath9k and previously with iwl3945. The only thing that worked for both modules was

rmmod <module> && modprobe <module>

I can confirm that this works for me.  I've been doing this for about a month if I needed to change profiles for whatever reason.


archlinux - please read this and this — twice — then ask questions.
--
http://rsontech.net | http://github.com/rson

Offline

#8 2009-09-12 11:21:57

davvil
Member
Registered: 2008-05-06
Posts: 165

Re: Netcfg down ... then up

I just installed the kernel 2.6.31 from [testing] and the issue seems to be gone.

Offline

Board footer

Powered by FluxBB