# [VERY UNRESOLVED] WARNING: net.wlan0 has started, but...

## Boinky

WARNING: net.wlan0 has started, but is inactive

Mac mini Intel, 1.66 GHz, dual core

```
uname -a
```

 *Quote:*   

> Linux 2.6.37-gentoo-r4 SMP i686

 

```
# lspci
```

 *Quote:*   

> AR5001 (rev 01)

 

dmesg: Atheros AR5414 chip found

.config

1.

 *Quote:*   

> # grep CONFIG_CFG80211 /usr/src/linux/.config
> 
> CONFIG_CFG80211=y
> 
> # CONFIG_CFG80211_DEVELOPER_WARNINGS is not set
> ...

 

2.

 *Quote:*   

> # grep CONFIG_MAC80211 /usr/src/linux/.config
> 
> CONFIG_MAC80211=y
> 
> CONFIG_MAC80211_HAS_RC=y
> ...

 

3.

 *Quote:*   

> grep CONFIG_ATH5K /usr/src/linux/.config
> 
> CONFIG_ATH5K=y
> 
> # CONFIG_ATH5K_DEBUG is not set

 

4.

 *Quote:*   

> *  net-wireless/madwifi-ng
> 
>       Latest version available: 0.9.4.4133.20100621
> 
>       Latest version installed: [ Not Installed ]
> ...

 

5.

```
# grep CONFIG_PACKET /usr/src/linux/.config
```

 *Quote:*   

> CONFIG_PACKET=y

 

# /etc/wpa_supplicant/wpa_supplicant.conf

 *Quote:*   

> # The below line not be changed otherwise we refuse to work
> 
> ctrl_interface=/var/run/wpa_supplicant
> 
> # Ensure that only root can read the WPA configuration
> ...

 

```
# cat /proc/net/wireless
```

 *Quote:*   

> Inter-| sta-|   Quality        |   Discarded packets               | Missed | WE
> 
>  face | tus | link level noise |  nwid  crypt   frag  retry   misc | beacon | 22
> 
>  wlan0: 0000    0     0     0        0      0      0      0      0        0

 

```
# dmesg | grep ath
```

 *Quote:*   

> [    0.916950] ath5k 0000:02:00.0: PCI INT A -> GSI 17 (level, low) -> IRQ 17
> 
> [    0.916962] ath5k 0000:02:00.0: setting latency timer to 64
> 
> [    0.917000] ath5k 0000:02:00.0: registered as 'phy0'
> ...

 

```
# cat /proc/net/dev
```

 *Quote:*   

> Inter-|   Receive                                                |  Transmit
> 
>  face |bytes    packets errs drop fifo frame compressed multicast|bytes    packets errs drop fifo colls carrier compressed
> 
>     lo:    2176      32    0    0    0     0          0         0     2176      32    0    0    0     0       0          0
> ...

 

```
# /etc/init.d/net.wlan0 start

bash: /etc/init.d/net.wlan0: No such file or directory
```

```
cd /etc/init.d/

# ln -s net.lo net.wlan0
```

```
/etc/init.d/net.wlan0 start
```

 *Quote:*   

> * Bringing up interface wlan0
> 
>  *   Starting wpa_supplicant on wlan0 ...
> 
> ctrl_iface exists and seems to be in use - cannot override it
> ...

 

```
/etc/init.d/net.wlan0 restart
```

 *Quote:*   

> * Bringing down interface wlan0
> 
>  *   Removing addresses
> 
>  *     Stopping wpa_cli on wlan0 ...                                                                                      [ ok ] *     Stopping wpa_supplicant on wlan0 ...                                                                               [ ok ] * Bringing up interface wlan0
> ...

 

```
# iwconfig
```

 *Quote:*   

> lo        no wireless extensions.
> 
> wlan0     IEEE 802.11abg  ESSID:off/any
> 
>           Mode:Managed  Access Point: Not-Associated   Tx-Power=20 dBm
> ...

 

```
# ifconfig wlan0 up
```

```
# iwlist wlan0 scan
```

 *Quote:*   

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

 

So, euh ... I'm trying to get my wireless up and running ... Any ideas?

----------

## percy_vere_uk

Boinky

I can't shed any light on this but I have pretty much the same problem. This seems to have come about after recent updates I think probably Baselayout2 and OpenRC Migration caused this. Just hope someone can come up with an answer!

percy

----------

## mikegpitt

I've noticed since the update to baselayout-2 my wireless device starts out as inactive, but when I fire up wpa_gui and select the network I want to connect to it becomes active and connects up as it should.

----------

## dmpogo

It's status is inactive when it has not yet associated with access point.

----------

## Boinky

 *Quote:*   

> It's status is inactive when it has not yet associated with access point.

 

And of course I didn't try my very best to get this thing associated  :Smile: . I wonder whether your answer might tickle my Atheros card to get associated. I very much like this kind of absurd humour    :Very Happy:   :Very Happy:   :Very Happy:   ...

----------

## KWhat

I had a similar issue after upgrading to baselayout 2.  Try setting rc_depend_strict="NO" in rc.conf and see if that helps.

----------

## percy_vere_uk

Hi

In my case I have found that setting " rc_depend_strict="NO" in rc.conf" makes no difference.  But when I fire up wpa_gui and disconnect wlan0 then go into my network mananager (wicd)  it finds my wireless connection and works fine. I have to repeat this procedure each time after a re-boot.

