# udev giving network error on boot

## razixx

It's been a while since playing around with Gentoo, wish I would have never left the scene, finally got it installed again but am running into problems at boot.  During the boot up it pauses at uevents for a really long time, looks something like this

```

* Waiting for uevents to be processed ...                    #pauses for about a minute

*UDEV:  Your system has a problem assigning persistent names        # then continues on here

*to these network interfaces:  eth0_rename

* Checking persistent-net rules:

* Found no duplicate names in persistent-net rules,

* There must be some other problem!

```

I tried fetching logs but am not sure where to find them, and syslog-ng doesn't log the necessary info soon enough in the boot process to copy and paste so I had to use scroll lock.

I didn't notice this happen untill after I emerged openntpd.  I have two network interfaces net.eth0 and net.eth1, currently I'm plugged into net.eth1.  any ideas?  If you need any other logs let me know and I will try and get them thx in advance.Last edited by razixx on Thu Oct 08, 2009 12:42 am; edited 5 times in total

----------

## DONAHUE

shift the plug

----------

## razixx

I can only seem to get net.eth1 one to work, it doesn't see my net.eth0??

/etc/conf.d/net

```

config_eth0=( "dhcp" )

config_eth1=( "dhcp" )

```

lspci output 

```

00:08.0 Bridge: nVidia Corporation MCP55 Ethernet (rev a2)

00:09.0 Bridge: nVidia Corporation MCP55 Ethernet (rev a2)

```

ifconfig output

```

eth1      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03

          inet addr:192.168.1.138  Bcast:192.168.1.255  Mask:255.255.255.0

          inet6 addr: fe80::64b:80ff:fe80:8003/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:180 errors:0 dropped:0 overruns:0 frame:0

          TX packets:177 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:18670 (18.2 KiB)  TX bytes:24977 (24.3 KiB)

          Interrupt:26 Base address:0xc000

lo        Link encap:Local Loopback

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

```

```

gentoo init.d # rc-update show default

               local | default

            net.eth0 | default

            netmount | default

                sshd | default

           syslog-ng | default

          vixie-cron | default

```

/etc/init.d/net.eth0 restart output

```

 * Stopping eth0

 *   Bringing down eth0

eth0: error fetching interface information: Device not found

eth0: error fetching interface information: Device not found

 *     Shutting down eth0 ...

eth0: error fetching interface information: Device not found              [ ok ]

 * Starting eth0

eth0: error fetching interface information: Device not found

eth0: error fetching interface information: Device not found

eth0: ERROR while getting interface flags: No such device

eth0: ERROR while getting interface flags: No such device

eth0: error fetching interface information: Device not found

eth0: ERROR while getting interface flags: No such device

 *   Bringing up eth0

 *     dhcp

 *       Running dhcpcd ...

eth0: dhcpcd 4.0.13 starting

eth0: read_interface: No such device                                      [ ok ]

eth0: error fetching interface information: Device not found

 *       eth0 received address

eth0: ERROR while getting interface flags: No such device

```

Maybe I'm missing something, not sure, I'll wait to see if anyone has any ideas or needs more input, worse case scenerio, i'll re-install lol

----------

## DONAHUE

```
rm /etc/init.d/net.eth0

ln -s /etc/init.d/net.lo /etc/init.d/net.eth1

rc-update del net.eth0 default

rc-update add net.eth1 default
```

does ifconfig -a show eth0 or is it totally dead?

----------

## razixx

Just to give an update, I did do a reinstall of gentoo but this time plugged into eth0.  but now I'm having the exact same problem only reversed.  Pauses during uvents on boot.  

```

tux ~ # ifconfig -a

eth0      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          inet addr:192.168.1.138  Bcast:192.168.1.255  Mask:255.255.255.0

          inet6 addr: fe80::64b:80ff:fe80:8003/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:96 errors:0 dropped:0 overruns:0 frame:0

          TX packets:59 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:12196 (11.9 KiB)  TX bytes:7985 (7.7 KiB)

          Interrupt:26 Base address:0x8000 

eth1_rena Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

          Interrupt:23 Base address:0xc000 

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

sit0      Link encap:IPv6-in-IPv4  

          NOARP  MTU:1480  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

```

