Convert wan port to lan + provide wifi AP

I have an older TP-Link TL-WR1043ND (v1) and would like to use it as a 5 port switch + a wifi AP.

I think I can set up either of those configs okay, but have not managed to combine the two successfully yet.

There are instructions for moving the WAN port to LAN here:

I'm happy to edit configs rather than use the UI.

If I follow those instructions, how would I then enable the wifi AP?

I don't want this to do any DNS / DHCP / NAT / firewall etc.., just be a (5 port) switch + wifi AP.

Is that possible, and what extra steps do I need to follow?

Thanks!

This is usually quite simple to do.

From a default/reset state, follow the dumb AP guide. Then, post your /etc/config/network config file and we can show you how to add the wan port to the lan bridge.

Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button:
grafik
Remember to redact passwords, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
1 Like

Great, thanks - I think I was having problems because openwrt was quite outdated; I've flashed the latest build and the dumb AP config seems to have worked well.

I'd like the LAN interface to be a DHCP client as opposed to static (the guide mentions that this is better), and that seems okay too.

Hopefully just the WAN port left to do now. Here's the output of the commands as requested:

# ubus call system board
{
        "kernel": "5.10.176",
        "hostname": "topsecret",
        "system": "Atheros AR9132 rev 2",
        "model": "TP-Link TL-WR1043ND v1",
        "board_name": "tplink,tl-wr1043nd-v1",
        "rootfs_type": "squashfs",
        "release": {
                "distribution": "OpenWrt",
                "version": "22.03.5",
                "revision": "r20134-5f15225c1e",
                "target": "ath79/generic",
                "description": "OpenWrt 22.03.5 r20134-5f15225c1e"
        }
}
# cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'XX:XX:XX::/48'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'eth0.1'

config interface 'lan'
        option device 'br-lan'
        option proto 'dhcp'

config interface 'wan'
        option device 'eth0.2'
        option proto 'dhcp'

config interface 'wan6'
        option device '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 '1 2 3 4 5t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '0 5t'

Thanks!

The config you have should be fine.

And the method to add the wan port to be 'just another port' is really simple. Remove logical port 0 from the vlan2 stanza and add it to the vlan1 section:

When you're done, it will look like this:

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '0 1 2 3 4 5t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '5t'

That all seems to be working perfectly.

Thank you very much for your help @psherman !

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.