Network Interfaces Name change in Ubuntu 15.10 (Wily Werewolf)

Sponsored Link
In Wily Werewolf, starting with systemd/udev will automatically assign predictable, stable network interface names for all local Ethernet, Wlan and Wwan interfaces.

The following different naming schemes for network interfaces are now supported by udev natively:

1) Names incorporating Firmware/BIOS provided index numbers for on-board devices (example: eno1)

2) Names incorporating Firmware/BIOS provided PCI Express hotplug slot index numbers (example: ens1)

3) Names incorporating physical/geographical location of the connector of the hardware (example: enp2s0)

4) Names incorporating the interfaces's MAC address (example: enx78e7d1ea46da)

5) Classic, unpredictable kernel-native ethX naming (example: eth0) -- deprecated

Example

In my case i have installed ubuntu 15.10 server in virtualbox and my interface naming started with "enp0s3" and now when i try to add second interface i didn't know what is the interface name so i have to use the following command to find which inteface it assigned

ip link

Output

1: lo: mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: enp0s3: mtu 1500 qdisc pfifo_fast state UP mode DEFAULT group default qlen 1000
link/ether 08:00:27:5f:dd:a1 brd ff:ff:ff:ff:ff:ff
3: enp0s8: mtu 1500 qdisc pfifo_fast state UP mode DEFAULT group default qlen 1000
link/ether 08:00:27:30:2d:00 brd ff:ff:ff:ff:ff:ff

From the above output the new network card interface name is "enp0s8"

Change the default network interface names

You can change the device name by defining the name manually with an udev-rule.These rules will be applied automatically at boot.

First you need to get the MAC address using "ip link" command.I have showed the output of ip link from the above i can see mAC address is "08:00:27:30:2d:00".You need to create 10-network.rules file

sudo vi /etc/udev/rules.d/10-network.rules

Add the following line

SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="08:00:27:30:2d:00″,KERNEL=="enp0s8″, NAME="eth1″

From the above command you have to replace MAC:ADDRESS with your interface mac address and KERNEL=="" to what your kernel is naming the device when it boots.

Save and exit the file and reboot your ubuntu system.After reboot my interface name should be eth1.

Via

Sponsored Link

Related posts

2 thoughts on “Network Interfaces Name change in Ubuntu 15.10 (Wily Werewolf)

  1. In case of static IP address, in addition to creating the 10-network.rules file, it is necessary
    to change the interface name in /etc/network/interfaces.

  2. Gentoo got this quite a while back. These addresses are neither predictable nor persistent. They are based on device enumeration, either PCI or USB as applicable. As for predictability, you can’t know until your computer does the enumeration – AFTER you boot. As for persistent, anything that changes the device enumeration may change you network interface name. That’s particularly problematic with USB, and can still be a problem with PCI, though much less common.

    The only thing that is predictable and persistent about a network interface is the MAC. It’s printed on the box, and it’s the only thing that truly sticks. (Until you use macchanger, but even that is after booting.)

Leave a comment

Your email address will not be published. Required fields are marked *