lpcware

Pinging router problem on uCLinux platform

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by awadhesh on Sat Mar 22 02:12:55 MST 2014
Hi,

I am working on ea-LPC1788 board on uCLinux platform. I have configured the network using

1> ifconfig eth0 100.101.111.225 netmask 255.255.255.0 up
2> route add default gw 100.101.111.111 eth0

After that I connected to my host pc, which IP is 100.101.111.235, it with ping successfully and host pc can ping the board successfully. Host ip is 100.101.111.235.

means:

ping 100.101.111.235 is working on board and ping 100.101.111.225 is working on host pc successfully.

And also host pc can ping the router i.e. ping 100.101.111.111.
64 bytes from 100.101.111.111: icmp_req=1 ttl=64 time=21.5 ms
64 bytes from 100.101.111.111: icmp_req=2 ttl=64 time=6.05 ms
64 bytes from 100.101.111.111: icmp_req=3 ttl=64 time=6.25 ms

But when I have connected board via router, it will not ping router from the board i.e. ping 100.101.111.111, it will not work. After pressing  ctrl+C I got.
PING 100.101.111.111 (100.101.111.111): 56 data bytes
^C
--- 100.101.111.111 ping statistics ---
7 packets transmitted, 0 packets received, 100% packet loss

This board cannot connect to any pc via router where as all pc are connected to each other via this router and working properly except this board.

I have checked the router table: route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
100.101.111.0   *               255.255.255.0   U     0      0        0 eth0
default         100.101.111.111 0.0.0.0         UG    0      0        0 eth0

It will very grateful if someone can help me!

Outcomes