```

tux ~ # ifconfig

eth0      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          inet addr:192.168.1.138  Bcast:192.168.1.255  Mask:255.255.255.0

          inet6 addr: fe80::64b:80ff:fe80:8003/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:132 errors:0 dropped:0 overruns:0 frame:0

          TX packets:83 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:15304 (14.9 KiB)  TX bytes:13121 (12.8 KiB)

          Interrupt:26 Base address:0x8000 

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

```

----------

## DONAHUE

boot a cd mount the gentoo partition

```
rm /mnt/gentoo/etc/udev/rules.d/70-persistent-net.rules
```

 don't worry it rewrites itself

```
ls -l  /mnt/gentoo/etc/init.d/net.*
```

should show only

```
/mnt/gentoo/etc/init.d/net.lo

/mnt/gentoo/etc/init.d/net.eth0 -> net.lo
```

If you have a  *Quote:*   

> /mnt/gentoo/etc/init.d/net.eth1 -> net.lo

  rm it.

```
nano /mnt/gentoo/etc/conf.d/net
```

and edit every line in it to start with #; yes, comment it all out.

try a reboot

----------

## razixx

Thx donahue, that worked like a charm.  When I opened the 

```

/mnt/gentoo/etc/udev/rules.d/70-persistent-net.rules

```

File it looked like it was configuring one interface to be both eth0 and eth1.  Weird and a big headache. Now I should finally be able to get on with business.. lol thx again.

----------

## razixx

Ok I thought this solved my problem, well it did sorta...haha  ummm..  Now when I type ifconfig, it only shows the local loopback device.  I have no connectivity to my computer now so I can't show any of the output.    It seems that when udev recreates that new file, it puts two entires in the file both with the same hardware address, and calls one eth0 and the other eth1.  I would like to think that both network ports would have a unique hardware address no?

Board : Asus M2N SLI DELUXE Nforce 570 Chip

The more reading I do online the more I'm starting to think it's this model of motherboard and the way asus designed it.

----------

## DONAHUE

run  

```
ifconfig -a
```

 to verify the nics are still getting drivers and that there are no strange names

```
ls -l /etc/init.d/ 
```

 verify that the link   *Quote:*   

> net.eth0 -> net.lo

  exists but  *Quote:*   

> net.eth1 -> net.lo

  does not.

```
cat /etc/conf.d/net
```

verify that no lines are present or all lines are commented.

```
rm /etc/udev/rules.d/70-persistent-net.rules
```

```
rc-update show
```

verify net.eth0 is present but net.eth1 is not

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

----------

## razixx

ifconfig -a 

```

eth0      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          inet addr:192.168.1.138  Bcast:192.168.1.255  Mask:255.255.255.0

          inet6 addr: fe80::64b:80ff:fe80:8003/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:279 errors:0 dropped:0 overruns:0 frame:0

          TX packets:195 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:26500 (25.8 KiB)  TX bytes:29933 (29.2 KiB)

          Interrupt:26 Base address:0x8000 

eth1      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          BROADCAST MULTICAST  MTU:1500  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

          Interrupt:23 Base address:0xc000 

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

sit0      Link encap:IPv6-in-IPv4  

          NOARP  MTU:1480  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

```

```

tux rules.d # ls -l /etc/init.d/net*

lrwxrwxrwx 1 root root     6 Oct  4 14:57 /etc/init.d/net.eth0 -> net.lo

-rwxr-xr-x 1 root root 30696 Sep 15 10:50 /etc/init.d/net.lo

-rwxr-xr-x 1 root root  3311 Sep 15 10:50 /etc/init.d/netmount

tux rules.d # 

```

```

tux rules.d # cat /etc/conf.d/net

# This blank configuration will automatically use DHCP for any net.*

# scripts in /etc/init.d.  To create a more complete configuration,

# please review /etc/conf.d/net.example and save your configuration

# in /etc/conf.d/net (this file :]!).

#dns_domain_lo=( "homenetwork" )

config_eth0=( "dhcp" )

#config_eth1=( "null" )

tux rules.d # 

```

NOTE: If I comment the one line, next time I reboot my computer, none of my nics will initialise I will only have a loopback device.

