Announcement

Collapse
No announcement yet.

Static ip For eth0 in different family than router ip breaks Internet Browsing

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Static ip For eth0 in different family than router ip breaks Internet Browsing

    Hello,

    I did a clean install of Kubuntu 12.04 on new Dell-15RSE.

    First I gave static IP to wired connection as 192.168.1.124 and gateway as 192.168.1.1 and rebooted the system
    At this point I am able to connect to internet and browse normally. Similarly ping to www.google.co.in also works.

    Later For experimentation I tried to give static IP of 10.66.1.124 and gateway as 192.168.1.1 and rebooted the system.
    At this point the Internet access is not possible and I cant ping to www.google.co.in.

    In both cases dns servers were given as 8.8.8.8 and 8.8.4.4.

    I can ping 192.168.1.1, 8.8.8.8, and another computer in lan with 10.66.1.248.

    Can somebody help me in this situation ?

    the outputs of various commands are given below for reference.

    Thanks and warm regards.

    Raja Patil


    Case with static IP 192.168.1.124

    Code:
            rsp@DELL-15RSE:~$ lspci
    
    		00:00.0 Host bridge: Intel Corporation Ivy Bridge DRAM Controller (rev 09)
    		00:01.0 PCI bridge: Intel Corporation Ivy Bridge PCI Express Root Port (rev 09)
    		00:02.0 VGA compatible controller: Intel Corporation Ivy Bridge Graphics Controller (rev 09)
    		00:14.0 USB controller: Intel Corporation Panther Point USB xHCI Host Controller (rev 04)
    		00:16.0 Communication controller: Intel Corporation Panther Point MEI Controller #1 (rev 04)
    		00:1a.0 USB controller: Intel Corporation Panther Point USB Enhanced Host Controller #2 (rev 04)
    		00:1b.0 Audio device: Intel Corporation Panther Point High Definition Audio Controller (rev 04)
    		00:1c.0 PCI bridge: Intel Corporation Panther Point PCI Express Root Port 1 (rev c4)
    		00:1c.1 PCI bridge: Intel Corporation Panther Point PCI Express Root Port 2 (rev c4)
    		00:1d.0 USB controller: Intel Corporation Panther Point USB Enhanced Host Controller #1 (rev 04)
    		00:1f.0 ISA bridge: Intel Corporation Panther Point LPC Controller (rev 04)
    		00:1f.2 SATA controller: Intel Corporation Panther Point 6 port SATA Controller [AHCI mode] (rev 04)
    		00:1f.3 SMBus: Intel Corporation Panther Point SMBus Controller (rev 04)
    		01:00.0 VGA compatible controller: Advanced Micro Devices [AMD] nee ATI Device 682f
    		07:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8111/8168B PCI Express Gigabit Ethernet controller (rev 07)
    		08:00.0 Network controller: Intel Corporation Centrino Wireless-N 2230 (rev c4)
    
    
    	rsp@DELL-15RSE:~$ ifconfig
    
    		eth0      Link encap:Ethernet  HWaddr d4:be:d9:56:44:4e  
    				inet addr:192.168.1.124  Bcast:192.168.1.255  Mask:255.255.255.0
    				inet6 addr: fe80::d6be:d9ff:fe56:444e/64 Scope:Link
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
    				RX packets:3205 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:2249 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:1882551 (1.8 MB)  TX bytes:308310 (308.3 KB)
    				Interrupt:43 
    
    		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:274 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:274 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:0 
    				RX bytes:23267 (23.2 KB)  TX bytes:23267 (23.2 KB)
    
    		vmnet1    Link encap:Ethernet  HWaddr 00:50:56:c0:00:01  
    				inet addr:10.1.1.1  Bcast:10.1.1.255  Mask:255.255.255.0
    				inet6 addr: fe80::250:56ff:fec0:1/64 Scope:Link                                                
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1                                             
    				RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:117 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    		vmnet8    Link encap:Ethernet  HWaddr 00:50:56:c0:00:08  
    				inet addr:172.16.165.1  Bcast:172.16.165.255  Mask:255.255.255.0
    				inet6 addr: fe80::250:56ff:fec0:8/64 Scope:Link
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
    				RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:128 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    	rsp@DELL-15RSE:~$ 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
    		10.1.1.0        *               255.255.255.0   U     0      0        0 vmnet1
    		link-local      *               255.255.0.0     U     1000   0        0 eth0
    		172.16.165.0    *               255.255.255.0   U     0      0        0 vmnet8
    		192.168.1.0     *               255.255.255.0   U     1      0        0 eth0
    Case with static IP 10.66.1.124

    Code:
    	rsp@DELL-15RSE:~$ ifconfig
    		eth0      Link encap:Ethernet  HWaddr d4:be:d9:56:44:4e  
    				inet addr:10.66.1.124  Bcast:10.66.1.255  Mask:255.255.255.0
    				inet6 addr: fe80::d6be:d9ff:fe56:444e/64 Scope:Link
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
    				RX packets:40 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:132 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:4068 (4.0 KB)  TX bytes:18002 (18.0 KB)
    				Interrupt:43 
    
    		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:69 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:69 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:0 
    				RX bytes:4422 (4.4 KB)  TX bytes:4422 (4.4 KB)
    
    		vmnet1    Link encap:Ethernet  HWaddr 00:50:56:c0:00:01  
    				inet addr:10.1.1.1  Bcast:10.1.1.255  Mask:255.255.255.0
    				inet6 addr: fe80::250:56ff:fec0:1/64 Scope:Link
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
    				RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:100 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    		vmnet8    Link encap:Ethernet  HWaddr 00:50:56:c0:00:08  
    				inet addr:172.16.165.1  Bcast:172.16.165.255  Mask:255.255.255.0
    				inet6 addr: fe80::250:56ff:fec0:8/64 Scope:Link                                                
    				UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1                                             
    				RX packets:0 errors:0 dropped:0 overruns:0 frame:0
    				TX packets:105 errors:0 dropped:0 overruns:0 carrier:0
    				collisions:0 txqueuelen:1000 
    				RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
    
    	rsp@DELL-15RSE:~$ 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
    		10.1.1.0        *               255.255.255.0   U     0      0        0 vmnet1
    		10.66.1.0       *               255.255.255.0   U     1      0        0 eth0
    		link-local      *               255.255.0.0     U     1000   0        0 eth0
    		172.16.165.0    *               255.255.255.0   U     0      0        0 vmnet8
    		192.168.1.1     *               255.255.255.255 UH    0      0        0 eth0
    
    	rsp@DELL-15RSE:~$ ping [url]www.google.co.in[/url]
    		ping: unknown host [url]www.google.co.in[/url]
    Last edited by SteveRiley; Dec 27, 2012, 10:16 PM.

    #2
    If your router is set to provide DHCP service, then you need to look into the default address range reserved for DHCP. .124 is probably in that range. If so, try .224 for the fixed IP address.

    Comment


      #3
      Thanks dibl,

      The range is in 192.168.1.* my static ip is in family 10.66.1.* so they are not conflicting.
      The problem is related to gateway given in other family I am not sure whether gateway
      can be given in different family or not.

      warm regards

      raja patil

      Comment


        #4
        A computer's default gateway must be in the same subnet as the computer's IP address. Because your default gateway is in 192.168.1/24 and your static IP is in 10.16.1/24, they can't see each other.

        When your computer needs to send a datagram to another computer, it can do this by itself if the two computers are on the same subnet. If the other computer is on some other subnet (like, say, the Internet), then it needs the services of a router. To find the nearest router, your computer issues an ARP request. It asks, "What is the MAC address for IP a.b.c.d?" ARP broadcasts cannot cross subnet boundaries. Your ARP broadcast will be picked up only by machines in 10.16.1/24. Your default gateway, being in a different subnet, will not respond.
        Last edited by SteveRiley; Dec 27, 2012, 10:26 PM.

        Comment

        Working...
        X