OpenWRT: Software update wget returns "Network is unreachable"

1

I have OpenWRT [Barrier Breaker 14.07 / LuCI Trunk (0.12+svn-r10530)] installed on a TP-Link Wifi Extender (TL-WA850RE v1), though acting like a simple Access Point, DHCP & DNS are provided by a LAN Ethernet port.

When I try to Update Lists from System > Software, OpenWRT returns:

wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
wget: can't connect to remote host (78.24.191.177): Network is unreachable
Collected errors:
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/base/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/luci/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/packages/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/routing/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/telephony/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/management/Packages.gz, wget returned 1.
 * opkg_download: Failed to download http://downloads.openwrt.org/barrier_breaker/14.07/ar71xx/generic/packages/oldpackages/Packages.gz, wget returned 1.

I've searched for some kind of solution but I'm probably searching this up all wrong.

Do you have any pointers on what to do?

Thanks

root@OpenWrtTPLinkExtender:~# ifconfig
br-lan    Link encap:Ethernet  HWaddr C0:4A:00:XX:XX:XX  
          inet addr:192.168.1.39  Bcast:192.168.1.254  Mask:255.255.255.0
          inet6 addr: fdab:194c:3d6f::1/60 Scope:Global
          inet6 addr: fe80::c24a:ff:feca:fc8e/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:299698 errors:0 dropped:161107 overruns:0 frame:0
          TX packets:15676 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:27303300 (26.0 MiB)  TX bytes:2435288 (2.3 MiB)

eth0      Link encap:Ethernet  HWaddr C0:4A:00:XX:XX:XX  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:6595727 errors:0 dropped:2 overruns:0 frame:0
          TX packets:6632247 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1859579896 (1.7 GiB)  TX bytes:2735120766 (2.5 GiB)
          Interrupt:4 

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:65536  Metric:1
          RX packets:196 errors:0 dropped:0 overruns:0 frame:0
          TX packets:196 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:16714 (16.3 KiB)  TX bytes:16714 (16.3 KiB)

wlan0     Link encap:Ethernet  HWaddr C0:4A:00:XX:XX:XX  
          inet6 addr: fe80::c24a:ff:feca:fc8e/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:6648389 errors:0 dropped:0 overruns:0 frame:0
          TX packets:6648114 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:2739930267 (2.5 GiB)  TX bytes:1991025874 (1.8 GiB)

root@OpenWrtTPLinkExtender:~# netstat -rn
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
192.168.1.0     0.0.0.0         255.255.255.0   U         0 0          0 br-lan
root@OpenWrtTPLinkExtender:~# 

acseven

Posted 2014-12-18T00:26:53.567

Reputation: 83

Connect it to the Internet? – Michael Hampton – 2014-12-18T00:29:55.337

OpenWRT in the enterprise?? – yagmoth555 – 2014-12-18T00:37:08.610

@MichaelHampton All devices connected to the router have internet access. – acseven – 2014-12-18T11:23:09.737

@yagmoth555 I'm sorry but I don't understand your comment/question. – acseven – 2014-12-18T11:23:45.123

@acseven: please post the output of "ifconfig" and "netstat -rn". If you're unable to connect to your openwrt via ssh (you can use "putty" for this), you can provide us the screenshot of "status=> routes" and "network=>intefaces" – Damiano Verzulli – 2014-12-21T12:27:42.963

Hi @DamianoVerzulli, I've inserted that info on the original question. Thanks! – acseven – 2014-12-21T17:47:18.097

Answers

1

It seems like your Access Point can't connect to the internet, as there is no default gateway configured.
For now, you can just run this, in order to connect temporarily:

route add default gw 192.168.1.1 eth0

For later, set 192.168.1.1 as your default gateway in the network config.

I assume 192.168.1.1 is your router IP, if not, change it according.

davidbaumann

Posted 2014-12-18T00:26:53.567

Reputation: 2 089

Hi, thanks for the repky. I get this error though: root@OpenWrtTPLinkExtender:~# route add default gw 192.168.1.254 eth0
route: SIOCADDRT: No such process
– acseven – 2014-12-22T09:42:15.737

1route add default gw 192.168.1.1 br-lan – davidbaumann – 2014-12-22T09:43:38.717

Thanks - I had to point to my DNS server, as that error kept popping up when using what is actually the gateway (192.168.1.254). – acseven – 2014-12-22T14:42:03.910

0

As reported by @davidbaumann , your problem is the lack of a "default gateway": without a DEF-GW you cannot access nothing beyond your local subnet.

More in detail, it looks like even if your device is marketed as a "wireless extender", OpenWrt is perfectly able to recognize both the LAN-interface (eth0) and the WLAN-interface (wlan0) (...and as such, it could be a wireless "router" routing between your WLAN and the LAN).

Back to your problem: OpenWrt created a virtual interface (br-lan) that looks like a two-port-ethernet-switch connecting both eth0 and wlan0. Thanks to br-lan, all the traffic coming from eth0 will be forwarded to wlan0 and vice-versa (all traffic coming from wlan0 is forwarded to eth0)

Unfortunatly it's not clear who assigned the IP configuration to br-lan: it could be DHCP assigned or statically defined by you, in the openwrt configuration.

If you configured the IP parameters by hand, then probably you missed the default-gateway: you can check this in the "network"=>"Interfaces"=>br-lan=>"IPv4 gateway"

If you have a DHCP-server on your LAN and your TP-Link got an IP from it... than probably something is wrong with your DHCP-server and/or the DHCP-negotiation between the two hosts.

Files /etc/config/wireless and /etc/config/network could help you in better understanding the gory detail of the configuration (something that, sometime, is not so immediate to get from the standard web-interface).

Damiano Verzulli

Posted 2014-12-18T00:26:53.567

Reputation: 416