/etc/udev/rules.d/70-persistent-net.rules recreates itself like this everytime

```

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

```

```

tux rules.d # rc-update show    

            bootmisc | boot                          

             checkfs | boot                          

           checkroot | boot                          

               clock | boot                          

         consolefont | boot                          

            hostname | boot                          

             keymaps | boot                          

               local |      default nonetwork        

          localmount | boot                          

             modules | boot                          

            net.eth0 |      default                  

              net.lo | boot                          

            netmount |      default                  

           rmnologin | boot                          

                sshd |      default                  

           syslog-ng |      default                  

             urandom | boot                          

          vixie-cron |      default 

```

```

tux rules.d # ifconfig

eth0      Link encap:Ethernet  HWaddr 04:4b:80:80:80:03  

          inet addr:192.168.1.138  Bcast:192.168.1.255  Mask:255.255.255.0

          inet6 addr: fe80::64b:80ff:fe80:8003/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:520 errors:0 dropped:0 overruns:0 frame:0

          TX packets:345 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000 

          RX bytes:47826 (46.7 KiB)  TX bytes:57821 (56.4 KiB)

          Interrupt:26 Base address:0x8000 

lo        Link encap:Local Loopback  

          inet addr:127.0.0.1  Mask:255.0.0.0

          inet6 addr: ::1/128 Scope:Host

          UP LOOPBACK RUNNING  MTU:16436  Metric:1

          RX packets:0 errors:0 dropped:0 overruns:0 frame:0

          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:0 

          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

tux rules.d # 

```

Sorry for the really long post, I just want you to see that I'm doing it.

----------

## razixx

Yeah, after my long last post, I did exactly as you suggested, and after rebooting, I still have connectivity.  Where as before I'd have to wipe udev rules and restart before I can bring back the nic.  Good job, and thx.  I wish I knew a little more as to what was causing it to do this..

----------

## DONAHUE

everything looks normal except  *Quote:*   

> NOTE: If I comment the one line, next time I reboot my computer, none of my nics will initialise I will only have a loopback device.

  Ordinarily an empty /etc/conf.d/net should be the same as config_eth0=( "dhcp" ) 

suggest support for auto mounting; mouse in the terminal; keeping the clock set 

```
emerge dbus hal udev gpm ntp

rc-update add dbus default

rc-update add hald default

rc-update add gpm default

rc-update add ntpd default

rc-update add ntp-client default
```

tux rules.d is an unusual machine name, curious, where is it from?

----------

## razixx

Yeah I'll try that out.

The tux portion is my pc name, got it from the install docs, and the rules.d was my current working directory at the time.  /etc/udev/rules.d/

wow, anyone with an m2n sli deluxe board, stay away, you'll rip your hair out  lol jk  I'm pretty sure I've installed gentoo with this board before, don't think I ever ran into any of these problems.  But I guess it's been a good learning experience thx again donaue for your help

----------

## DONAHUE

I'm on an m2n sli deluxe   :Laughing:  ... as someone once said "Results may vary...

----------

## razixx

It's still seems that i'm having issues with udev, the workaround or fix is to delete my /etc/udev/rules.d/70-persistant-rules.net file before every restart.  But there has to be a more concrete reason as to why this is happening.  When I work off the ubuntu cd and compare the 70-persistant-rules.net file, they are identical, so something else is going wrong somewhere.   

Anyone have any other ideas?  or at least something I can try?

----------

## d2_racing

You have a big problem, because :

```

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1" 

```

The address is the same, so do you have 2 network cards or only one ?

It's the first time that I see that problem.

----------

## DONAHUE

good eye d2!!

he has 2, I have same board, m2n sli deluxe, I'm luckier, asus gave me different mac numbers.

The BIOS does allow disabling the NIC's individually.

----------

## d2_racing

So, can you disable one inside the bios and delete the udev rules and retry ?

If he ends up with 2 lan card again, then it's a udev bug for sure.

----------

## razixx

Great thank you for the reply, I thought the mac addresses were suspicious as well, I can live having one work properly, on the other hand, it kinda bugs me that I have two and they both can't work at the same time...lol.   Do you think if I updated my bios version, I know I'm not running on the latest, that it would make a difference?  Or am I a poor sucker that ended up with two identical hard coded macs?

