Openwrt to use LAN port as WAN port

Hello, I am new to open wrt and it seems iam missing some vacabulary. I attached my home network at the given moment.

Cablemodem/router is a Vodafone Station which atm. acts also as DHCP server. Wifi is off.

All my rooms in the house have point to point cable connections which i did myself during rennovating the house.

So the genreal setup is atm the 2 mentioned rooms in my drawings have several PC/sLaptops which connect to a small switch which then connects to the eth. plug in the wall. The corresponding plug in the living room connects also to a switch and that switch then goes to the vodafone station. Everything runs on 1Gbps, stable and fine (kinda proud that my entire cabeling works)

What is depicted as Openwrt, is atm an old ASUS router which can not run openwrt and is so old that asus does not update it anymore and now has several massive security issues. The thing runs as access point and provides wifi to the entire house.

the idea is the following:

  • add a PiHole to filter Ads and other stuff on network level. It turns out i cannot reroute the DNS sever on the vodafone station. The thing does not have the option and internet searches confirm that issue.

  • following idea was to get myself in the same run a new wifi router, replace the old asus, put openwrt on it. Let it act also as DHCP server, and then tell openwrt to tell the clients the PiHole is the DNS server.

I got myself a Fritzbox 4040 (no modem included, as i will change to fiber in the coming months) and managed to get openwrt on it. I have a raspi with installed pihole on it.

But the issue seems that the position of the openwrt is in room 2, there is no direct connection from the WAN port to the modem possible. Its only the lan connection. otherwise the other clients in that room are out.

So how i configure this mess to operate as i want. I deactivated the DHCP server on the vodafone station and gave it as static ip. Openwrt got and the DHCP activated.

Openwrt seems to want to route internet via the WAN port which is not connected. I need to tell it "Hey use as your door to the internet.

I think i have to put the vodafone station in bridge mode (which is possible via the web interface from vodafone) but the rest of the configuration in openwrt eludes me.

So if one could direct me to the right vacabulary what to search or a guide or something would be gread. thx

If you can put your current ISP router into bridge mode then that's the easiest option. Then put your OpenWRT device in between the ISP router (connecting via the WAN port) and the main switch (via one of the LAN ports).

it is not possible, as my router is in another room and the ethernet cabled shall also service all clients in room 2. I need a config which uses this one cable from room 2 to living room as a LAN connection for all the clients

