Why would a home Internet connection work from one computer but not the other?

0

I have an Internet connection via a router (AT&T U-Verse) with a static IP address.

In most cases, it works... but I experienced something rather strange yesterday.

I have a local network. All the traffic from all the other computers goes through my main computer which has a strong firewall. (The firewall was not the culprit, do not jump to conclusion here. The problem resolved itself and I did not change the firewall at all since.)

So... my network looks something like this:

+------------+    +------------+    +------------+    +------------+
|            |    |            |    |            |    |            |
|    LAN     |<-->|  Main PC   |<-->|  Router    |<-->|  Internet  |
|            |    |            |    |            |    |            |
+------------+    +------------+    +------------+    +------------+
 192.168.2.45      192.168.2.1                                [eth1]
                   192.168.1.1       192.168.1.254          [eth0:0]
                   x.x.x.120         162.220.130.126          [eth0]

So my main computer has a static IP address and it uses gateway 162.226.130.126 to access the Internet. I'm not 100% sure where the gateway is specified, but from what I recall, I put it in the router for the system to work.

Now... sometime yesterday, my Main PC lost its Internet access completely. Up to here... well... I would say, it happens all the time, so nothing too strange. I could not connect to anything, get IP addresses from names, etc. All looked like it was down.

However, the LAN computer next to my main PC, which uses the Main PC connection to the Internet, was working just fine. Not only that, it would continue to process playing back movies from Youtube.com, I could go to any website like Google, etc. as long as I was on the LAN computer.

To me that makes absolutely no sense. The Main PC forwards the LAN computer packages to the Internet... So how could it just continue to work when the Main PC stops working??? (i.e. from the outside, the IP address is the same, so if I had been firewalled by my ISP, then nothing should work.)

I tried a traceroute from both computers and got the following.

Tracing from the LAN computer gets me out, it seems to jump over the gateway though:

traceroute 45.55.5.185
traceroute to 45.55.5.185 (45.55.5.185), 30 hops max, 60 byte packets
 1  halk (192.168.2.1)  0.368 ms  0.374 ms  0.367 ms
 2  192.168.1.254 (192.168.1.254)  0.813 ms  1.045 ms  1.048 ms
 3  162-201-40-3.lightspeed.frokca.sbcglobal.net (162.201.40.3)  20.271 ms  21.638 ms  23.065 ms
 4  75.29.64.148 (75.29.64.148)  28.758 ms  28.999 ms  29.520 ms
 5  12.83.77.141 (12.83.77.141)  27.213 ms 12.83.77.149 (12.83.77.149)  30.960 ms 12.83.77.141 (12.83.77.141)  31.212 ms
 6  12.122.149.133 (12.122.149.133)  36.060 ms  35.725 ms  35.960 ms
 7  192.205.32.222 (192.205.32.222)  36.200 ms  24.034 ms  24.786 ms
 8  digitalocean-ic-302451-sjo-b21.c.telia.net (62.115.34.18)  28.043 ms digitalocean-ic-306499-sjo-b21.c.telia.net (62.115.45.22)  29.201 ms digitalocean-ic-302451-sjo-b21.c.telia.net (62.115.34.18)  30.409 ms
 9  * * *

Tracing from the Main PC, I only get one entry, the gateway:

traceroute 45.55.5.185
traceroute to 45.55.5.185 (45.55.5.185), 30 hops max, 60 byte packets
 1  x.x.x.126  0.556 ms  0.742 ms  1.029 ms
 2  * * *

I just went to bed and in the morning everything was back to normal, and now the traceroute on the Main PC works as on the LAN computer and reaches the DigitalOcean computer as expected.

So my question is not so much "What did happen?" because that may be difficult to answer, but rather "How is it possible that the same tunnel work for one computer and not the other?"

Alexis Wilke

Posted 2016-11-18T01:15:05.297

Reputation: 447

Reset your router. Use Dynamic (DHCP) from your router's settings. Then just plug in your "Main PC" that you run Ethernet cable to and perform the "ipconfig /all" command to get the information; what I mentioned above. Your wireless computer's should work after that too. It's when you start using static IP's and not set it up correctly is when things get blocked. – ejbytes – 2016-11-18T04:00:29.900

I'm under Linux. I am not questioning whether the route will fluctuate a bit here and there, but why would my connection not work from my my Main Computer opposed to a LAN computer (which is also running Linux,) because from the LAN computer I could go and see all the Internet... whereas the other one I was cut off. – Alexis Wilke – 2016-11-18T05:14:31.287

