Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a 6 year-old desktop on which I've been running Debian.
I updated the OS about 10 days and then was too busy to get on the machine until yesterday.
But I was trying to log back in yesterday and the machine seems to have lost our home network. The network settings just say, "Connecting..." and yet is not doing so.
The machine is plugged in with an ethernet cable and thus is not bothered by these issues of linux running on a WiFI enabled device.
You need to find out where things are going wrong. I suggest a few simple tests.
1. Use dmesg|more to check that the kernel is still setting up your card correctly.
2. Look in /sys/class/net to see what the interface is called. Some distros are switching from the old eth0 nomenclature to one based on bus address. For example Crux now calls my ethernet card enp0s25. If your configuration files are set to the old name and that name has changed, the network won't come up.
3. /sbin/ip link show will also provide useful information.
4. Check both ends of your ethernet cable! Sounds corny but sometimes it works.
I'm guessing you have a static network setup.
When Wheezy came out Network Manager started taking a very active role in managing network connections, and it killed me in my static network setup- any wired connection got brought down and then restarted as DHCP. I was just killing NM-applet soon after boot and resetting the connections to what I needed. You need to look up the Network Manager tutorial and set the connections up in it. In the meantime, try killing the NM-applet process, ifdown the nic (eth0,1,whatever), make sure the definitions are correct for your network in /etc/network/interfaces, and then ifup the nic. I suspect your home network will have returned.
I see: source /etc/network/inerfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
I checked the ethernet cable (looking perfectly fine on both ends).
I did notice that when I unplugged it from the machine, the notification changed (which means it is recognizing the cable) - but is still not connecting.
While reading, dmesg|more, where does it tell me if the kernel is connecting to the proper interface?
In /etc/network/run
I see lo=lo
SO, far I have experimented with changing every instance of "lo" to eth0 because the debian documentation says that is what it's supposed to be (unless, this update switched everything to "lo")
ifup & ifdown do not recognize either option.
What do people think?
Is my machine finally ready for the heap, or can I get it connected again?
I appreciate the suggestions thus far.
J.
Last edited by jlibraryist; 05-02-2016 at 08:44 PM.
My Debian Jessie ../interfaces looks like that too, but I added my wired connection to Network Manager, I don't know if I removed the definition in interfaces or NM did. Look for the network manager wiki/howto, there's a command you run in a terminal to add the definition to NM, you will need the hardware id for the nic because network manager doesn't go by the ethx names.
Also, you should put lo back, that's the internal loopback interface and as I understand it it's very necessary.
While reading, dmesg|more, where does it tell me if the kernel is connecting to the proper interface?
It doesn't. What dmesg tells you is whether the card has been set up correctly as a piece of hardware. Usually the card is configured right at the end of the boot. You see something like this:
[ 5.384141] IPv6: ADDRCONF(NETDEV_UP): enp0s25: link is not ready
[ 6.675877] e1000e: enp0s25 NIC Link is Up 100 Mbps Full Duplex, Flow Control: Rx/Tx
[ 6.675986] e1000e 0000:00:19.0 enp0s25: 10/100 speed: disabling TSO
[ 6.676026] IPv6: ADDRCONF(NETDEV_CHANGE): enp0s25: link becomes ready
That tells me that my card is up and running with the e1000e driver, and that the new interface nomenclature is being used.
You haven't said what /sys/class/net shows. If the card is working, you should see the interface name there. Mine says: enp0s25 lo. So there are two working interfaces there, the ethernet card and loopback.
Quote:
SO, far I have experimented with changing every instance of "lo" to eth0 because the debian documentation says that is what it's supposed to be (unless, this update switched everything to "lo")
No, no, no! Please change everything back to the way you found it. Only change a configuration file if you know what the line you are changing means, why it is written that way, and why it ought to be written differently. And always keep a backup copy of the file as it was before you changed it.
Work systematically. I assume your upgrade included a new kernel so first find out if the card itself still works. Then we can talk of setting up the network.
It doesn't. What dmesg tells you is whether the card has been set up correctly as a piece of hardware. Usually the card is configured right at the end of the boot. You see something like this:
[ 5.384141] IPv6: ADDRCONF(NETDEV_UP): enp0s25: link is not ready
[ 6.675877] e1000e: enp0s25 NIC Link is Up 100 Mbps Full Duplex, Flow Control: Rx/Tx
[ 6.675986] e1000e 0000:00:19.0 enp0s25: 10/100 speed: disabling TSO
[ 6.676026] IPv6: ADDRCONF(NETDEV_CHANGE): enp0s25: link becomes ready
That tells me that my card is up and running with the e1000e driver, and that the new interface nomenclature is being used.
<<Ok, I will doublecheck this toniught too.>>
You haven't said what /sys/class/net shows. If the card is working, you should see the interface name there. Mine says: enp0s25 lo. So there are two working interfaces there, the ethernet card and loopback.
<<I forgot to check this (WILL DO TONIGHT)>>
No, no, no! Please change everything back to the way you found it. Only change a configuration file if you know what the line you are changing means, why it is written that way, and why it ought to be written differently. And always keep a backup copy of the file as it was before you changed it.
<<I will change everything back this evening>>
Work systematically. I assume your upgrade included a new kernel so first find out if the card itself still works. Then we can talk of setting up the network.
I will do everything in my power to keep this machine running - this is why we call it DIY computing.
But, the machine is old enough, and I have gotten plenty of use from it - so if it's its time, I will ding it a song.
But in the meantime, more troubleshooting.
2. Look in /sys/class/net to see what the interface is called. Some distros are switching from the old eth0 nomenclature to one based on bus address. For example Crux now calls my ethernet card enp0s25. If your configuration files are set to the old name and that name has changed, the network won't come up.
.
I checked in this directory and two are listed:
eth0 & lo
less ifstate
lo=lo
What are my next steps?
I edited the two config files I mangled before to return them to their original info.
Still no connection.
Ironically, even though the ifstate is lo=lo, when I open the Connection Settings, I see eth0 after the number.
I feel this might be where the issue is.
[ 16.801252] r8169 0000:02:00.0 eth0: link down
[ 16.801261] r8169 0000:02:00.0 eth0: link down
[ 16.801404] IPv6: ADDRCONF (NETDEV_UP): eth0: link is not ready
[ 18.383103] r8169 0000:02:00.0 eth0: link up
[ 16.383118] IPv6: ADDRCONF (NETDEV_CHANGE): eth0: link becomes ready
What does this tell me re: eth0 Vs. lo for ifstate?
lo is an internal interface, I don't believe you even need a nic to have that interface. Eth0 is there and recognized. Open a terminal and enter "nmcli dev status" (without the quotes). Network manager will come back with the list of devices it has found and what their status is. lo should be unmanaged, what does it say about eth0? If it's unmanaged, you should probably add the device to network manager using the command line tool, for which you can find a thorough description searching on "network manager tutorial" or something similar. You don't have settings for it in /etc/network/interfaces so at this point eth0 is not configured for anything, no IP address etc., and it needs that information, be it from .../interfaces or from network manager. Network manager seems to handle wireless DHCP connections without configuring them, but not wired connections.
A quick search yields https://wiki.debian.org/NetworkManager
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.