You are not logged in.

#1 2014-05-15 20:48:50

carbonosity
Member
Registered: 2014-05-15
Posts: 1

Systemd Network Device Naming via Link Files

So I am trying to use the functionality Tom described in the links below to have a ".link" file placed in "/etc/systemd/network" name an interface instead of using udev rules directly.  Yes, udev rules directly do work, but I am investigating this functionality and wonder if I'm doing something wrong or if there is perhaps a bug.

I've fully read man pages on this and have gone so far as to reference the source code but my abilities in C are limited.  Nothing is standing out to my on why this would not work.  I have no other files in the "etc/systemd/network", "run/systemd/network, or "usr/lib/systemd/network" other than the "99-default.link" and "80-container-host0.network". I've even removed thoose files and tried all I can think of to no avail.

I am doing all this on a fairly recent and up-to-date arch install in an VMWare container and am happy to try suggestions or provide more information if anyone needs more to help.
The MAC Address stays static between reboots, as does the location on the pcibus, I've tried [Match] with MACAddress and Path both individually.

Ohh, the device name is enp0s3 with the "99-default.link" and my "1.link" in place and eth0 with "99-default.link" removed.  You can see I am attempted to have it renamed to test without the use of udev rules.

Thanks.

Referencing these two links for my primary sources of information.
http://www.freedesktop.org/software/sys … .link.html
http://coreos.com/blog/intro-to-systemd-networkd/

# uname -a
Linux test 3.14.4-1-ARCH #1 SMP PREEMPT Tue May 13 16:44:54 CEST 2014 i686 GNU/Linux

# pacman -Qi systemd
Name           : systemd
Version        : 212-3
Description    : system and service manager
Architecture   : i686
2: enp0s3: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether 08:00:27:3f:43:de brd ff:ff:ff:ff:ff:ff
# File Name - /etc/systemd/network/1.link
[Match]
MACAddress=08:00:27:3f:43:de

[Link]
Name=test0
# lspci -v -n -s 00:03.0
00:03.0 0200: 8086:1004 (rev 02)
        Subsystem: 8086:1004
        Flags: bus master, 66MHz, medium devsel, latency 64, IRQ 10
        Memory at f0000000 (32-bit, non-prefetchable) [size=128K]
        I/O ports at d010 [size=8]
        Capabilities: [dc] Power Management version 2
        Capabilities: [e4] PCI-X non-bridge device
        Kernel driver in use: e1000
        Kernel modules: e1000

Offline

Board footer

Powered by FluxBB