0

I have no network connectivity this morning (no problems at all yesterday) on a desktop running 16.04. I cannot directly paste command outputs for obvious reasons, but I'll try to describe the problem.

lshw -C network displays both my wireless and ethernet cards yet no physical id and no logical name for either.

I attempted to manually add eth0 to /etc/network/interfaces as follows thinking/hoping perhaps ifup would assign it to something?!

auto eth0

iface eth0 inet dhcp

When I run

$ifup eth0

I get errors as follows;

"Cannot find device "eth0" Error getting hardware address for eth0"

How can I get a logical name assigned to my network adaptors?

9
  • Run ip link show | grep -o eth0 to see if that named device is present Apr 6, 2017 at 8:40
  • Only lo is present Apr 6, 2017 at 8:40
  • Try this sudo systemctl restart NetworkManager Apr 6, 2017 at 8:42
  • No clear error but lo remains the only device. sudo systemctl status NetworkManager shows; nm_device_get_device_type: assertion 'NM_IS_DEVICE (self)' failed Apr 6, 2017 at 8:45
  • Please check your hardware...How old is your system? Apr 6, 2017 at 8:48

1 Answer 1

0

This error is something specific to ubuntu. To be able to configure interfaces using commands ifup and ifdown or ifconfig up and ifconfig down, you need to add those interfaces to the file:

/etc/network/interfaces

Open this file using

$nano /etc/network/interfaces

You find the first line says that:

interfaces(5) file used by ifup(8) and ifdown(8)

so, add the interface you want to that file, then restart the networking service, and you will be able to run the command.

1 - Open the file for edit

2 - add the line (in a new line)

auto (interface_name_without_bracets)

3 - save the file and exit

4 - $sudo service networking restart

5 - Try the commands ifup or ifdown

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .