PDA

View Full Version : [SOLVED] Internet Failure - Hardware OK



lile001
October 8th, 2012, 06:29 PM
I am having a problem accessing the internet on one Linux machine, yet am able to access it on another Linux machine connected to the same router (Which I am typing on now!) Non-working machine was operational about an hour ago, and can access internet from Windows, so hardware is probably OK. Some network setting may have suddenly changed. I am not too familiar with monkey-wrenching network settings on Linux so let's take this slow and one step at a time. I don't know where to start, but I have a lot of information about what I am seeing:

Here are the details:

Non-Working Machine: Ubuntu 12.02, running on a Dell dual core 64 bit machine. Working up to about an hour ago. Pinging my internet provider now produces "unknown host", I can log into my router admin page from the other computer and see that there is NO IP ADDRESS NOR MAC ADDRESS assigned to the non-working computer by the router. This ought to be a pretty good clue for someone who knows what all this gibberish means. If I reboot the non-working computer and start in Windows, the router ASSIGNS AN IP ADDRESS AND SHOWS A MAC ADDRESS in the router admin pages. This is telling me I do not have a hardware problem, cable problem, router or modem problem (I am typing over that connection now.) Link lights are OK in all cases on the cables.

Just before the intertubes quit, here is what I was doing: Trying to install DraftSight on 64 bit. For those of you who know, this can be frustrating as draftsight isn't really programmed for 64 bit, and it needs monkey-wrenching to make it work. There are a bunch of missing dependencies, and I was trying to install a bunch of them. At a terminal (mind you, I just barely understand what all this stuff is!) I had entered "sudo apt-get -f install libdirectfb1.2-9:i386 libsysfs2:i386 libdirectfb-extra:i386"

Previous to that, I had entered "Sudo apt-get -f install" which, as I understood, would find missing dependencies on the other stuff I had previously tried unsuccessfully to install. Perhaps this understanding is inaccurate.

Anyway, just about that time, Pandora stopped, and I noticed that web pages weren't loading, tried a ping and found no internet connectivity. Checked cables for link lights, rebooted a couple of times, and booted into windows, finding the intertubes OK under Bill Gate's Kludge. Went to computer on the next desk, logged into the router admin page, and found no IP address or mac address for the malfunctioning brainbox.

So, where do we go next?

TheFu
October 8th, 2012, 06:41 PM
On both Linux machines, run these commands:
* ifconfig
* route
* more /etc/resolv.conf
and post the output **clearly** saying which is for each machine.

Are you on static or DHCP networking?

Look at the output. Is it the same or different? What is different?

lile001
October 8th, 2012, 06:59 PM
On both Linux machines, run these commands:
* ifconfig
* route
* more /etc/resolv.conf
and post the output **clearly** saying which is for each machine.

Are you on static or DHCP networking?

Look at the output. Is it the same or different? What is different?

OK, these are obviously quite different, however I don't understand enough to know what to do about these differences. I believe that I may be on DHCP networking.


Working Machine:


ifconfig:
eth0 Link encap:Ethernet HWaddr 00:22:19:2d:03:0f
inet addr:192.168.1.106 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::222:19ff:fe2d:30f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:433938 errors:0 dropped:0 overruns:0 frame:0
TX packets:302351 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:435070902 (435.0 MB) TX bytes:48366666 (48.3 MB)
Interrupt:17

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:8554 errors:0 dropped:0 overruns:0 frame:0
TX packets:8554 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1358425 (1.3 MB) TX bytes:1358425 (1.3 MB)

route:
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.1.1 0.0.0.0 UG 0 0 0 eth0
link-local * 255.255.0.0 U 1000 0 0 eth0
192.168.1.0 * 255.255.255.0 U 1 0 0 eth0

more /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.0.1

Nonworking Machine:
Nonworking Machine:


ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:9318 errors:0 dropped:0 overruns:0 frame:0
TX packets:9318 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:3989579 (3.9 MB) TX bytes:3989579 (3.9 MB)
route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface

more /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
# DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

grahammechanical
October 8th, 2012, 07:00 PM
So, you are using 12.04. You should see a network icon in the top panel in the section on the right set aside for indicators.

Do you see either two arrows going in opposite directions (ethernet) or a cone of arcs radiating upwards (wireless)? If you see an upside down cone then you are disconnected. You should have received a warning message about that.

Click the Networking icon and see if you have tick marks against Enable Networking and Enable wireless. If not tick them.

Regards.

