Creating LAN to WLAN bridge wifi repeater

Hello everyone!

I have a small Fritzbox 7312 and I installed OpenWRT onto it. I would like to use this Fritzbox 7312 as wifi repeater, by means of bridging the LAN port to the WLAN port (yes, LAN->WLAN). My main router provinding internet is a Fritzbox 7330 with stock firmware, onto which I cannot install openWRT, because I'm using the DECT functionality for telephones. As far as I read, openwrt has no support for it.

This Fritzbox 7330 router isn't able to cover all the house with the wifi signal and some devices cannot connect to internet at all. So, what I'm trying to do is to wire both routers to the LAN ports (LAN2 on 7330 and LAN1 on 7312) and create a bridge from the LAN port to the WLAN interface on the Fritzbox 7312. I would like the devices on the repeater side to be on the same subnet as the main router. I have read several tutorials (e.g: https://openwrt.org/docs/guide-user/network/wifi/dumbap https://openwrt.org/docs/guide-user/network/wifi/bridgedap relay_configuration etc), but I guess all of them are bridging the interfaces the other way around (WLAN->LAN).

So my question is: How can I create this bridge?

Best regards,

Ch.

Unless I'm missing the obvious, this sounds like a classical use case of https://openwrt.org/docs/guide-user/network/wifi/dumbap

2 Likes

This is exactly one of the tutorials I followed but it didn't work for me. This is the config Im using:

/etc/config/network:

config interface 'lan'
        option type 'bridge'
        option ifname 'eth0 wlan0'
        option proto 'static'
        option ipaddr '22.3.7.2'
        option netmask '255.255.255.0'
        option gateway '22.3.7.1'
        option igmp_snooping '1'
        option stp '1'
        option dns '22.3.7.1'

And for wireless:

/etc/config/wireless:

config wifi-device 'radio0'
        option type 'mac80211'
        option channel '11'
        option hwmode '11g'
        option path 'pci0000:00/0000:00:0e.0'
        option htmode 'HT20'
        option disabled '0'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option ssid 'wifi'
        option encryption 'psk2'
        option mode 'ap'
        option key 'key'

Firewall and dnsmasquerade are disabled. This actually doesn't work. The main router doesn't even know there is another device connected on the second LAN port.

What am I doing wrong here?

best regards,

Ch.

My two cents:

  1. Do you really own the 22.3.7.0/24 network?
  2. Do not bridge eth0 and wlan0 at the network configuration.
  3. What tests have you performed?
1 Like

No the OP doesn't, all of 22.0.0.0/8 is owned by the US Department of Defense.

  • Lastly, can you ping the xxx.xxx.xxx .1 IP?
  • Do you have a link llight on your upstream router's LAN port?
  • Do you have a link light on the Fritzbox 7312?
1 Like

Hi Eduperez,

I don't know exactly what you mean by owing the network. But the local network is on 22.3.7.x and the main router is located at 22.3.7.1.
I also tried to not use the wlan on the bridge config, but it doesn't work either.

Hi Ileachii,

I can ping the 22.3.7.1 (main router) only when I'm connected to the main router's wifi network. If I'm connected to the secondary router's wifi network is out of reach.
nmap doesn't report the second router is active, nor does it the Fritzbox 7330's stock web interface. Also, both routers have actually no lights on the LAN ports, so I can't really tell if something actually happens and I have to trust nmap and this web interface. On the 7312, the DSL/Power light stays on and the WLAN light blinks. That's all I can tell

Thanks for your answers!

Ch.

Don't refer to wifi in /etc/config/network. In other words your option ifname eth0 wlan0 should just be option ifname eth0. The wifi will get connected by its option network in /etc/config/wireless. You can confirm this with brctl show which should show ethernet and wifi in the br-lan bridge.

If you shut down dnsmasq entirely the DNS will stop working. It is better to leave it running but set option ignore on the lan network so it does not attempt to issue DHCP on the LAN. Also you have to turn off the IPv6 options separately.

If there are link lights on the ethernet ports but they're not lighting up there is a problem with the link. You can also get connection status and byte counts with ip link show or swconfig dev switch0 show if there is a switch involved.

To ensure proper wifi operation be sure to set your country code in the wifi-device block.

1 Like

Hello mk24,

Thanks for your answer. Yes, I have removed wlan0 from bridge configuration. Now it tries to get ip address but it doesn't connect to the network.

Both routers have no physical lights attached to the LAN ports, as many ethernet ports do actually have. The only existing lights on both routers only show general information (power on/off, internet, WLAN, DECT, etc.), but no traffic.

Im going to check if with the dnsmasquerade works.
Best regards,

Ch.

You could put an unmanaged switch in the line between the two routers then watch the carrier and traffic LEDs on the switch.

So, I so far this is what I have tested:

->wlan0 removed from bridge config
->dnsmasq on
->dnsmasq off
->changed wifi name

None of these seem to work. Main router won't detect the second. I was wondering if the lan cable should be crossed or not. I guess it shouldn't be necessary since I can connect to the internet when I connect the main router with my laptop using the same cable.

The weirdest thing is, it won't connect to the wifi network. No matter if the name is the same or different than that of the main router. Could it be that the Fritzbox 7330 is blocking the openwrt router somehow?

Best regards,

Ch.

In a dumb AP configuration, a device connecting to the AP negotiates its IP from the main router via DHCP, so if there is no link to the main router the device will give up at the "Obtaining IP address" stage (this is what Android shows to the user).

Modern equipment all will automatically swap TX and RX so crossing cable is almost never needed. But I really suggest you plug the dumb AP into a device that has a link light and that light does not come on something is wrong.

2 Likes

What do you mean with "main router won't detect the second"? What are you expecting to happen?

Unless you are the US department of defense, you should not use that network. Your main router is misconfigured.

If I enable DHCP for the LAN interface, the second router should get an IP address from the main one, but this doesn't happen. Or am I wrong?

Why am I not allowed to use the 22.x.x.x network as my local network? I don't see the point on prohibiting this.

The 22.x addresses may exist on the Internet, so there is a potential conflict. What this means in practical terms is that if for example the US Army has hosted a public web page with a 22.3.7.x IP, users of your network won't be able to reach it, they will contact something within your LAN instead.

There is absolutely no reason not to use the designated "private" IP's on the private side of your network.

1 Like

I made another try. I set DHCP on the LAN interface of the 7312 router with openwrt. It doesn't work either. I simply don't understand.

Best
Ch.

You still don't know if the 7312 Ethernet port even works at level 1.

Yes, exactly. Can we see the config files and the logs when you make this test, please?