OpenWrt Forum Archive

Topic: Router can't contact (ping, ...) my LAN machines

The content of this topic has been archived on 22 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I've Linksys WRT160NL with today's trunk (19111).

I couldn't make port redirection working and looking for reason I noticed router can't contact my machine at all. It doesn't matter if I connect using cable or WiFi. I get IP from DHCP server on router and I can browse Internet without problems.

zajec@linux-g0th:~> ip addr show dev eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:1d:ba:19:9e:db brd ff:ff:ff:ff:ff:ff
    inet 192.168.1.197/24 brd 192.168.1.255 scope global eth0
    inet6 fe80::21d:baff:fe19:9edb/64 scope link
       valid_lft forever preferred_lft forever
zajec@linux-g0th:~> ssh root@192.168.1.1
root@192.168.1.1's password:


BusyBox v1.15.3 (2010-01-12 12:59:03 CET) built-in shell (ash)
Enter 'help' for a list of built-in commands.

  _______                     ________        __
 |       |.-----.-----.-----.|  |  |  |.----.|  |_
 |   -   ||  _  |  -__|     ||  |  |  ||   _||   _|
 |_______||   __|_____|__|__||________||__|  |____|
          |__| W I R E L E S S   F R E E D O M
 KAMIKAZE (bleeding edge, r19111) ------------------
  * 10 oz Vodka       Shake well with ice and strain
  * 10 oz Triple sec  mixture into 10 shot glasses.
  * 10 oz lime juice  Salute!
 ---------------------------------------------------
root@OpenWrt:~# ping -c 3 192.168.1.1
PING 192.168.1.1 (192.168.1.1): 56 data bytes
64 bytes from 192.168.1.1: seq=0 ttl=64 time=0.341 ms
64 bytes from 192.168.1.1: seq=1 ttl=64 time=0.253 ms
64 bytes from 192.168.1.1: seq=2 ttl=64 time=0.230 ms

--- 192.168.1.1 ping statistics ---
3 packets transmitted, 3 packets received, 0% packet loss
round-trip min/avg/max = 0.230/0.274/0.341 ms
root@OpenWrt:~# ping -c 3 192.168.1.197
PING 192.168.1.197 (192.168.1.197): 56 data bytes

--- 192.168.1.197 ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss

Same happens when I disable firewall (/etc/init.d/firewall stop): I don't have access to Internet anymore and pinging still doesn't work.

Please post your current network setup (/etc/config/network)

jow wrote:

Please post your current network setup (/etc/config/network)

Thanks for response! If I can post anything else to help debugging it, please just ask.

# cat /etc/config/network

config 'interface' 'loopback'
        option 'ifname' 'lo'
        option 'proto' 'static'
        option 'ipaddr' '127.0.0.1'
        option 'netmask' '255.0.0.0'

config 'interface' 'lan'
        option 'ifname' 'eth0'
        option 'type' 'bridge'
        option 'proto' 'static'
        option 'ipaddr' '192.168.1.1'
        option 'netmask' '255.255.255.0'

config 'interface' 'wan'
        option 'ifname' 'eth1'
        option 'proto' 'static'
        option 'ipaddr' '192.168.0.2'
        option 'netmask' '255.255.255.0'
        option 'gateway' '192.168.0.1'
        option 'defaultroute' '0'
        option 'peerdns' '0'

config 'switch' 'eth0'
        option 'reset' '1'
        option 'enable_vlan' '1'

config 'switch_vlan'
        option 'device' 'eth0'
        option 'vlan' '1'
        option 'ports' '0 1 2 3 4 5'

The discussion might have continued from here.