HostOnNet Blog

Ubuntu Routing Problem 192.69.x.x

Looking for Linux Server Admin or WordPress Expert? We can help.

After moving labs.buyscripts.in to new server, one of the ubuntu PC can’t connect to it.

root@pc15:~# ping labs.buyscripts.in
PING labs.buyscripts.in (192.69.210.196) 56(84) bytes of data.
From pc15 (192.168.0.15) icmp_seq=1 Destination Host Unreachable
From pc15 (192.168.0.15) icmp_seq=2 Destination Host Unreachable
^C
--- labs.buyscripts.in ping statistics ---
10 packets transmitted, 0 received, +9 errors, 100% packet loss, time 9047ms
pipe 3
root@pc15:~# ping 192.69.210.196
PING 192.69.210.196 (192.69.210.196) 56(84) bytes of data.
From 192.168.0.15 icmp_seq=1 Destination Host Unreachable
From 192.168.0.15 icmp_seq=2 Destination Host Unreachable
From 192.168.0.15 icmp_seq=3 Destination Host Unreachable
^C
--- 192.69.210.196 ping statistics ---
5 packets transmitted, 0 received, +3 errors, 100% packet loss, time 4024ms
pipe 3

root@pc15:~# traceroute 192.69.210.196
traceroute to 192.69.210.196 (192.69.210.196), 30 hops max, 60 byte packets
 1  pc15 (192.168.0.15)  3001.838 ms !H  3001.833 ms !H  3001.825 ms !H
root@pc15:~#

Ping and treaceroute fails.

I checked route

root@pc15:~# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
169.254.0.0     0.0.0.0         255.255.0.0     U     1000   0        0 eth1
192.0.0.0       0.0.0.0         255.0.0.0       U     1      0        0 eth1
0.0.0.0         192.168.0.1     0.0.0.0         UG    0      0        0 eth1
root@pc15:~# 

Second line

192.0.0.0       0.0.0.0         255.0.0.0       U     1      0        0 eth1

This caused access to 192.69.210.196 fail. It route traffic to LAN. For LAN, only 192.168.x.x needed.

To fix this, i added route to 192.69.0.0

route add -net 192.69.0.0 netmask 255.255.0.0 gw 192.168.0.1 dev eth1

Added the command to /etc/rc.local, so it run on boot.

Posted in Ubuntu

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.