If you put your existing ISP router into bridge mode then you can use the fritzbox (which I assume is what you've put OpenWRT on) as the router instead. So in your diagram it essentially replaces the 'Modem/Router' in the living room.

I would configure the OpenWrt router as a "dumb AP" first, check that everything works as expected, then move the DNS to it.


The position in Room 2 is ideal for WiFi coverage of the house, as room 2 is one level up in the house. Its the sweetspot. I would like to leave it that way.

Regarding the Accesspoint Idea. Can an Access point be the DHCP? Otherwise my entire pihole idea goies out the windows due to the lacking dns options in the vodafone router

Given the current setup there is not much you can do with OpenWrt in room2. You'd need managed switches and vlans to separate the wan from the lan and be able to transfer the internet from the living room to room2 wan port of OpenWrt, then from OpenWrt lan port to provide connectivity to the rest of the house.
If you need OpenWrt as router, it better be placed in the living room between modem and switch (optional).
If you want an access point, you can use whatever device, running OpenWrt or not, in room2.

1 Like

I did not propose to change that... but, if you are going to use it as a dumb access point, I think you should start by configuring it as a proper access point.

Yes, a router is a router, and "dumb ap" is just the role, and how you configure it. Then, you can configure the DHCP server in the OpenWrt router (just remember to use the current router as a gateway), and disable DHCP in the current router.

1 Like

so if i get a second very small router that can run openwrt, something strong enough to handle a 1Gbps fibre connection,. yet small and power efficientso it does not unnecassary blow up my power bill, it should work?

Yes, there are discussions for small routers capable of 1Gbps with small consumption.

So atm i have two conflicting statements.

One says " make access Point and then configure the AP as DHCP"

The other says that's note possible with my setup.

What is true now?

It depends on 2 things.

  1. What will be the role of OpenWrt? Router or dumbAP?
  2. Where can it be placed? Living room or room 2?
1 Like

It shall be placed in room 2.
It shall provide Wifi for the house.
It shall provide the DHCP server,
It shall tell the clients that my pihole is the DNS server.

The Vodafone station shall only be a dumb modem which can be replaced when i change my ISP from cable to fiber.

The idea is essentially that all hardware i don't have under control, like ISP provided Router/Modem combos are only there to connect to the internet and my network is completely behind that.

Then it can be done with a not-so-dumbAP, which will serve DHCP and advertise Pihole with option 6.

1 Like

This can be done with OpenWRT as an AP. You can have it on the network running DHCP telling other connected devices that they should use the pihole for DNS and the Vodafone Station as the default gateway.

This you can't do with OpenWRT just as an AP. You either need the Vodafone Station (or the next ISP replacement) to act as the router, or the OpenWRT device. If it's the latter then you either need to put the OpenWRT device between the ISP modem and the first switch, or invest in smart switches and use VLANs.

1 Like

You could do this using managed switches allowing you to create VLans over the Cable that goes from the Living room to Room 2. That would be the cleanest option to archive this.

Though if you are ok with the nets not being seperated cleanly you could also just share the L2 Network with Seperate IPs.

ISP Router:

  • IP Range
  • DHCP on LAN disabled

Room 2 Router:

  • WAN Static IP within the net
  • LAN Static IP whithin network DHCP enabled

Without knowing much about the ISP's router I'm not sure if you could prevent the double NAT that this would create.

Note that this is far from optimal since any Client within your network could just set themselves a IP within the network and reach the ISP router directly, circumventing your OpenWRT Router. Also note that this is quite a complicated setup compared to getting another OpenWRT box in the Living room having that be the Main Router and having a simple dumb AP in Room 2.

It's not though is it? The cleanest way to achieve having the OpenWRT device as the main router would be to put it in the correct place, i.e. between the modem and first switch. VLANs could work but are more complicated and could still lead to some of the issues you later mention.

And unless the @rizzorat already has managed switches in their setup it'll likely cost as much (if not more) to get them, rather than just picking up an AP to put in room 2.

1 Like

If your goal is to have the main router in Room 2 I believe it would be.

If your goal is to have OpenWRT as the main router, then putting it into the living room would be the cleanest setup. No doubt about that.

I think there is a lot of confusion in this thread, because the question points in a wrong direction.

What OP really needs is to add a PiHole to a network where he cannot control the main DHCP server. All the debate about LAN/WAN ports and VLANs is misleading, because none of that is needed (despite what the title implies) to achieve the goal.

  • First, the OpenWrt router has to be configured as a "dumb AP" (with its DHCP server inactive), and connected to the existing network through one of its LAN ports. The network will continue to operate normally.

  • Second, the OpenWrt router has to be configured with a static IP address (in the same range as the ISP router, but with a different address) and its DHCP server enabled, with two precautions: the gateway announced has to be the ISP server, and the DNS server has to be /; then, the the DHCP server on the ISP router has to be switched off. The network will continue to operate normally.

  • Now, once the PiHole has been configured and tested, the DHCP server on the OpenWrt has to be configured to use/announce the PiHole as a DNS. The network will continue to operate normally, but without ads.

  • As a "plus one" feature, the OpenWrt router can be configured to bridge its LAN and WAN ports, so you can connect it to the switch through the WAN port, and free all the LAN ports (and, eventually, get rid of the switch on room 2).

One caveat of this scenario is that you will not be able to block devices that use their own DNS, instead of the one provided by the DHCP server.