Hi,
Just installed openwrt on wavlink wl-wn570ha and cannot access internet to update OS.
I'm using a ssh client through the rj45 cable. No luci is installed by default.
root@OpenWrt:~# opkg update
Downloading http://downloads.openwrt.org/releases/19.07.3/targets/ramips/mt76x8/packages/Packages.gz
Failed to establish connection
*** Failed to download the package list from http://downloads.openwrt.org/releases/19.07.3/targets/ramips/mt76x8/packages/Packages.gz
root@OpenWrt:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.0.1 0.0.0.0 UG 0 0 0 br-lan
192.168.0.0 0.0.0.0 255.255.0.0 U 0 0 0 br-lan
network settings goes like this
config interface 'loopback'
option ifname 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config globals 'globals'
option ula_prefix 'fd9a:c973:6eb6::/48'
config interface 'lan'
option type 'bridge'
option ifname 'eth0.1'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.0.0'
option ip6assign '60'
option gateway '192.168.0.1'
config device 'lan_eth0_1_dev'
option name 'eth0.1'
option macaddr '80:3f:5d:c3:67:34'
config interface 'wan'
option ifname 'eth0.2'
option proto 'static'
option ipaddr 'x.x.x.x'
config device 'wan_eth0_2_dev'
option name 'eth0.2'
option macaddr '80:3f:5d:c3:67:35'
config interface 'wan6'
option ifname 'eth0.2'
option proto 'dhcpv6'
config switch
option name 'switch0'
option reset '1'
option enable_vlan '1'
config switch_vlan
option device 'switch0'
option vlan '1'
option ports '0 1 2 3 6t'
config switch_vlan
option device 'switch0'
option vlan '2'
option ports '4 6t'
and wifi like this
config wifi-device 'radio0'
option type 'mac80211'
option channel '11'
option hwmode '11g'
option path 'platform/10300000.wmac'
option htmode 'HT20'
option disabled '0'
option country 'DE'
config wifi-iface 'default_radio0'
option device 'radio0'
option network 'lan'
option mode 'ap'
option ssid 'OpenWrt-2.4G'
option encryption 'none'
config wifi-device 'radio1'
option type 'mac80211'
option channel '36'
option hwmode '11a'
option path 'pci0000:00/0000:00:00.0/0000:01:00.0'
option htmode 'VHT80'
option disabled '0'
option country 'DE'
config wifi-iface 'default_radio1'
option device 'radio1'
option network 'lan'
option mode 'ap'
option ssid 'OpenWrt-5G'
option encryption 'none'
root@OpenWrt:~# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
root@OpenWrt:~#
root@OpenWrt:~# iptables -L -t nat
Chain PREROUTING (policy ACCEPT)
target prot opt source destination
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Chain POSTROUTING (policy ACCEPT)
target prot opt source destination
Can someone help?
You have configured a gateway on 192.168.0.1, on the LAN network, is that correct?
You have a WAN configured, but it does not seem.to be active, is that correct?
1 Like
wan is active
root@OpenWrt:~# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN qlen 1000
link/ether 80:3f:5d:c3:67:34 brd ff:ff:ff:ff:ff:ff
inet6 fe80::823f:5dff:fec3:6734/64 scope link
valid_lft forever preferred_lft forever
45: br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
link/ether 80:3f:5d:c3:67:34 brd ff:ff:ff:ff:ff:ff
inet 192.168.1.1/16 brd 192.168.255.255 scope global br-lan
valid_lft forever preferred_lft forever
inet6 fd9a:c973:6eb6::1/60 scope global
valid_lft forever preferred_lft forever
inet6 fe80::823f:5dff:fec3:6734/64 scope link
valid_lft forever preferred_lft forever
46: eth0.1@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
link/ether 80:3f:5d:c3:67:34 brd ff:ff:ff:ff:ff:ff
47: eth0.2@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
link/ether 80:3f:5d:c3:67:35 brd ff:ff:ff:ff:ff:ff
inet x.x.x.x/32 brd 255.255.255.255 scope global eth0.2
valid_lft forever preferred_lft forever
inet6 fe80::823f:5dff:fec3:6735/64 scope link
valid_lft forever preferred_lft forever
48: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
link/ether 80:3f:5d:c3:67:35 brd ff:ff:ff:ff:ff:ff
inet6 fe80::823f:5dff:fec3:6735/64 scope link
valid_lft forever preferred_lft forever
49: wlan1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
link/ether 80:3f:5d:c3:67:36 brd ff:ff:ff:ff:ff:ff
inet6 fe80::823f:5dff:fec3:6736/64 scope link
valid_lft forever preferred_lft forever
root@OpenWrt:~# sysctl net.ipv4.ip_forward
net.ipv4.ip_forward = 1
trendy
July 11, 2020, 2:00pm
5
If wan is your internet connection, then remove the gateway from the lan interface.
3 Likes
I have tried on both, none works.
trendy
July 11, 2020, 2:03pm
7
You need to add the gateway to the wan then. Currently it is empty. And some DNS.
3 Likes
this is the new config, still does not work.
root@OpenWrt:~# 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 globals 'globals'
option ula_prefix 'fd9a:c973:6eb6::/48'
config interface 'lan'
option type 'bridge'
option ifname 'eth0.1'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.0.0'
option ip6assign '60'
config device 'lan_eth0_1_dev'
option name 'eth0.1'
option macaddr '80:3f:5d:c3:67:34'
config interface 'wan'
option ifname 'eth0.2'
option proto 'static'
option ipaddr 'X.X.122.18'
option gateway 'X.X.122.63' << ==== this is my internet router
option dns '8.8.8.8'
config device 'wan_eth0_2_dev'
option name 'eth0.2'
option macaddr '80:3f:5d:c3:67:35'
root@OpenWrt:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.0.0 0.0.0.0 255.255.0.0 U 0 0 0 br-lan
root@OpenWrt:~# route add default gw X.X.122.63 eth0
route: SIOCADDRT: Network unreachable
root@OpenWrt:~# route add default gw X.X.122.63 eth0.2
route: SIOCADDRT: Network unreachable
trendy
July 11, 2020, 2:35pm
9
Please use the "Preformatted text </>
" button for logs, scripts, configs and general console output.
Please edit your post accordingly. Thank you!
There is no mask in wan interface.
And I hope the IP of the wan doesn't start with 192.168
1 Like
root@OpenWrt:~# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 X.16.122.63 0.0.0.0 UG 0 0 0 eth0.2
X.16.112.0 0.0.0.0 255.255.240.0 U 0 0 0 eth0.2
192.168.0.0 0.0.0.0 255.255.0.0 U 0 0 0 br-lan
root@OpenWrt:~# ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
--- 8.8.8.8 ping statistics ---
3 packets transmitted, 0 packets received, 100% packet loss
root@OpenWrt:~# ip a
71: eth0.2@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
link/ether 80:3f:5d:c3:67:35 brd ff:ff:ff:ff:ff:ff
inet X.16.122.18/20 brd X.16.127.255 scope global eth0.2
valid_lft forever preferred_lft forever
inet6 fe80::823f:5dff:fec3:6735/64 scope link
valid_lft forever preferred_lft forever
root@OpenWrt:~# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
From a windows cmd window
C:\Users\g\Desktop>ping X.16.122.18
Pinging X.16.122.18 with 32 bytes of data:
Reply from X.16.122.45: Destination host unreachable.
Your WAN interface has a /32 mask, you cannot reach the main router using that interface. Add a proper "option netmask" to that interface.
2 Likes
Note : this device has only one rj45 port. But default configs from openwrt gives a lan and a wan config.
lan mask has been changed to '255.255.0.0'
wan mask to '255.255.240.0'
mk24
July 11, 2020, 3:05pm
14
I think this device is going to have an Ethernet switch in the SOC (which I think is Atheros) but only one port connected to hardware. The other ports are still present and technically functioning, but not usable since their hardware link dead-ends inside the box.
Check the switch configuration with swconfig dev switch0 show
.
The port which is connected to the ISP must be in VLAN 2 and confirm that it shows link up with the cable plugged in and link down with the link unplugged at the modem. (obviously unplugging the cable between the PoE injector and the AP would kill everything).
1 Like
root@OpenWrt:~# ubus call system board
{
"kernel": "4.14.180",
"hostname": "OpenWrt",
"system": "MediaTek MT7688 ver:1 eco:2",
"model": "Wavlink WL-WN570HA1",
"board_name": "wavlink,wl-wn570ha1",
"release": {
"distribution": "OpenWrt",
"version": "19.07.3",
"revision": "r11063-85e04e9f46",
"target": "ramips/mt76x8",
"description": "OpenWrt 19.07.3 r11063-85e04e9f46"
}
}
km24
root@OpenWrt:~# swconfig dev switch0 show
Global attributes:
enable_vlan: 1
alternate_vlan_disable: 0
bc_storm_protect: 0
led_frequency: 0
Port 0:
disable: 0
doubletag: 0
untag: 1
led: 5
lan: 1
recv_bad: 0
recv_good: 8755
tr_bad: 0
tr_good: 9601
pvid: 1
link: port:0 link:up speed:100baseT full-duplex
Port 1:
disable: 0
doubletag: 0
untag: 1
led: 5
lan: 1
recv_bad: 0
recv_good: 0
tr_bad: 0
tr_good: 0
pvid: 1
link: port:1 link:down
Port 2:
disable: 0
doubletag: 0
untag: 1
led: 5
lan: 1
recv_bad: 0
recv_good: 0
tr_bad: 0
tr_good: 0
pvid: 1
link: port:2 link:down
Port 3:
disable: 0
doubletag: 0
untag: 1
led: 5
lan: 1
recv_bad: 0
recv_good: 0
tr_bad: 0
tr_good: 0
pvid: 1
link: port:3 link:down
Port 4:
disable: 0
doubletag: 0
untag: 1
led: 5
lan: 0
recv_bad: 0
recv_good: 0
tr_bad: 0
tr_good: 0
pvid: 2
link: port:4 link:down
Port 5:
disable: 1
doubletag: 0
untag: 0
led: ???
lan: 1
recv_bad: 0
recv_good: 0
tr_bad: 0
tr_good: 0
pvid: 0
link: port:5 link:down
Port 6:
disable: 0
doubletag: 0
untag: 0
led: ???
lan: ???
recv_bad: ???
recv_good: ???
tr_bad: ???
tr_good: ???
pvid: 0
link: port:6 link:up speed:1000baseT full-duplex
VLAN 1:
ports: 0 1 2 3 6t
VLAN 2:
ports: 4 6t
trendy
July 11, 2020, 3:12pm
18
bernigs:
Wavlink WL-WN570HA1
With only one physical lan port you'll need a managed switch capable of vlan tagging to use both lan and wan interfaces. You cannot have 2 untagged interfaces on the same port.
Or you can use the physical port for wan and the wifi for lan.
1 Like
Do I needd to remove the wan configs then? Keep only the lan?
trendy
July 11, 2020, 3:15pm
20
Yes, that would be an option. However it would be best to know what do you plan to do with this device.
Ideally it could be a dumbAP.
1 Like