I own an Ubiquiti Airrouter running OpenWRT that I'm using to connect several cabled devices to my wireless network. This works fine as long as I'm using static IP's but even after spending several hours on this, I cannot get DHCP addresses coming in from my main router to be relayed.
My setup:
<client> ---[cable]--- <owrt bridge> --[wifi]-- <my_router> ------ <Internet>
Setting up, I followed the instructions exactly as found on the wiki. I also went and checked if there are any updated versions out there but all information I could find more or less confirms what's in the wiki. The only thing I did in the end on top of what's written in the wiki is to give my wwan a static IP and to entirely stop and disable dnsmasq, the firewall, and dhcp.
I ran tcpdump on the client and on the owrt bridge. The DHCP request from the client clearly gets to my_router and my_router sends a valid dhcp reply to the broadcast adress (255.255.255.255). In the tcpdump on owrt bridge, I can verify that the owrt bridge actually receives this reply.
root@OpenWrt:/etc# tcpdump -i any port 68
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on any, link-type LINUX_SLL (Linux cooked), capture size 65535 bytes
19:29:27.981849 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from 00:16:3e:0a:ff:da (oui Unknown), length 300
19:29:27.981872 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from 00:16:3e:0a:ff:da (oui Unknown), length 300
19:29:27.982138 IP 0.0.0.0.bootpc > 255.255.255.255.bootps: BOOTP/DHCP, Request from 00:16:3e:0a:ff:da (oui Unknown), length 300
19:29:28.513557 IP 192.168.0.1.bootps > 255.255.255.255.bootpc: BOOTP/DHCP, Reply, length 300
Unfortunately, however, the DHCP server's reply never makes it to the client. There is no firewall or anything else blocking the communication between the owrt bridge and the client.
Here some other information about my configuration:
root@OpenWrt:/etc# cat openwrt_release
DISTRIB_ID="OpenWrt"
DISTRIB_RELEASE="14.07"
DISTRIB_REVISION="r42625"
DISTRIB_CODENAME="barrier_breaker"
DISTRIB_TARGET="ar71xx/generic"
DISTRIB_DESCRIPTION="OpenWrt Barrier Breaker 14.07"
DISTRIB_TAINTS=""
root@OpenWrt:/etc/config# cat 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 'fd6e:f1f4:0690::/48'
config interface 'lan'
option ifname 'eth0'
option force_link '1'
option type 'bridge'
option proto 'static'
option netmask '255.255.255.0'
option ip6assign '60'
option gateway '192.168.0.1'
option dns '192.168.0.100'
option ipaddr '192.168.1.1'
option stp '1'
config interface 'wan'
option ifname 'eth1'
option proto 'dhcp'
config interface 'wan6'
option ifname '@wan'
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 4'
config interface 'wwan'
option proto 'static'
option ipaddr '192.168.0.201'
option netmask '255.255.255.0'
option gateway '192.168.0.1'
config interface 'stabridge'
option proto 'relay'
list network 'lan'
list network 'wwan'
option ipaddr '192.168.0.201'
root@OpenWrt:/etc/config# cat wireless
config wifi-device 'radio0'
option type 'mac80211'
option hwmode '11g'
option path 'pci0000:00/0000:00:00.0'
option htmode 'HT20'
option channel 'auto'
config wifi-iface
option device 'radio0'
option mode 'sta'
option network 'wwan'
option ssid 'my_router'
option encryption 'psk2'
option key '*******'
root@OpenWrt:~# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.0.1 0.0.0.0 UG 0 0 0 wlan0
192.168.0.0 * 255.255.255.0 U 0 0 0 wlan0
192.168.1.0 * 255.255.255.0 U 0 0 0 br-lan
I'm stuck. Any help would be much appreciated.
(Last edited by vic-t on 7 Mar 2018, 22:19)