unraid 5 + udev + nic card driver load order issue


Recommended Posts

Hello

 

I'm having an issue with unraid's choice of which network card it picks first. I have eth0, and eth1, and of course the one I want to use as "primary" interface for the unraid is eth1, instead of eth0.

 

I've looked at

http://lime-technology.com/forum/index.php?topic=38487.15

 

Which had shed some light on how to deal with some of this, but nothing has worked. I've also tried "cating the 70-persistent-net.rules" into /etc/udev/70-persistent-net.rules on boot and issuing a udevadm trigger and udevadm restart? but nothing takes effect.

 

My current file after unraid boot looks like this;

 

# PCI device 0x8086:0x10c7 (ixgbe)

SUBSYSTEM==net, ACTION==add, DRIVERS==?*, ATTR{address}==00:1b:21:5f:cf:ec, ATTR{dev_id}==0x0, ATTR{type}==1, KERNEL==eth*, NAME=eth1

# PCI device 0x8086:0x10de (e1000e)

SUBSYSTEM==net, ACTION==add, DRIVERS==?*, ATTR{address}==00:25:b3:13:49:d1, ATTR{dev_id}==0x0, ATTR{type}==1, KERNEL==eth*, NAME=eth0

 

 

And I want to make the following happen:

# PCI device 0x8086:0x10c7 (ixgbe)

SUBSYSTEM==net, ACTION==add, DRIVERS==?*, ATTR{address}==00:1b:21:5f:cf:ec, ATTR{dev_id}==0x0, ATTR{type}==1, KERNEL==eth*, NAME=eth0

# PCI device 0x8086:0x10de (e1000e)

SUBSYSTEM==net, ACTION==add, DRIVERS==?*, ATTR{address}==00:25:b3:13:49:d1, ATTR{dev_id}==0x0, ATTR{type}==1, KERNEL==eth*, NAME=eth1

 

As you know the system isn't a real partition, so all changes after boot up are lost...

 

In theory, if I xz bzroot, and then cpio -idv, add my file to the "etc/udev/rules.d" and stuff it back together would it work, or is there some annoying checksum?

 

Aside from that or bashing my head against the desk doing a slackware-unraid setup, which I think I saw a guide how-to-do, is there any easier option? Can I somehow pull apart the image, update or make the 70-persistent-net.rules file static and get going?

 

 

Thanks,

 

Jonathan

Link to comment

Not a bad idea, I hadn't tried that.... but sadly after a quick test, it does the same.

 

root@Tower:/etc/udev/rules.d# cat 70-persistent-net.rules

# This file was automatically generated by the /lib/udev/write_net_rules

# program, run by the persistent-net-generator.rules rules file.

#

# You can modify it, as long as you keep each rule on a single

# line, and change only the value of the NAME= key.

 

# PCI device 0x8086:/sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 (ixgbe)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1b:21:5f:cf:ec", ATTR{dev_id}=="0x0", ATTR{type}=="1", K  ERNEL=="eth*", NAME="eth0"

 

# PCI device 0x8086:/sys/devices/pci0000:00/0000:00:19.0 (e1000e)

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:25:b3:13:49:d1", ATTR{dev_id}=="0x0", ATTR{type}=="1", K  ERNEL=="eth*", NAME="eth1"

root@Tower:/etc/udev/rules.d# dmesg | grep eth

reboot: HP Compaq Laptop series board detected. Selecting BIOS-method for reboots.

ACPI Error: Method parse/execution failed [\_SB_.PCI0._OSC] (Node ffff880073448de8), AE_ALREADY_EXISTS (20140926/psparse-53  6)

e1000e 0000:00:19.0 eth1: (PCI Express:2.5GT/s:Width x1) 00:25:b3:13:49:d1

e1000e 0000:00:19.0 eth1: Intel® PRO/1000 Network Connection

e1000e 0000:00:19.0 eth1: MAC: 8, PHY: 8, PBA No: FFFFFF-0FF

ixgbe 0000:01:00.0 eth0: NIC Link is Up 10 Gbps, Flow Control: RX/TX

root@Tower:/etc/udev/rules.d# uname -a

Linux Tower 3.18.5-unRAID #3 SMP Thu Feb 19 09:21:26 PST 2015 x86_64 Intel® Core2 Duo CPU    E8400  @ 3.00GHz Genuin  eIntel GNU/Linux

root@Tower:/etc/udev/rules.d#

 

Link to comment
  • 3 weeks later...

Hi

 

I was looking for a way to modify the udev rules upon boot of unraid, using the "persistent rules file". However upon pulling the bzroot apart, and re-packing it with a small change to the startup script to create the "70-persistent-net.rules", the udev rules are ignored. Though I can see my expected changes are reflected in the file at the time of boot (I add cat /etc/udev/xxx upon boot to see), the boot up console shows me they haven't worked (ixgbe loads first before e1000).... argh! :bandhead:

 

Looking into various startup files,  and config files, I noticed there was another "udev" and rules under /dev/.udev - so I tested creating a rules file there too - no luck.

 

I modified the /etc/rc.d/rc.S to create the following files

1. /etc/udev/rules.d/70-persistent-net.rules

2. /dev/.udev/rules.d/70-persistent-net.rules

...I tried creating this file before and after /etc/rc.d/rc.S calls udev startup "/etc/rc.d/rc.udev start", and no luck still.

 

dmesg reveals the 10gig card is still eth0.

 

I am not sure why the udev persistent rules aren't read in when udev is started.

 

In either case I had to do something aweful as a temporary work around until I can figure this out.... rename the ixgbe.ko until the system boots, and then rename it back and modprobe it.

 

I've looked but don't see much success with udev related on the forms, any ideas how to get the udev to read the persistent rules file?

 

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.