[Bug 1565083] Re: 16.04 beta2, cannot override udev network interface name in VM
Martin Pitt
martin.pitt at ubuntu.com
Sat Apr 2 13:49:30 UTC 2016
> You have to run "sudo update-initramfs -u" to regenerate the image!
> What a pity it's not in the docs! (upstream issue?)
Actually /usr/share/doc/udev/README.Debian.gz does mention it, in the
"custom net interface naming" section.
** Changed in: systemd (Ubuntu)
Status: New => Invalid
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1565083
Title:
16.04 beta2, cannot override udev network interface name in VM
Status in systemd package in Ubuntu:
Invalid
Bug description:
Hello,
I just cannot seem to override a network interface name on a Ubuntu Server 16.04 beta 2 fresh install.
Reproduce steps were tried on both VirtualBox 4 and VMware Player 7.
(Sadly, despite updating apt, I could not find apport in the
repositories, so please bear with me)
--N.B.: following is not an apport output--
DistroRelease: Ubuntu 16.04
Package: systemd 229-3ubuntu1
Package: udev 229-3ubuntu1
Uname: Linux ubuntu 4.4.0-15-generic #31-Ubuntu SMP Fri Mar 18 19:08:31 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Architecture: amd64
InstallationMedia: ubuntu-16.04-beta2-server-amd64.iso, checksummed (20160323)
ProcEnviron:
LANG=en_US.UTF-8
UpgradeStatus: fresh install
--
Steps to Reproduce:
1. Setup VM with a network card (VirtualBox: Intel Pro/1000 MT Server; VMware Player: E1000 or (hand-edited vmx) vmxnet3
2. Install
3. Upgrade
4. Login
5. Run "networkctl" and note interface name
6. Run "/sbin/udevadm test /sys/class/net/ens160" replacing ens160 with the interface name
ID_PATH=pci-0000:03:00.0
ID_NET_LINK_FILE=/lib/systemd/network/99-default.link
7. Create an override rule : "sudo vi /etc/systemd/50-eth0.link" -- see systemd.link(5) -- with these contents:
[Match]
Path=pci-0000:03:00.0*
[Link]
Name=eth0
MACAddressPolicy=persistent
8. Run again "/sbin/udevadm test /sys/class/net/ens160"
ID_NET_LINK_FILE=/etc/systemd/network/50-eth0.link
9. Run "sudo reboot"
10. Login and run "networkctl"
Expected result:
interface name is now eth0
Actual Result:
No change in interface name.
Other thoughts:
- journalctl does not provide extra info, just that the interface has been renamed to the persistent name as usual.
- /etc/udev/rules.d/ is empty.
- network-manager package is not installed
- Have also tried adding a blank "NamePolicy=" line just under [Link]
- Have tried with Name=ethfoo to avoid potential conflicts; no dice
- Of course, you can disable the new names by adding net.ifnames=0
kernel boot option to grub; it works (but then you don't assign an
name to a matching device).
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1565083/+subscriptions
More information about the foundations-bugs
mailing list