Looks like you might have your IP's a bit mixed? I see you set your router to 192.168.1.254. I did similar to my network. I assume by what you've stated, are static IP's? That's okay, but your main computer in your dia. should not be 192.168.1.1, that's reserved. Make your main comp to be other than 1. And your LAN comp also has an incorrect IP it seems @ 192.168.2.45. The 45 is okay, but change the 2 to a 1 so it looks like 192.168.1.45. I'm not a network engineer, but I've always set my gateways to match the IP. The ipconfig /all equivalent to Linux is $ ifconfig -a – ejbytes – 2016-11-18T08:11:11.053

@ejbytes strictly speaking, 192.168.1.1 is not reserved. It is just common to use as an address for routing. Imagine a closed private network represented by the net block 192.168.1.0/24 with no outside communication. Would it be a problem to assign 192.168.1.1 to any of the hosts? Absolutely not. – diametralpitch – 2016-11-18T20:27:31.457

@diametralpitch While you can, it's not good practice. You can also J-Walk, but I don't recommend it. – ejbytes – 2016-11-18T23:00:00.727

@ejbytes had you qualified your instruction in the previous comment with "it's not good practice", I would not have bothered to comment. You just said it was reserved, and told the OP to change it. Now while I have already mentioned this practice is common, I would not have used such a strong word such as 'reserved', and I offered an example as to why. – diametralpitch – 2016-12-01T05:02:35.727

@ejbytes also, there is a flaw in your reasoning because you are attempting to use an analogy in which an actual rule is being broken. In my example, using 192.168.1.1 violates no such rule. – diametralpitch – 2016-12-01T05:03:28.437

@diametralpitch No flaw. I think you need to let it be. You aren't proving anything at all except that you like to belabor a point to death, beyond any reasonable length and you aren't contributing to anything productive. Good practice is equivalent to standard, which is just as good as law and rule. If you don't agree with that then you need to do some reading. Good day and I hope this quashes any fight you have left in you because I'm not here to have emotional discussions. Good day sir. – ejbytes – 2016-12-02T00:56:01.450

@ejbytes sure, we can just agree to disagree on this one. My intention was to improve the advice given to the OP and anyone else reading this, and also to share my reasoning with you. – diametralpitch – 2016-12-03T02:03:36.193

Answers

1

I am going to make a few assumptions, based on the information in your question.

  1. You say this is a home internet connection, which makes me think that your WAN IP adddress and or gateway (from your ISP) are actually dynamic. This means that your router should occasionally renew its DHCP lease once it expires and possibly receive a new WAN IP and or gateway when it does.
  2. You state you have a static IP address but I think that you are only saying this because you manually assigned the internal address 192.168.1.254 to your router.
  3. I can't see your net masks, but it seems you have two subnets - 192.168.1.0/24 and 192.168.2.0/24. I'm assuming a net mask of 255.255.255.0 for both.

Based on those assumptions, here is one possibility of what happened:

From the perspective of the 'main pc', you were using a default gateway of 162.226.130.126 during a time when you should have been using a dynamic gateway from your ISP. This is evident in your successful traceroute from the LAN perspective where the hop occurs between 192.168.1.254 to 162.201.40.3. No where was 162.226.130.126 actually reached. Because of this, it gives me the impression that your router is periodically renewing a DHCP lease to acquire, at least, a default WAN gateway. Since hosts on your LAN are using the actual address of the router 192.168.1.254 as a gateway, and not your expired WAN gateway (see assumption 1), outbound packets originating from the LAN requiring routing will eventually pass through the routing table of your router which at this time will have the appropriate dynamic default WAN gateway needed to reach the internet through your ISP. Back to the perspective of the 'main pc', because you are using a default gateway equivalent to an expired WAN gateway, you are circumventing the routing action and not relying on the dynamic gateway renewal of your actual router. A reasonable fix could be to just use the router's IP address 192.168.1.254 as the default gateway for your 'main pc'.

diametralpitch

Posted 2016-11-18T01:15:05.297

Reputation: 588

Hmm.... I can assure you that I have a static IP address (I had such for 13 years, I would know if it weren't...), but you may be right. That is, the WAN connection may actually be using a DHCP to connect between my place and the U-Verse servers. I'm pretty sure I read something about that before. And it could be that somehow the LAN computers bypass the gateway of the main computer, somehow... – Alexis Wilke – 2016-11-19T03:19:33.467