Adding new network (USB 802.11n dongle) clobbers 'persistent naming'
by Johncc330 from LinuxQuestions.org on (#6DB32)
I'm trying to understand the persistent naming system to be able to add a new wlan dongle (802.11n). When I add the dongle it seems to change the ethxx assignments.
The system has two net-cards (because the motherboard lan broke down). rc.inet1.conf has eth0 and eth1 defined.
From the dmesg I extracted:
Code:[ 7.711543] r8169 0000:01:00.0 eth0: RTL8168h/8111h, xx:9d:02, XID 541, IRQ 33
[ 7.713256] r8169 0000:01:00.0 eth0: jumbo features [frames: 9194 bytes, tx checksumming: ko]
[ 7.719698] r8169 0000:03:00.0 eth1: RTL8168e/8111e, xx:78:55, XID 2c2, IRQ 34
[ 7.721402] r8169 0000:03:00.0 eth1: jumbo features [frames: 9194 bytes, tx checksumming: ko]
...
[ 9.585174] r8169 0000:03:00.0 eth125: renamed from eth1
[ 9.591230] r8169 0000:03:00.0 rename_eth125: renamed from eth125
[ 9.758219] r8169 0000:01:00.0 eth126: renamed from eth0
[ 9.770258] r8169 0000:01:00.0 eth2: renamed from eth126
[ 9.802604] r8169 0000:03:00.0 eth0: renamed from rename_eth125(I shortened the MAC addresses a bit)
and from /etc/udev/rules.d/70-persistent-net.rules:
Code:# Disabled because the motherboard LAN failed
# SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:9e:bf", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
# PCI Express device 0x10ec:/sys/devices/pci0000:00/0000:00:03.1/0000:01:00.0 (r8169)
# tp-link TG-3468(UN)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:78:55", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
# PCI Express device 0x10ec:/sys/devices/pci0000:00/0000:00:03.1/0000:01:00.0 (r8169)
# tp-link TG-3468(UN)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:9d:02", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"From this I tried to reason where the actual eth assignment comes from:
Code:Time Card 0 Card 1
xx:9d:02 xx:78:55
7.711543 -> eth0 Initial assignment (by driver or rules?)
7.719698 -> eth1 Initial assignment (by driver or rules?)
9.585174 -> eth125 Who does this?
9.591230 -> rename_eth125 Who does this?
9.758219 -> eth126 Who does this?
9.770258 -> eth2 Who does this?
9.802604 -> eth0 Who does this?I adapted the firewall and other items to eth0/eth2. Now, if I insert the 802.11n
dongle, these addresses get all mixed up. eth2 even disappears (is this because of the lack of eth2 definition in rc.inet.conf?).
Q1: How can I add the dongle without changing the above assignations (or at least so that in the future I really have 'persistent' assignments?
Q2: I'd like to understand what I'm doing here - anyone know a document which explains clearly what is going on? I've found some explanations, but they're for Redhat, and other distros.
The system has two net-cards (because the motherboard lan broke down). rc.inet1.conf has eth0 and eth1 defined.
From the dmesg I extracted:
Code:[ 7.711543] r8169 0000:01:00.0 eth0: RTL8168h/8111h, xx:9d:02, XID 541, IRQ 33
[ 7.713256] r8169 0000:01:00.0 eth0: jumbo features [frames: 9194 bytes, tx checksumming: ko]
[ 7.719698] r8169 0000:03:00.0 eth1: RTL8168e/8111e, xx:78:55, XID 2c2, IRQ 34
[ 7.721402] r8169 0000:03:00.0 eth1: jumbo features [frames: 9194 bytes, tx checksumming: ko]
...
[ 9.585174] r8169 0000:03:00.0 eth125: renamed from eth1
[ 9.591230] r8169 0000:03:00.0 rename_eth125: renamed from eth125
[ 9.758219] r8169 0000:01:00.0 eth126: renamed from eth0
[ 9.770258] r8169 0000:01:00.0 eth2: renamed from eth126
[ 9.802604] r8169 0000:03:00.0 eth0: renamed from rename_eth125(I shortened the MAC addresses a bit)
and from /etc/udev/rules.d/70-persistent-net.rules:
Code:# Disabled because the motherboard LAN failed
# SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:9e:bf", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
# PCI Express device 0x10ec:/sys/devices/pci0000:00/0000:00:03.1/0000:01:00.0 (r8169)
# tp-link TG-3468(UN)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:78:55", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
# PCI Express device 0x10ec:/sys/devices/pci0000:00/0000:00:03.1/0000:01:00.0 (r8169)
# tp-link TG-3468(UN)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="xx:9d:02", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"From this I tried to reason where the actual eth assignment comes from:
Code:Time Card 0 Card 1
xx:9d:02 xx:78:55
7.711543 -> eth0 Initial assignment (by driver or rules?)
7.719698 -> eth1 Initial assignment (by driver or rules?)
9.585174 -> eth125 Who does this?
9.591230 -> rename_eth125 Who does this?
9.758219 -> eth126 Who does this?
9.770258 -> eth2 Who does this?
9.802604 -> eth0 Who does this?I adapted the firewall and other items to eth0/eth2. Now, if I insert the 802.11n
dongle, these addresses get all mixed up. eth2 even disappears (is this because of the lack of eth2 definition in rc.inet.conf?).
Q1: How can I add the dongle without changing the above assignations (or at least so that in the future I really have 'persistent' assignments?
Q2: I'd like to understand what I'm doing here - anyone know a document which explains clearly what is going on? I've found some explanations, but they're for Redhat, and other distros.