I'll try what d2 suggested and then I'll get back to you guys later on tonight.

----------

## razixx

Ok so I did as D2 suggested, I removed my /etc/udev/rules.d/70-persistant-net-rules   file rebooted, disabled nic 2 in the bios and this is the file that it created below when it came back online.

```

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0" #with nic 2 disabled

```

I then did this a second time, removing net rules file, rebooting, disabling nic 1, enabled nic 2, udev generated the file below when the machine came back online.

```

# PCI device 0x10de:0x0373 (forcedeth)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="04:4b:80:80:80:03", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

```

Notice how both macs are still the same.  I only need one nic, but I'll try updating my bios just for kicks, although I don't know if it would hold mac setting within the actual bios itself.  but worth a try I guess.

----------

## d2_racing

We have two choices, it's a bios bug or an udev bug.

Try to update your bios and post the result.

----------

## razixx

ok so I upgraded my bios version from 1501 to 1701, re-enabled both interfaces, booted the machine up, deleted my net-rules file, and reboot to find myself back at square one.    :Laughing: 

```

* Waiting for uevents to be processed ...                    #pauses for about a minute 

*UDEV:  Your system has a problem assigning persistent names        # then continues on here 

*to these network interfaces:  eth0_rename 

* Checking persistent-net rules: 

* Found no duplicate names in persistent-net rules, 

* There must be some other problem! 

```

Perhaps it's a bug with udev?  :Rolling Eyes: 

----------

## Mike Hunt

Did you re-emerge udev after deleting the rules?

 :Arrow:   Look at this thread

----------

## DONAHUE

mac addresses still duplicate?

----------

## razixx

Thx for the thread link, I'll give that a try today after work, won't be till the evening sometime.  

As for the macs, both interfaces still have the exact same mac.  Only difference is, when one is disabled, only one udev entry is created not two.  Doesn't matter which one is enabled though, they both have the exact same mac.

----------

## DONAHUE

mac addresses are burned into nic chips. As a final check for some sort of spoofing, boot whatever linux systems and cds you have laying around, run ifconfig -a, check the macs. If both the same in different linux the chipburner screwed up, the good news you can live with it, unless you need two nics enabled, in which case you are in the market for an add-on nic..

----------

## razixx

Ok guys, I tried was was suggested in the forum link above and it still didn't solve my problem.

```

rm /etc/udev/rules.d/*

emerge -auv udev

init 6

```

rebooted twice after this and then got the long pause while processing uevents.

----------

## DONAHUE

disable one of 'em and go on with life.   :Smile: 

----------

## razixx

Yeah, I guess, that's what I'll have to do.. haha, oh well, thanks for your help guys.  :Laughing: 

----------

## DONAHUE

complain to asus and nvidia? or sing in the shower -- whichever is  better for morale  :Laughing: 

----------

## d2_racing

In fact  :Razz:  Sing baby sing  :Razz: 

----------

## nixnut

Moved from Installing Gentoo to Networking & Security.

Not about getting gentoo installed, so moved here

----------

## modsRule

Sorry for the bump, but having just gone through this problem, I thought it useful if I post my solution somewhere where others can find it.

The problem I had was that because I was bonding eth0 and eth1 together they both got assigned a new virtual mac address, leading to udev getting confused because they both had the same mac...

Clearing udev rules didn't help, it just recreated them with one of the NICs _rename'd, or just refused plain to accept the setup.

The actual problem was because I had had one non-clean shutdown and the bonding driver hadn't told the NIC to re-init before shutdown with the mac from its eeprom. So no amount of rebooting/udev tweaking could fix this.

The solution was: clear the persistent net rules before shutting down and unplugging the computer for a few minutes, to let it drain down all the capacitors. When it next starts, the NIC re-reads the eeprom instead and loads with its real mac. Udev is now happy again because there are no duplicate macs, and re-creates the rules correctly.

Annoying to have to do everytime it doesn't correctly shutdown (though luckily that isn't very often), but it lets me use both my NICs again!

----------

