FS#32769 - [systemd] Persistent network udev rule missing

Attached to Project: Arch Linux
Opened by Cedric Bellegarde (gnumdk) - Tuesday, 20 November 2012, 08:03 GMT
Last edited by Dave Reisner (falconindy) - Monday, 17 December 2012, 13:26 GMT
Task Type Support Request
Category Packages: Core
Status Closed
Assigned To Dave Reisner (falconindy)
Tom Gundersen (tomegun)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Seens recents update, udev doesn't honnor /etc/udev/rules.d/10-network.rules

So, on boot, network is working randomly...

Peristent network interface generator should be re-added to udev.
This task depends upon

Closed by  Dave Reisner (falconindy)
Monday, 17 December 2012, 13:26 GMT
Reason for closing:  Not a bug
Comment by Dave Reisner (falconindy) - Friday, 23 November 2012, 17:02 GMT
Upstream intentionally removed this, and that's what we follow. You can rename your devices based on MAC address to names outside the kernel namespace, such as "lan0" or "home". This will not changed in Arch.
Comment by JT (jalt) - Sunday, 16 December 2012, 18:49 GMT
  • Field changed: Percent Complete (100% → 0%)
The OP doesn't specify that he was using kernel namespace names (ethX, wlanX, etc), and I actually have the same problem, where udev does not seem to carry out the renaming rules.

More precisely, I have followed the wiki instructions (https://wiki.archlinux.org/index.php/Udev#Network_device) and 'ip l show' still reports eth0 and eth1 instead of net0 and net1. I doublechecked that my MACs were correct and lowercase.

It's a fresh install with the 2012.12.01 media, x86-64. If you tell me what other info you need, I can provide it.
Comment by Dave Reisner (falconindy) - Sunday, 16 December 2012, 18:53 GMT
I suggest you figure out what the actual problem is with udevadm test.

edit: Unsurprisingly, the rule in the wiki works just fine for me.
Comment by Cedric Bellegarde (gnumdk) - Monday, 17 December 2012, 10:10 GMT
I now use this to replace udev rules:

[gnumdk@arch ~]$ cat /etc/iftab
vlans mac 00:e0:4c:f9:6f:54
vlan5 mac 00:24:e8:4b:c8:d2
[gnumdk@arch ~]$ cat /etc/systemd/system/network.service
[Unit]
Description=Network Connectivity
Wants=network.target
Before=network.target

[Service]
Type=oneshot
RemainAfterExit=yes
EnvironmentFile=/etc/conf.d/network
ExecStart=/usr/sbin/ifrename -c /etc/iftab
ExecStart=/sbin/ip link set dev ${interface} up
ExecStart=/sbin/ip addr add ${address}/${netmask} dev ${interface}
ExecStart=/sbin/ip route add default via ${gateway}
ExecStop=/sbin/ip addr flush dev ${interface}
ExecStop=/sbin/ip link set dev ${interface} down

[Install]
WantedBy=multi-user.target
Comment by JT (jalt) - Monday, 17 December 2012, 13:18 GMT
falconindy, thanks for the tip. I was mistakenly using parentheses () instead of {} brackets, both of which render remarkably alike with my screen's DPI...

I am only now catching up with the whole systemd/udev thing, and some stuff in the wiki is not yet up to speed either. I will try to edit it to highlight my newbie mistake and add a link on how to use udevadm.

gnumdk, I considered using iftab, but that is deprecated.

In any case, my problem is now solved: the renamed interfaces work as expected.

Loading...