P.S. from the printout that you have just posted it is clear that you are not connected by ethernet cable (eth0). All that stuff about eth0 is missing from the none working machine. See, what I have written above.

Another thing. Is this a laptop with a Fn key press that switches off networking? Is that the problem?

lile001
October 8th, 2012, 07:03 PM
BTW thanks a lot for your quick reply!

lile001
October 8th, 2012, 07:18 PM
So, you are using 12.04. You should see a network icon in the top panel in the section on the right set aside for indicators.

Do you see either two arrows going in opposite directions (ethernet) or a cone of arcs radiating upwards (wireless)? If you see an upside down cone then you are disconnected. You should have received a warning message about that.

Click the Networking icon and see if you have tick marks against Enable Networking and Enable wireless. If not tick them.

Regards.

P.S. from the printout that you have just posted it is clear that you are not connected by ethernet cable (eth0). All that stuff about eth0 is missing from the none working machine. See, what I have written above.

Another thing. Is this a laptop with a Fn key press that switches off networking? Is that the problem?

Ah, the dreaded laptop internet key. The simple stuff first. You is a smart guy, not to get lost in arcania without checking easy things first! Nope, this is a desktop machine. Hardwired. No internet key.

I have an ethernet cable, and have just once again checked that it is fully plugged into the back of the computer with a link light displayed. I can boot this machine into Windows, and internet works, Justin Bieber Videos and all. Reboot into Linux, no intertube joy. So the brainbox may THINK it has no cable, but the cable is physically there and functional.

Network icon in the top panel of the non-working machine is NOT PRESENT. Present on the working machine. Hmm.

lile001
October 8th, 2012, 07:23 PM
Note: That last post was not intended to imply that me or anyone else would obtain Internet Joy by watching Justin Bieber. Just sayin'

Here is a bit more interesting info, not that I understand what it means:

Nonworking Machine:
ifconfig
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:15685 errors:0 dropped:0 overruns:0 frame:0
TX packets:15685 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:4508574 (4.5 MB) TX bytes:4508574 (4.5 MB)

Nonworking Machine:
~$ ifconfig eth0
eth0 Link encap:Ethernet HWaddr d0:67:e5:f1:11:95
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
Interrupt:17

Hmm. I don't understand this, but it sure seems like there is an ethernet connection but SOMEBODY isn't talking to it.

