# net.wlan0 does not come up during boot

## massimo

As the topic reveals my wifi interface does not come up during boot, at all:

```

* Bringing up interface wlan0

 *   ERROR: interface wlan0 does not exist

 *   Ensure that you have loaded the correct kernel module for your hardware

 * ERROR: net.wlan0 failed to start

```

Right after boot I login and run /etc/init.d/net.wlan0 start which almost immediately assigns an IP address to that interface - network connection established. I tried changing things via rc.conf, hence rc_depend_strict and rc_hotplug but this did not help.

This system has been installed just a few days ago, since I received a used SSD drive onto which I installed Gentoo (amd64, zen-sources-3.1). For the wifi connection I use and USB device which usually works by loading zd1211rw through /etc/conf.d/modules.

Maybe the time between loading the module and starting wlan0 is too short for the interface to come up - as I said the system is installed on a SSD and this drive boot pretty fast (< 3 seconds to login after hitting enter in grub).

Anything else I can do or try (again)?

----------

## derk

A thought .. did you set parallel in /etc/rc.conf ?  if so unset it 

what runlevel is net.wlan0 installed at .. what software are you using to set-up wlan0  does it need to run before net.wlan0?  

just some thoughts not enough detail to decide what is best mode .. if it previously worked .. then the timing or order of events is the issue

----------

## doctaweeks

After boot and before you manually start net.wlan0 are these lines in dmesg related to that network interface indicating some type of failure? If things aren't quite ready yet, I suspect something will show up there.

You can also check dmesg after you manually start net.wlan0 for related lines and then look to see what didn't happen earlier automatically. If anything odd shows up in either case you can post here and it might help figure out what's going on.

----------

## massimo

 *derk wrote:*   

> A thought .. did you set parallel in /etc/rc.conf ?  if so unset it 

 

No, this I've never ever set. Not even on my old box.

 *derk wrote:*   

> 
> 
> what runlevel is net.wlan0 installed at .. what software are you using to set-up wlan0  does it need to run before net.wlan0?  
> 
> 

 

default run-level

I put the required information in /etc/conf.d/net and /etc/wpa_supplicant/wpa_supplicant.conf and the module is loaded as stated in the initial post.

 *derk wrote:*   

> 
> 
> just some thoughts not enough detail to decide what is best mode .. if it previously worked .. then the timing or order of events is the issue

 

Basically I took the configuration of my old system and put it to my new system - at the moment I can not think of anything which would have that impact.

 *doctaweeks wrote:*   

> 
> 
> After boot and before you manually start net.wlan0 are these lines in dmesg related to that network interface indicating some type of failure? If things aren't quite ready yet, I suspect something will show up there.
> 
> 

 

Nothing which shows any problem, warning or error.

 *doctaweeks wrote:*   

> 
> 
> You can also check dmesg after you manually start net.wlan0 for related lines and then look to see what didn't happen earlier automatically. If anything odd shows up in either case you can post here and it might help figure out what's going on.
> 
> 

 

My last resort would be putting the driver in the kernel (don't know about the required firmware though), hence it might get loaded a bit earlier, thus it's there when wlan0 tries to come up. Maybe it helps putting the USB drivers (EHCI, OHCI) - which I until now always compiled as module - in the kernel as well since it's an USB Wifi device.

Another thing I was thinking about if there is an option somewhere where I can set a timeout which would require the system to wait a few seconds after the modules were loaded through /etc/init.d/modules.

----------

## massimo

Nothing has basically changed from a system's configuration point of view but that fact that I reorganised my disks in a way that I'm now using a btrfs raid1 for /home, /opt, /var, /usr/src, /usr/portage. Magically my problem was solved by this change, hence Wifi comes up without any issues (at least the last four to five times in a row). It's still frustrating not being able to tell the exact reason for this problem but I still assume the Wifi driver has not enough time to do it's magic right before net.wlan0 tries to start.

For me this topic remains unsolved.

----------

