Relayd Interface


I have relayd installed and initially just lan and wwan connected through it. However, I have had it completely crash OpenWRT when I attempt to add another device/interface. Is there anyway of using relayd without it crashing the device? Currently reinstalling OpenWRT because I tried add another interface to the relayd interface while the interface was still running.



In order to better assist you, it may be good to provide more information:

  • The make/model of your device
  • Version of OpenWrt your device is running
  • Your configs
  • Your use case - basically, it's not obvious why relayd is needed in the setup described in your first post
  • Clarify what you mean by "reinstalling OpenWrt" because you tried to "add another interface to the relayd interface while the interface was still running" - did you mean "Reset"?
	"kernel": "5.10.161",
	"hostname": "OpenWrt",
	"system": "ARMv8 Processor rev 4",
	"model": "Bananapi BPI-R64",
	"board_name": "bananapi,bpi-r64",
	"rootfs_type": "squashfs",
	"release": {
		"distribution": "OpenWrt",
		"version": "22.03.3",
		"revision": "r20028-43d71ad93e",
		"target": "mediatek/mt7622",
		"description": "OpenWrt 22.03.3 r20028-43d71ad93e"

running on a BPi R64. Needed the relay to pass the 10.1.1.* subnet of my main router through to my desktop pc. Without it would just be assigned an address in the range. I not sure if I tested with before I reinstalled but it working now just with the lan and wwam interfaces connected via the relay.


Just tested again and can not access the device via either (yes, have to reinstall after checking).

Here's an example config I use to relay to a settop box. I make an interface and add the PHYs, the protocol is "none" I then add that interface the the upstream interface to the created relay interface:

config interface 'wwan'
        option proto 'dhcp'

config interface 'media_lan'
        option proto 'none'
        option device 'eth0.3'

config interface 'media_br'
        option proto 'relay'
        list network 'media_lan'
        list network 'wwan'

Hope this helps.

So you can only connect two interfaces?

Honesty, I don't know.

If you need to connect mutiple interface to an upstream relay interface - make all the downstream PHYs one bridge, then add the bridge

If you want more detailed answers, you may want to provide detailed descriptions/details of the interfaces you which to relay, etc.

At the moment I have wwan, lan and vpn. Was wanting to relay vpn with wan and lan

I'm not sure what this means. Are you saying that you want to relay the wwan to both [a Layer 2-based] VPN and lan?

(:spiral_notepad: The VPN must be Layer 2.)

Is OpenVPN Layer 2?

That depends on how you have it configured currently.

Also, mobile devices don't do Layer 2 OpenVPN. See:

So if your working OpenVPN clients were mobile, you can be assured it's likely Layer 3 and not 2.

relayd is for the specific use case of making a psuedo "layer 2 bridge" over a conventional AP-STA wifi link. It is not applicable to any other situation.

OpenVPN would be either routed layer 3, or if you have TAP OpenVPN on both ends it can be conventionally bridged.

1 Like

FYI, the OPs upstream interface is a STA:

So to be clear, if OP's OpenVPN is a TAP interface, OP can indeed:

  • Bridge LAN and VPN (or add VPN into the existing LAN bridge)
  • Add bridge to relay with wwan


That is fine if you're going to VPN everything from the LAN anyway.

That doesn't make a lot of sense. Relayd is written for the one very specific use case of a "wireless extender" and it breaks standards to do it.

If you want to include devices on the non-OpenWrt main router into the OpenWrt lan and vpn networks it would be better to convert to OpenWrt being the main router and relegate the original router to be a link to the Internet only. Or use symmetric routing if you have any control of the main router (ability to install static routes on it).

1 Like

This is how it is setup! The only thing I have changed is the port number.