0

I'm with NetworkManager

I want to change the interface name, what I don't know sure the steps....

First I should know my interface name and mac from it,

ip a

Seconds, set down the interface,

sudo ip link set dev enp31s0 down

rename the device name, I'll change to hallo0.

First:

What is the difference between used,

sudo gedit /etc/network/interfaces

and write on this file

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug  hallo0
iface hallo0 inet dhcp

Second:

With udev

sudo /etc/udev/rules.d/70-persistent-net.rules

and write on this file,

SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="aa:bb:cc:dd:ee:ff", KERNEL=="eth*", NAME="hallo0"

What from the two possibilities should use?

Can someone help with this question?

0

My problem was when to tried this steps the interface name not to change.

I found the problem because of it not change...

I did Two mistakes;

1 - I forget to link the file,

sudo /etc/udev/rules.d/70-persistent-net.rules

I does it with

sudo  ln -s /dev/null /etc/udev/rules.d/70-net-setup-link.rules

2 - Since Ubuntu 16.04 and Linux Mint 17 on the file,

/etc/udev/rules.d/70-persistent-net.rules

where i write,

SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="aa:bb:cc:dd:ee:ff", KERNEL=="eth*", NAME="hallo0"

I had to write without the word KERNEL=="eth*", so, I should to write,

SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="aa:bb:cc:dd:ee:ff", NAME="hallo0"

As here to say.

For my question what from the two possibilities should use?, i to use both, because with the file /etc/udev/rules.d/70-persistent-net.rules I to say what interface name I`ll to chage and what mac adress belong to it....

The file sudo gedit /etc/network/interfaces, you not need to change, you can leave it as is.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.