# No notwork at boot

## d135-1r43

All device management on my notebook is made by udev. Unfortunately, udev tries to start all network related init-scripts although there is normally neither a cable plugged in nor a wifi hotspot available. What can I do to force udev not to load net.ethx and ipw3945d (my wlan driver daemon)? Net.lo is needed, of course. 

```
# rc-update show 

               acpid |      default                  

           alsasound |      default                  

            bootmisc | boot                          

             checkfs | boot                          

           checkroot | boot                          

               clock | boot                          

         consolefont | boot                          

            hostname | boot                          

             keymaps | boot                          

         laptop_mode |      default                  

               local |      default nonetwork        

          localmount | boot                          

             modules | boot                          

              net.lo | boot                          

           rmnologin | boot                          

           syslog-ng |      default                  

             urandom | boot                          

          vixie-cron |      default       
```

----------

## iron999mike

According to the output of your rc-update show command it doesn't look like either of those init scripts are being loaded. I am unfamilar with udev loading init scripts, but maybe it would be helpful if you posted the your relevent udev configs/logs that load these init scripts. All your current output shows us is that it isn't loaded at a certain runlevel. I am also unfamilar with this but you might want to check out the nonetwork runlevel, might be helpful, might not:

http://gentoo-wiki.com/Rc-update

Especially check out section 4e here:

http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=4

It seems to pertain to your situation.

----------

## d135-1r43

I don't think that my netX-scripts are loaded by any kind of runlevel. Are there any dependencies that force the loading of network interfaces?

I think udev tries to activate everything it could find. This is my udev configuration. As far as I know there are no changes to the default conf shipped with the ebuild. 

```
 # cat 70-persistent-net.rules 

# PCI device 0x8086:0x4227 (ipw3945)

SUBSYSTEM=="net", DRIVERS=="?*", ATTRS{address}=="00:13:02:a4:c8:d4", NAME="eth2"

 # cat 75-persistent-net-generator.rules 

# these rules generate rules for persistent network device naming

ACTION=="add", SUBSYSTEM=="net", KERNEL=="eth*|ath*|wlan*|ra*|sta*" \

   NAME!="?*", DRIVERS=="?*", GOTO="persistent_net_generator_do"

GOTO="persistent_net_generator_end"

LABEL="persistent_net_generator_do"

# build device description string to add a comment the generated rule

SUBSYSTEMS=="pci", ENV{COMMENT}="PCI device $attr{vendor}:$attr{device} ($attr{driver})"

SUBSYSTEMS=="usb", ENV{COMMENT}="USB device 0x$attr{idVendor}:0x$attr{idProduct} ($attr{driver})"

SUBSYSTEMS=="ieee1394", ENV{COMMENT}="Firewire device $attr{host_id})"

SUBSYSTEMS=="xen", ENV{COMMENT}="Xen virtual device"

ENV{COMMENT}=="", ENV{COMMENT}="$env{SUBSYSTEM} device ($attr{driver})"

IMPORT{program}="write_net_rules $attr{address}"

ENV{INTERFACE_NEW}=="?*", NAME="$env{INTERFACE_NEW}"

LABEL="persistent_net_generator_end"
```

I can't find anything that tells udev to load netX or ipw3945.

----------

## iron999mike

Are you trying to stop Udev from finding your devices completely? Or are you just trying to stop network services from trying to be brought up?

As far as i know as long as you don't have net.ethX set  to boot up in a runlevel, it should not boot up unless you have it configured somewhere else. How do you know that the eth.x init script is being ran? If I remove my net.eth0 from the default runlevel I don't get any network services and no init script is run (eth0 is my only card). Can I ask what makes you think that Udev is loading the init scripts? Udev has nothing to do with loading your network devices  (finding them and assigning drivers, yes, but not bringing the network up).

----------

## d135-1r43

Of course I want udev to recognize my hardware and modprobe the needed modules, but I don't want it to load the init scripts. 

(Unfortunately bootlog doesn't work with gen/bootsplash. So I had to copy the stuff manually)

I think these messages during bootup are in relation to udev, not to rc:

```
* Device initiated services: ipw3945d net.eth0 net.eth1  [ok]
```

This line appears directly before the first init-scripts are executed by rc.

----------

## iron999mike

Once again i am unsure why you think it is udev calling an init script (can you find where udev calls the init scripts)?

I am having areally hard time picturing the state of your machine and can only offer you this advice, as this is what I do when i have trouble.

Eliminate as much complexity as you can. 

-I would start over on your networking and build it up piece by piece and make sure each piece work as it goes: 

-I would disable your wlan modules in the kernel, don't have the kernel load the module (this would prevent even udev from finding it, since you think that is the problem), make sure the init script is not being run buy rc-update, etc. This would prevent even udev from finding it, since you think that is the problem.

-I would also do the same with your ethernet card. 

-Make sure no networking starts at all besides loopback (Net.lo)

Then:

-Only enable your ethernet card and make sure it works when you are connected.

-Then try to set up a no network softlevel (or user defined) that will allow you to boot into this when you aren't connected by a land line (see link in post above).

-You can make it boot into this profile by default in Grub.

-Make sure this works.

-Then only after this works try the same for your wlan. I chose ethernet first because wlan is often more complex then ethernet to set up.

I am sorry I could not be more help, but like I said, I am really having a hard time seeing what state the machine is in and  without some more information there is nothing I can do. Keep me updated and I will try to help if I can.

----------

## cyrxi

 *d135-1r43 wrote:*   

> 
> 
> I think these messages during bootup are in relation to udev, not to rc:
> 
> ```
> ...

 

I'm assuming you figured this out by now, but since I stumbled across this while searching for something else, here's the solution:

It has to do with HOT/COLD plugging.  Simply edit /etc/conf.d/rc and look for the line RC_PLUG_SERVICES=""

put anything you don't want to start up in there with an "!" in front of it, e.g.

```
RC_PLUG_SERVICES="!ipw3945d !net.eth0 !net.eth1"
```

----------

## d135-1r43

Thanks! My workaround was to set the timeout for DHCP on a very low level. The explicit exclusion in conf.d/rc now works perfectly.

----------