percy

----------

## Goverp

This probably won't help, but...  I use an Asus netbook usually on WiFi but sometimes with a USB G3 broadband dongle.  When I use the dongle, I turn off the WiFi to save power.  When I turn it back on, it sometimes won't come up.  it turns out that its become "blocked" ("rfkill list wifi"), and the cure is to unblock it ("rfkill unblock wifi") and restart net.wlan0.

----------

## greyspoke

The problem isn't the message about net.wlan0 being inactive, as I get that but my wlan0 becomes active soon after.  That is just openrc's way of saying that it has done its bit but the process it just started has yet to complete.  Or something like that.

So the problem appears to be that wpa_supplicant isn't connecting you.  Maybe try setting your network up with no security to start off?  What driver are you telling wpa_supplicant to use in your /etc/conf.d/net file - the default is 

```
wpa_supplicant_wlan0="-Dwext"
```

, but as you have a recent kernel with the ath5k driver installed I think you should use 

```
wpa_supplicant_wlan0="-Dnl80211"
```

.  The default ought to work as you have also enabled  cfg80211 wireless extensions compatibility in your kernel.  I haven't a clue how madwifi fits into all this.

ETA - another thing that I just remembered caused me grief when setting up my wireless network, you may have hotplugging enabled in your /etc/rc.conf, which may be the reason for the output that says wpa_supplicant is already running.  Set 

```
rc_hotplug="!net.*"
```

 to prevent any network devices from being started automatically by udev.

----------

## coolone

I got this error as well since yesterday, but i have another issue before.

https://forums.gentoo.org/viewtopic-t-882749.html

everything was fine before yesterday! if that is really a problem from openrc?

----------

## Hendrikus

I had also the same warning messages after the update to baselayout-2, and got problems with wpa-supplicant. (I work also wireless, with zydas zd1211rw-driver)

My problems solved by using wicd:

After trying out several configurations and offered solutions on forums, I unmerged wpa_supplicant, removed the wpa_supplicant.conf scripts in /etc and in /etc/wpa_supplicant/ and removed /etc/conf.d/net

Also removed the symlink /etc/init.d/net.wlan0 and removed also any startup service from net.wlan0 in /etc/runlevels (rc-update del net.wlan0 boot, for example) Keep net.lo in /etc/runlevels/boot

I made a new empty file /etc/conf.d/net and emerged net-misc/wicd.

This will emerge wpa_supplicant (again) and -of course- wicd.

Check if the (re-)emerge of wpa_supplicant created a file /etc/wpa_supplicant.conf or /etc/wpa_supplicant/wpa_supplicant.conf. If so, delete them.

Add wicd to the startup service: rc-update add wicd boot

Check file /etc/conf.d/wpa_supplicant: only one line must be in: wpa_supplicant_args=""

If you use dhcp, then you need to edit /etc/dhcpcd.conf. I had to put in the lines:

```
hostname

nohook lookup-hostname

noipv4ll

require dhcp_server_identifier

option interface_mtu
```

And in /etc/rc.conf:

```
RC_PLUG_SERVICES="net.lo !net.eth0"

RC_NET_STRICT_CHECKING="lo"
```

Don't do anything with the configuration files from wicd. Just reboot, and IF ok, wicd will start automatic and you'll see an icon on the panel, looks like a small monitor with a warning sign on it. Just click on it and the configuration is really simple and easy.

Since I use wpa_supplicant with wicd, I don't have any warning-messages any more; and it connects without problems. The only thing is, that it takes a few seconds more before it connects after bootup than wpa_supplicant did. Maximum 10 seconds after the desktop is ready, the icon will show a green bar (or yellow till red, depending on the strength of the connection).

----------

## pertplus

Not sure how helpful this will be, but I use wpa_supplicant and I get the same message "not active"), BUT it still works fine. In my case the ssid is hardcoded in the wpa_supplicant.conf

----------

## gerdesj

 *pertplus wrote:*   

> Not sure how helpful this will be, but I use wpa_supplicant and I get the same message "not active"), BUT it still works fine. In my case the ssid is hardcoded in the wpa_supplicant.conf

 

If you have ifplugd or similar running then the interface *will* come up as inactive to start with.  The module is loaded but dhcpcd (or similar) has not finished.  This is normal.

Also, you have put the ssid and stuff in the right place.

So, from what you describe - everything is working correctly.

Cheers

Jon

----------

## gerdesj

Some excerpts from a working system:

Change to your country code

```

# /etc/wpa_supplicant/wpa_supplicant.conf

# jglaptop

# 30 Jan 2010

ctrl_interface=/var/run/wpa_supplicant

eapol_version=1

ap_scan=1

fast_reauth=1

country=GB

network={

        ssid="<MYSSID>"

        psk="<MYPSK"

}

```

Change to your driver (-D) 

```

#######################################################

# /etc/conf.d/net 

# jglaptop

# 26 Apr 2009

modules="dhclient

         iproute2"

modules_wlan0="!plug"

wpa_supplicant_wlan0="-Dwext"

config_wlan0="dhcp"

```

Hope this helps - it should be that simple.  

Wifi on Linux: Keep an eye on "dmesg" and "ip a" etc.  Make sure that your firmware is available.    Keep your kernel up to date - there have been many changes and updates.

If you use wicd or network manager instead of statically setting things up then this will probably not help much

Cheers

Jon

----------