lile001
October 8th, 2012, 07:38 PM
Does any of this stuff from this page (https://help.ubuntu.com/10.04/serverguide/network-configuration.html) have any relevance:?



Dynamic IP Address Assignment (DHCP Client)
To configure your server to use DHCP for dynamic address assignment, add the dhcp method to the inet address family statement for the appropriate interface in the file /etc/network/interfaces. The example below assumes you are configuring your first Ethernet interface identified as eth0.

auto eth0
iface eth0 inet dhcp
By adding an interface configuration as shown above, you can manually enable the interface through the ifup command which initiates the DHCP process via dhclient.

sudo ifup eth0

grahammechanical
October 8th, 2012, 07:43 PM
Hi

Compare what you see on your machine with what I see on mine;


eth0 Link encap:Ethernet HWaddr 00:1a:92:82:db:59
inet addr:192.168.1.64 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::21a:92ff:fe82:db59/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:45007 errors:0 dropped:0 overruns:0 frame:0
TX packets:43582 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:42769683 (42.7 MB) TX bytes:8802631 (8.8 MB)
Interrupt:17

You do not have UP and RUNNING either side of BROADCAST. More prooof of what we already know. It ain't connected. Here is the best clue:


Network icon in the top panel of the non-working machine is NOT PRESENT.

Network manager is switched off. Not just networking but Network Manager. Now I need to think and find out how to switch it back on. I am not an expert on this. Which is why I stopped haunting the Networking and Wireless section.

Regards

grahammechanical
October 8th, 2012, 07:54 PM
I have found something. Try this command


sudo service network-manager restart

You will need to put in your password. You may need to reboot for this to take effect.

This command will switch off networking for eth0.


sudo ifconfig eth0 down

and this one will switch it back on


sudo ifconfig eth0 up

Sometimes switching it off and then back on gets it working again.

Regards.

cipherboy_loc
October 8th, 2012, 07:56 PM
If


sudo ifconfig eth0 up

Does not work, try running:


sudo /etc/init.d/NetworkManager status && sudo /etc/init.d/NetworkManager start

And posting the result. First command should bring the interface up (assuming it is eth0) regardless of whether NetworkManager is running, and should at least get you temporary Internet (you might have to manually run sudo dhclient eth0), second command checks the status of network manager and then tries to start it. Starting it will show any errors that NetworkManager has on startup.


Thanks,
Cipherboy

TheFu
October 8th, 2012, 08:05 PM
Thanks for those outputs. Those are extremely helpful to everyone here. Those make it clear that the network is not running when you ran that second set of commands on the "non-working" machine.

Can you run them when the networking is working on that box too? Like right after a reboot so we can see the working configurations.

In the meantime, you should check the ethernet card drivers
$ lspci -nnk | grep -iA2 ethernet
and the log files for issues
$ sudo more /var/log/syslog
$ dmesg | more

lile001
October 8th, 2012, 08:15 PM
Ok, we are getting somewhere but we aren't there yet.

Restarting network manager gave a response indicating it was shut down then turned back on. No ping, so I rebooted. Still no ping.

ifconfig eth0 down then eth0 up seemed to function, and now ifconfig DOES report an Eth0 connection:

Nonworking Machine:


ifconfig
eth0 Link encap:Ethernet HWaddr d0:67:e5:f1:11:95
inet6 addr: fe80::d267:e5ff:fef1:1195/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2 errors:0 dropped:0 overruns:0 frame:0
TX packets:37 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:128 (128.0 B) TX bytes:26726 (26.7 KB)
Interrupt:17

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:1850 errors:0 dropped:0 overruns:0 frame:0
TX packets:1850 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:3382677 (3.3 MB) TX bytes:3382677 (3.3 MB)

larry@DianeFossey:~$ ping socket.net
ping: unknown host socket.net

As you can see, still no ping. I gave it another network-manager restart and a reboot, plus power cycled the router just to be thorough. We are making some progress I think!

TheFu
October 8th, 2012, 08:22 PM
If eth0 doesn't show an IP address (from the ifconfig cmd), you can't ping anything.

lile001
October 8th, 2012, 08:25 PM
If


sudo ifconfig eth0 up

Does not work, try running:


sudo /etc/init.d/NetworkManager status && sudo /etc/init.d/NetworkManager start



AHA! it says "/etc/init.d/NetworkManager Command Not Found". I confirmed there is NO file in init.d called NetworkManager with any combination of caps/nocaps/dash on the nonworking machine. I do find network-manager on the working machine.

This sounds really suspicious.

lile001
October 8th, 2012, 08:37 PM
Thanks for those outputs. Those are extremely helpful to everyone here. Those make it clear that the network is not running when you ran that second set of commands on the "non-working" machine.

Can you run them when the networking is working on that box too? Like right after a reboot so we can see the working configurations.

In the meantime, you should check the ethernet card drivers
$ lspci -nnk | grep -iA2 ethernet
and the log files for issues
$ sudo more /var/log/syslog
$ dmesg | more

The first command produced this:


lspci -nnk | grep -iA2 ethernet
05:00.0 Ethernet controller [0200]: Broadcom Corporation NetXtreme BCM5761 Gigabit Ethernet PCIe [14e4:1681] (rev 10)
Subsystem: Dell Device [1028:0293]
Kernel driver in use: tg3

The syslog and dmesg commands produced truly massive outputs, none of which I could make heads or tails of, pages and pages of stuff about every IRQ, nut, bolt and peripheral on the computer.

lile001
October 8th, 2012, 08:54 PM
Ubuntu Software Center reports Network-Manager-Gnome as NOT installed on the nonworking machine.

Ok, how do I install network-manager without an internet connection?

lile001
October 8th, 2012, 09:12 PM
I am following the instructions here

http://askubuntu.com/questions/55805/how-do-i-re-install-network-manager-without-an-internet-connection

to get .deb packages for network manager and network-manager-gnome.

Cross your fingers.

cipherboy_loc
October 8th, 2012, 09:14 PM
If you have synaptic installed, it would be interesting to check why the package was removed. Otherwise, check http://packages.ubuntu.com/ for your version and get download the package and all missing dependencies (search for network manager) on the working computer, then copy via USB to the other computer.

Edit: didn't see your post, the instructions you posted should work.


Thanks,
Cipherboy

lile001
October 8th, 2012, 09:18 PM
AHA! Ubuntu Software Center is compalining about some of that crap I was trying to install earlier (Remember how this started? Trying to install Draftsight? Draftsight wants dependencies? )

libdirectfb and libsysf2. Arghh. Those files somehow hosed network manager. these are GRAPHICs drivers for cryin out loud.

Stand by...

lile001
October 8th, 2012, 09:38 PM
If you have synaptic installed, it would be interesting to check why the package was removed. Otherwise, check http://packages.ubuntu.com/ for your version and get download the package and all missing dependencies (search for network manager) on the working computer, then copy via USB to the other computer.

Edit: didn't see your post, the instructions you posted should work.


Thanks,
Cipherboy

See attached text file for what i just did. Hope it was close to correct.

Still have some missing dependencies, struggling to figure out how to find and install them without an internet connection.

Removed all those libxxxxxi386 crap, which probably didn't belong on that computer anyway. I have attached an output (too big to post) showing what was removed and what dependencies are still missing. I am seriously in over my head here.

lile001
October 8th, 2012, 09:52 PM
Yow! Apparently there is a boatload of crap that this depends on, not installed. This is a mess!

I wonder if I would be better off with a linux install CD? Not that I have one....

lile001
October 8th, 2012, 09:58 PM
AHA! rebooted, and things are now working.

I have done the following:

apt-get update
apt-get check which should check for broken dependencies if I understand correctly. All seems to be OK.


Anythign else I should do to clean up this freaking mess?

TheFu
October 8th, 2012, 10:08 PM
AHA! rebooted, and things are now working. I may still apt-get install network manager now that I have a new connection, seeing as it was complaining about how much stuff it didn't have. Anythign else I should do to clean up this freaking mess? Updates?

This is why it is dangerous to install programs outside the known repositories.

Installing from PPAs can be dangerous too, especially if they aren't release specific.

Installing raw .deb files can be dangerous too.

It is likely that you are in "APT Hell" now and that your package management will never be the same. I hope you aren't.

lile001
October 8th, 2012, 10:13 PM
This is why it is dangerous to install programs outside the known repositories.

Installing from PPAs can be dangerous too, especially if they aren't release specific.

Installing raw .deb files can be dangerous too.

It is likely that you are in "APT Hell" now and that your package management will never be the same. I hope you aren't.

Apparently it is dangerous to install Draftsight, which was the original problem. LibreCad is coming to a computer near me very soon, maybe it will actually work.

Seriously, should I reinstall Ubuntu 12.02?

TheFu
October 8th, 2012, 10:23 PM
Apparently it is dangerous to install Draftsight, which was the original problem. LibreCad is coming to a computer near me very soon, maybe it will actually work.

Seriously, should I reinstall Ubuntu 12.02?

http://linuxaideddesign.blogspot.com/2012/03/draftsight-and-ubuntu-1204-lts-64bit.html shows some intricate steps to install Draftsight. I didn't read them all, since it appears the package isn't designed for Ubuntu 12.04.

LibreCad seems to be in the 12.04 repository, so it should be safe to install.

BTW, 12.04 is probably the release you mean, not 12.02. It was released in April (.04) of 2012 (12.) Thanks for using the numbers, but being correct is important when asking for help. 12.10 is for October 2012.

Canonical has standardized on Apr/Oct releases to help with predictability since 2008. Most people who are not developers should use the April release in the even years. These are called LTS - Long Term Support - and meant to be more stable and have a 5 yr support/patch promise. Just to clarify, when 12.10 is released in a few days/weeks, you should not grab it.

lile001
October 8th, 2012, 10:31 PM
http://linuxaideddesign.blogspot.com/2012/03/draftsight-and-ubuntu-1204-lts-64bit.html shows some intricate steps to install Draftsight. I didn't read them all, since it appears the package isn't designed for Ubuntu 12.04.

LibreCad seems to be in the 12.04 repository, so it should be safe to install.

BTW, 12.04 is probably the release you mean, not 12.02. It was released in April (.04) of 2012 (12.) Thanks for using the numbers, but being correct is important when asking for help. 12.10 is for October 2012.

Canonical has standardized on Apr/Oct releases to help with predictability since 2008. Most people who are not developers should use the April release in the even years. These are called LTS - Long Term Support - and meant to be more stable and have a 5 yr support/patch promise. Just to clarify, when 12.10 is released in a few days/weeks, you should not grab it.


Thanks, you are right I am on 12.04. Only interested in LTS releases.

The intricate instructions to install Draftsight are indeed intricate, and fraught with errors and pitfalls. One can find any number of helpful instructions for installing Draftsight on 64 bit, many of which are incorrect or fraught with dangers. I had it working once, but they forced an upgrade and it all fell apart.