Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
docs:guide-user:network:wifi:relay_configuration [2019/09/02 12:50] – [Setup with Luci GUI] reformat text, add gateway and DNS settings brianpowdocs:guide-user:network:wifi:relay_configuration [2024/06/22 06:26] – Final editorial pass richb-hanover
Line 1: Line 1:
-====== Wifi Extender or Repeater or Bridge Configuration ======+====== Wireless Repeater/Extender with Relayd ====== 
 +This article describes how to make an OpenWrt router into a Wi-Fi repeater/extender/bridge. 
 +It makes a Wi-Fi connection to the "main router" with one of its radios, 
 +and acts as an AP (access point) for local devices with another radio.  
 +The extender then relies on the ''relayd'' package to bridge between the two connections.
  
-<WRAP center round important 80%> +For the sake of simplicity, this article will use the term "Wi-Fi extender" from now on.
-Using relayd as instructed in this article isn't guaranteed to work.\\ +
-The most common problem is that the client router cannot pass the DHCP message between the main router and the client connected to the client router. Currently it seems to be the hardware/SOC limitation (related to MAC cloning?)\\ +
-You may also consider to use [[docs:guide-user:network:wifi:atheroswds|WDS]] or [[docs:guide-user:network:wifi:mesh:start|mesh networking]].\\ +
-Instead of relayd it should be possible to use **kmod-trelay**the only information about using it can be seen in [[https://github.com/openwrt/openwrt/commit/c3bba7f8c61ee98265bcffef8ee86e22aa89bbe9|its source code]], if you used it successfully please add a section for it in this article.\\ +
-</WRAP>+
  
 +This configuration is useful where you do not control the main router,
 +where the main router does not run OpenWrt,
 +or does not support preferred [[docs:guide-user:network:wifi:atheroswds|Wireless Repeater/Extender with WDS]]
 +or [[docs:guide-user:network:wifi:mesh:80211s|802.11s Mesh Networking]].
 +You may also wish to consider using an alternate [[:docs:guide-user:network:wifi:connect_client_wifi|simple wireless client]] where bridged network is not required.
  
-In this article you will see how to configure your device to become WiFi Extender/Repeater/Bridge.\\+There is Youtube video that shows substantially the same procedure as described below: 
 +https://www.youtube.com/watch?v=Bfmx5NjIWLQ
  
-Since opensource wireless drivers used in OpenWrt do not support bridging in client mode, the traffic between LAN and the wireless client must be joined by routing it.\\ The **relayd** package implements a bridge-like behavior complete with DHCP and Broadcast relaying. This configuration can be done through SSH (remote terminalor through Luci GUI.\\ For the sake of simplicity, I'll call the device we are working on "wifi extenderfrom now on.+The image below shows the normal configuration. 
 +The "main router" is on the right: its WAN port connects to the internet, 
 +and its LAN port (192.168.1.1/24serves local clients 
 +The Wi-Fi extender is on the left.  
 +It makes a wireless connection (labeled "W-LAN (Client)") as a client to the main router. 
 +The Wi-Fi extender's other radio acts as an access point for local devices.
  
 \\ {{ docs:guide-user:wifirepeater_802.11-routed-relay.png |}} \\  \\ {{ docs:guide-user:wifirepeater_802.11-routed-relay.png |}} \\ 
  
-This image shows an example setup. **LAN** interface of the wifi extender device MUST be on a different subnet for relayd to work (since it is routing traffic, it expects 2 different subnets).+Other notes on the configuration:
  
-Since both ethernet ports and Access Point WiFi network are on the same **LAN** interface, all clients connecting to the Ethernet ports and to the Access Point Wifi network of the WiFi extender device will be routed by **relayd** and will be connected to your main network.+Even though all end devices on the Wi-Fi extender will get a DHCP address from the main router's LAN subnet, the **LAN** interface of the Wi-Fi extender MUST be on a different subnet for relayd to work (since it is routing traffic, it expects 2 different subnets). 
 +The rest of this article uses 192.168.2.1 as the "Wi-Fi extender subnet".
  
-The **LAN** interface subnet will be used only as a "management" interface, as devices connecting to the wifi repeater will be on the main network's subnet instead. You will have to set your PC with a static address in the same subnet as the **LAN** interface (like 192.168.2.10 for our example) to connect again to the wifi repeater's Luci GUI or SSH.\\+Since both ethernet ports and Access Point Wi-Fi network are on the same **LAN** interface, all clients connecting to the Ethernet ports and to the Access Point Wi-Fi network of the Wi-Fi extender device will be routed by **relayd** and will be connected to your main network.
  
-===== Required packages ===== +The **LAN** interface subnet will be used only as a "management" interface, as devices connecting to the Wi-Fi repeater will be on the main network's subnet instead. If the relayd device becomes unreachable, you will have to configure a PC with a static address in the same subnet as the **LAN** interface (eg. 192.168.2.10 for our example) to connect and be able to use LuCI GUI or SSH.
-==== Compulsory ====  +
-**relayd** package  +
-==== Optional ==== +
-**luci-proto-relay** for LuCI Web Interface+
  
-===== Setup with LuCI Web Interface ===== +You may use the same Wi-Fi network name (SSID) and encryptionpassword, etc. 
-As shown in the image above, the **LAN** interface must be set in a different subnet than the wifi network you are connecting to.+settings on the Wi-Fi extender as your main router. 
 +This allows wireless devices connected to your (wider) network to roam to the best Wi-Fi network.  
 +Alternatively, you can also choose to have a different SSID name/encryption/password on the Wi-Fi extender. 
 +  
 +This procedure has been tested with OpenWrt 23.05.
  
-Begin by configuring and enabling the normal WiFi network and configure it as you want it.\\ 
-If you are making a simple WiFi Repeater (a device that extends the same wifi network's coverage) it's a good choice to set this WiFi network to be the same as the one of your main router, same name, encryption, password, and so on. This way, devices connected to your (wider) network will automatically stay connected to the best WiFi network.\\ 
-But you can also choose to have a different name/encryption/password if you prefer to.\\ 
-Setting up a WiFi network at this stage is not necessary if you want a "WiFi bridge", a device designed to connect ethernet-only devices to your existing WiFi network. 
  
-\\ {{ :docs:guide-user:wifirepeater_interfaces_lan.png |}} \\ +===== Setup with LuCI Web GUI =====
  
-  * Set **LAN protocol** as **static address**  +==== Configure LAN Interface ==== 
-  * Assign an IP address in different subnet (e.g. 192.168.2.1) +The **LAN** interface of the Wi-Fi extender must be set in different subnet than the main router. 
-  * Disable DHCP for the **LAN** interface (as it does prevent **relayd** from working).  + 
-  * (May be required in certain case) set **Gateway address** and **Use custom DNS servers** using IP address of the primary router (e.g. 192.168.1.1)  +  * Remove any wired connections between your Wi-Fi extender and your main router. 
-  * Save and Apply.+  * Connect a computer with Ethernet to a LAN port on the Wi-Fi extender and log into LuCI web UI at 192.168.1.1 (default address
 +  * (Optional) Update the firmware of the Wi-Fi extender to the current release. 
 +  On **System -> Backup/Flash Firmware**, click **Perform reset** to return to default OpenWrt settings
 +  * Go to **Network -> Interfaces**, click **Edit** for the LAN interface 
 +  * Set **LAN protocol** to **static address**, click **Change protocol** 
 +  * Assign an IP address using the "Wi-Fi extender subnet" (e.g. 192.168.2.1 - see image below). Click **Save**. 
 +  * Click **Save and Apply**. 
 + 
 +\\  {{media:docs:howto:relay_lan_changeip.jpg?400|}} \\
  
 ---- ----
  
-Set your PC's ethernet or wifi settings at static IP 192.168.2.10 and default gateway 192.168.2.1, then connect again to the wifi repeater (through ethernet or wifi)When you finish all of the following stepsremember to reset your PC's IP address back to the original address (or DHCP)otherwise you won't have Internet accessThe repeater won't route traffic from the 192.168.2.0/24 subnet.+  * Reconnect to router at its new IP address (eg. 192.168.2.1
 +  * From **Network -> Interfaces**click **Edit** for the LAN interface 
 +  * Click the **DHCP Server** tab and disable DHCP, IPv6 RA-Service, and DHCP-v6 ServiceTo do this: 
 +     * On the **General Settings** tabcheck the "Ignore interface" box to disable DHCP for the interface. 
 +     * On the **IPv6 Settings** tab, choose "disabled" for **RA-Service** and **DHCP-v6 Service** 
 +     * See images below 
 +  * Click **Save**. 
 +  * Click **Save and Apply**. 
 +  * Finally, set your PC'Ethernet port to use a static IP in the Wi-Fi extender subnet 
 +(e.g.192.168.2.10) and default gateway (e.g., 192.168.2.1), 
 +then connect again to the Wi-Fi extender via Ethernet.  
 +  
 +\\ {{media:docs:howto:relay_lan_disableDHCP.jpg?400|}} \\  
 +---- 
 +\\ {{media:docs:howto:relay_lan_disableIPv6.jpg?400|}} \\ 
  
-We will now set up the client wifi network, the configuration needed to connect to another wifi network.\\ Once you are connected again to the wifi extender, go in the wireless networks page, and click on **Scan** button.\\+==== Configure Wi-Fi Interface ====
  
-\\ {{ :docs:guide-user:wifirepeater_joinnetwork_wifi_scan.png |}} \\ +To configure the Wi-Fi connection to the main router.  
 +  * Keep your PC connected to the Wi-Fi extender via Ethernet. Remove any other physical connections. 
 +  * Navigate to the **Network -> Wireless** page 
 +  * Choose a radio to connect to the main router. Typically this should be a b/g/n radio, since they have longer range than 5GHz radios 
 +  * Click on **Scan** button for that radio.
  
-Choose the wifi network you want to connect to from the page and click "Join Network".\\ +\\ {{media:docs:howto:relay_join_wifi_1.jpg?800|}} \\  
 +  
 +  * From the list of SSIDs found in the scan, choose the Wi-Fi SSID from the main router and click **Join Network**. 
 + 
 +\\ {{media:docs:howto:relay_join_wifi_2.jpg?800|}} \\   
  
 ---- ----
  
-\\ {{ :docs:guide-user:wifirepeater_joinnetwork_settings.png |}} \\ +  * You'll see the "Joining Network" pane (image below). 
 +     * Set the "Name of new network" to "wwan" 
 +     * Enter any Wi-Fi credentials such as WPA passphrase 
 +     * Select **lan** firewall zone.  
 +  * Click **Save**. 
 +  * Click **Save & Apply**.
  
-Enter the wifi password, leave the "name of new network" as "wwan" and select **lan** firewall zone. Click Save.\\+\\ {{media:docs:howto:relay_join_wifi_3.jpg?600|}} \\ 
  
 ---- ----
  
-----+You will see the client Wi-Fi settings page (image below). Edit as required. 
 +The most important settings are on the **Operating Frequency** line. 
 +  
 +  * Set the **Mode** to **Legacy** if you are connecting to a Wi-Fi g network, or **N** if you are connecting to a Wi-Fi n (and so on).\\  
 +  * Set the **Width** to the same channel width as the main router 
 +  * Keep the same Wi-Fi channel number. The extender must match the main router. 
 +  * Click **Save** when finished.  
 +  * Click **Save & Apply**. 
  
-\\ {{ :docs:guide-user:wifirepeater_clientwifi_settings.png |}} \\ +\\ {{media:docs:howto:relay_join_wifi_5.jpg?550|}} \\  
 +==== Remove redundant WAN interface and firewall zones ==== 
 +  
 +Although it's optional, it is recommended to delete the redundant WAN interfaces and firewall zones.  
 +  
 +  * Go to **Network -> Interfaces** (image below) 
 +  * Delete both ''WAN'' and ''WAN6'' 
 +  * Go to **Network > Firewall** (image below) 
 +  * Delete the ''wan'' rule 
 +  * Click **Save & Apply** 
  
-You will land in the client wifi settings page, set other things as needed.\\ The most important settings are on the **Operating Frequency** line.\\ Set the **Mode** to **Legacy** if you are connecting to a wifi g network (like in my example) or **N** if you are connecting to a wifi n (and so on).\\ Set the **Width** to the same value that you set on the wifi you are connecting to (to avoid bottlenecking the connection for no reason).+**Note:** These actions will also automatically remove any redundant firewall traffic and port forwarding rules.
  
-----+\\ {{media:docs:howto:relay_wan_delete.jpg?800|}} \\ 
  
-----+\\ {{media:docs:howto:relay_firewall_delete_wan.jpg?800|}} \\  
 +==== Add static IP on wwan ==== 
 +   
 +It is recommended to assign a static IP address to newly created wwan interface.  
 +This should be in the same subnet as the main router's LAN (eg. 192.168.1.30). 
 +You can then manage the router using this static IP address. 
 +This static IP address will also be used later when creating the Relay interface.  
  
-Go in the **Interfaces** page, we will now add the relayd interface that will join the **lan** and **wwan** interfaces.\\ +  * Go to **Network -> Interfaces** (image below) 
-Click on **Add New Interface**.\\+  Click **Edit** for the ''wwan'' interface
  
-\\ {{ :docs:guide-user:wifirepeater_newinterface.png |}} \\ +\\ {{media:docs:howto:relay_wwan_static_1.jpg?800|}} \\
  
- Write a name for it (**repeater_bridge** is the name I used in the example), and then choose **Relay bridge** in the **Protocol of the new interface** fieldClick **Submit**.+  On the **General Settings** tab, change the protocol to 'Static Address' (image below) 
 +  * Enter an IP address from the main router's LAN subnet (e.g., 192.168.1.30); a subnet mask (e.g.255.255.255.0); and a gateway IP address, usually the LAN IP address of your main router (e.g., 192.168.1.1)
  
-----+\\ {{media:docs:howto:relay_wwan_static_2.jpg?500|}} \\
  
-\\ {{ :docs:guide-user:wifirepeater_relaybridge1.png |}} \\ +  * On the **Advanced Settings** tab (image below) 
 +  * Set **Use custom DNS Servers** to the IP address of the main router (e.g., 192.168.1.1). 
 +  * Press **Save**  
 +  * Press **Save & Apply**
  
-In this new interface's setting page, select both **lan** and **wwan** in the **Relay between networks** list.+\\ {{media:docs:howto:relay_wwan_statis_3.jpg?500|}} \\ 
 +==== Test Connection ====
  
-This interface needs to have an IP address from 192.168.1.0/24 zone otherwise this bridge will not be accessible from the clients connected directly to the primary router. +At this point, the Wi-Fi extender should be wirelessly connected to the main router. 
-----+To verify the the connection:  
 +  * Go to **Network -> Diagnostics** 
 +  * Perform a ping test by clicking the "IPv4 Ping" button. 
 +  * A few moments later, you should see ping results if the main router is connected to the internet. 
 +  *  
 +\\ {{media:docs:howto:relay_network_test.jpg?500|}} \\
  
-----+==== Install relayd package ====
  
-\\ {{ :docs:guide-user:wifirepeater_relaybridge2.png |}} \\  +  * Go to **System -> Software**
-Move to the Firewall tab of this interface settings page and select **lan**. Click on **Save and Apply**.+  * Click **Update List** button. If the Wi-Fi extender is connected to the main router, and that is connected to the internet, a few moments later, the results of the update appears. 
 +  * Enter **luci-proto-relay** into the Filter box (image below), and click **Install**. 
 +  When that completes, reboot the router from **System -> Reboot** (image below).
  
-----+\\ {{media:docs:howto:relay_package_1.jpg?800|}} \\
  
-----+\\ {{media:docs:howto:relay_package_2.jpg?400|}} \\
  
-After you have done this, it might be necessary to reboot the wifi extender.+==== Create Relay Interface ====
  
-\\ {{ :docs:guide-user:wifirepeater_final_result.png |}} \\ +Add the ''relayd'' interface that will join/bridge the **lan** and **wwan** interfaces. To do this: 
 +  * Go to **Network -> Interfaces** 
 +  * Click on **Add New Interface** (image below)
  
-This is the final resultNote how the client network has ? instead of IP address.+\\ {{media:docs:howto:relay_create_bridge_3.jpg?500|}} \\ 
 +  * In the **Add new interface** window (image below) 
 +    * Enter name ("repeater_bridge" is good choice) 
 +    * Select **Relay bridge** protocol as shown below. (Reboot your device if the **Relay bridge** option fails to appears.)  
 +  * Click **Create Interface**   
  
-----+\\ {{media:docs:howto:relay_create_bridge_1.jpg?900|}} \\
  
-----+  * In **Network -> Interfaces**, click **Edit** for the new "repeater_bridge" interface (image below) 
 +    * Enter the IP address assigned to the ''wwan'' interface. (eg. 192.168.1.30)  
 +    * Select both **lan** and **wwan** in the **Relay between networks** list. 
 +  * Click **Save**. 
 +  * Click **Save & Apply**. 
 +  * After you have completed above steps, reboot the router. 
  
-:!The following part of the configuration should not be necessary (already default options or changed automatically), in case something isn't working check this too+\\ {{media:docs:howto:relay_create_bridge_2.jpg?500|}} \\
  
-\\ {{ :docs:guide-user:wifirepeater_firewall.png |}} \\  +==== Enable the AP ==== 
-Under the **Network** tab, click on the **Firewall** tabUnder **Zones**, change the forwarding for **lan** and **wwan** to **accept**+Enable and configure the Wi-Fi extender to be an access point for local devices.
  
-----+  * Go to **Network -> Wireless** 
 +  * Click **Edit** button for any item with **Mode: Master**. (Don't edit your Client connection to the main router.) 
 +    * In the Interface Configuration section, configure SSID, security and other parameters of your Wi-Fi extender so it can act like an access point.  
 +    * If you are configuring the same radio that also serves as the client connection to the main router, ensure the **Operating frequency** matches the Client network. 
 +    * Click **Save** 
 +  * **Enable** the wireless network. 
 +  * You might edit/enable other radios (for example, enabling both the b/g/n and n/ac/ax/etc. radios) 
 +  * Click **Save & Apply**.
  
-----+==== You're Done More Testing ====
  
-:!: if you are doing this with a device that has a single radio, both wifi networks will stay on the same channel, and total bandwith will be halved as the same radio is used for 2 different wifi networks.+After configuring the Wi-Fi extender's APchange your computer back to DHCP client mode 
 +and connect to the newly-configured Wi-Fi. 
 +Your computer should be fully on the internet, having acquired a DHCP IP address from your main router.  
 +The Wi-Fi extender can be managed through its static ''wwan'' IP address (eg. 192.168.1.30) 
  
 +The **Status -> Overview** window (image below) shows the final result.
 +''radio1'' is a DHCP client to the main router.
 +''radio0'' (the access point) has not been configured/enabled yet. 
 +The client Wi-Fi has a ? in the **Host** column instead of a IP address 
 +because its ''wwan'' IP address is only visible in the Network Interfaces page.  
  
 +\\ {{media:docs:howto:relay_status_1.jpg?800|}} \\
  
 ===== Setup with CLI ===== ===== Setup with CLI =====
  
-Before doing any actual configuration, the wifi interface must be enabled in order to be able to scan for networks in the vincinity:+Before doing any actual configuration, the Wi-Fi interface must be enabled in order to scan for networks in the vicinity:
  
-<code>uci set wireless.@wifi-device[0].disabled=0+<code bash> 
 +uci set wireless.@wifi-device[0].disabled="0"
 uci commit wireless uci commit wireless
-wifi</code>+wifi 
 +</code>
  
   * Set the disabled option to 0 (to enable wireless)   * Set the disabled option to 0 (to enable wireless)
Line 135: Line 240:
 ''iw dev wlan0 scan'' output example:\\ ''iw dev wlan0 scan'' output example:\\
  
-<code>root@OpenWrt:/# iw dev wlan0 scan+<code bash> 
 +# iw dev wlan0 scan
 BSS c8:d5:fe:c8:61:b0(on wlan0) -- associated BSS c8:d5:fe:c8:61:b0(on wlan0) -- associated
         TSF: 24324848870 usec (0d, 06:45:24)         TSF: 24324848870 usec (0d, 06:45:24)
Line 181: Line 287:
                  * Pairwise ciphers: TKIP CCMP                  * Pairwise ciphers: TKIP CCMP
                  * Authentication suites: PSK                  * Authentication suites: PSK
-                 * Capabilities: 1-PTKSA-RC 1-GTKSA-RC (0x0000) </code>+                 * Capabilities: 1-PTKSA-RC 1-GTKSA-RC (0x0000) 
 +</code>
  
-In the example, there are two networks, a Wifi g one called Violetta and a Wifi n one called GOinternet_EB20FB.+In the example, there are two networks, a Wi-Fi g one called Violetta and a Wi-Fi n one called GOinternet_EB20FB.
 The device was configured to connect to the one called Violetta. The device was configured to connect to the one called Violetta.
  
 These are the uci values that were added or changed by the configuration procedure.\\ These are the uci values that were added or changed by the configuration procedure.\\
-For SSID, BSSID, and encryption you must use the info you got from the wifi scan above.\\+For SSID, BSSID, and encryption you must use the info you got from the Wi-Fi scan above.\\
 For an explanation of why these values were changed, please read the luci tutorial above.\\ For an explanation of why these values were changed, please read the luci tutorial above.\\
  
-<code>network.lan.ipaddr='192.168.2.1'+<code bash> 
 +network.lan.ipaddr='192.168.2.1'
 network.repeater_bridge=interface network.repeater_bridge=interface
 network.repeater_bridge.proto='relay' network.repeater_bridge.proto='relay'
Line 218: Line 326:
 </code> </code>
  
-Please note that the wifi network generated by the device in this example (the one called OpenWrt) has no password nor encryption.\\+Please note that the Wi-Fi network generated by the device in this example (the one called OpenWrt) has no password nor encryption.\\
 This was done because the focus of this article was getting the relay bridge up and running.\\ This was done because the focus of this article was getting the relay bridge up and running.\\
-You will likely want to set up your device'wifi network in a more secure way, as explained in the WiFi setup page [[docs:guide-user:network:wifi:basic|here]].+You will likely want to set up your device'Wi-Fi network in a more secure way, as explained in the Wi-Fi setup page [[docs:guide-user:network:wifi:basic|here]].
  
-===== Accessing the OpenWrt device =====+===== Troubleshooting ===== 
 +==== Accessing the Extender ==== 
 +If you find the Wi-Fi extender itself is only accessible from those computers directly connected to the W-LAN AP, not from the ones connected to the OpenWrt W-LAN client, when in the 192.168.1.0 subnet, Make sure the ''Local IPv4 address'' setting in the ''Relay bridge'' interface matches the ip address of the wireless uplink. 
 +(The alternative is tedious: It is possible to access the OpenWrt box via its ''192.168.2.1'' address if you manually configure your computer to that subnet.)
  
-With this setup your OpenWrt device itself may only be accessible from those computers directly connected to the W-LAN AP, not from the ones connected to the OpenWrt W-LAN client only, when in the 192.168.1.0 subnet. It is however still possible to access the OpenWrt box via its ''192.168.2.1'' address, when you are in that subnet. One way of being in both subnets at the same time with a Linux client is by adding a second, a virtual network interface to /etc/network/interfaces:+==== Check Firewall zones ====
  
-<code> +:!: The following part of the configuration should not be necessary (already default options or changed automatically), in case something isn't working check this too
-iface eth0 inet dhcp +
-  gateway 192.168.1.1+
  
-auto eth0:+\\ {{media:docs:howto:relay_firewallzone_checkLAN.jpg?800|}} \\ 
-iface eth0:1 inet static +\\   
-    address 192.168.2.102 +---- 
-    netmask 255.255.255.0 +\\ {{media:docs:howto:relay_firewallzone_checkLAN_2.jpg?400|}} \\
-    broadcast 192.168.2.255 +
-</code> +
- +
-//[If someone can describe a solution without modifications to the client network configuration that would be appreciated!]// +
- +
-===== Adding IPv6 support =====+
  
-Activate IPv6 support on your Internet box, this will get you a public IPv6 prefix. We will now activate IPv6 on our WiFi Extender to allow for [[https://en.wikipedia.org/wiki/IPv6_address#Stateless_address_autoconfiguration|Stateless Address Autoconfiguration (SLAAC)]] of your public IPv6 addresses and IPv6 traffic.+==== Adding IPv6 support ==== 
 +Activate IPv6 support on your Internet box, this will get you a public IPv6 prefix. We will now activate IPv6 on our Wi-Fi extender to allow for [[https://en.wikipedia.org/wiki/IPv6_address#Stateless_address_autoconfiguration|Stateless Address Autoconfiguration (SLAAC)]] of your public IPv6 addresses and IPv6 traffic.
  
 1. Go to Network / Interfaces and create a new interface. Name it ''WWAN6'', using protocol DHCPv6, cover the WWAN interface. In the Common Configuration of the new interface, configure: Request IPv6 address: disabled. In the Firewall settings: check that the "lan / repeater bridge…" line is selected. Leave the other settings by default, especially, leave the "Custom delegated IPv6-prefix" field empty. On the Interfaces / overwiew page check that the WWAN interface gets a public IPv6 address.\\ 1. Go to Network / Interfaces and create a new interface. Name it ''WWAN6'', using protocol DHCPv6, cover the WWAN interface. In the Common Configuration of the new interface, configure: Request IPv6 address: disabled. In the Firewall settings: check that the "lan / repeater bridge…" line is selected. Leave the other settings by default, especially, leave the "Custom delegated IPv6-prefix" field empty. On the Interfaces / overwiew page check that the WWAN interface gets a public IPv6 address.\\
Line 248: Line 352:
  
 3. Open a SSH session on your OpenWrt device. Issue the following commands:\\ 3. Open a SSH session on your OpenWrt device. Issue the following commands:\\
-<code>+<code bash>
 uci set dhcp.wan.interface=wwan uci set dhcp.wan.interface=wwan
 uci set dhcp.wan.ra=relay uci set dhcp.wan.ra=relay
Line 255: Line 359:
 uci commit uci commit
 </code> </code>
-We suppose that you created a ''wwan'' interface when you joined to the other wifi network as suggested earlier in this guide; otherwise, change the ''dhcp.wan.interface=…'' line accordingly.\\+We suppose that you created a ''wwan'' interface when you joined to the other Wi-Fi network as suggested earlier in this guide; otherwise, change the ''dhcp.wan.interface=…'' line accordingly.\\
  
-That's it. Restart ''ophcpd'' (LuCI System/Starup page, or ''/etc/init.d/odhcpd restart'') and your IPv6-network should begin to configure itself. Connected IPv6-enabled devices should get their public IPv6 addresses, derived from your public IPv6 prefix, and IPv6 traffic should go through your WiFi Extender+That's it. Restart ''ophcpd'' (LuCI System/Starup page, or ''service odhcpd restart'') and your IPv6-network should begin to configure itself. Connected IPv6-enabled devices should get their public IPv6 addresses, derived from your public IPv6 prefix, and IPv6 traffic should go through your Wi-Fi extender
  
-===== Wifi Extender with NAT (or what to do when all else fails) =====+==== Known Issues ====
  
-This method basically puts a second wifi router in cascade on the first.\\ +Here are a list of some recently reported issues: 
-It's like connecting with a cable the WAN port on the Wifi Extender to the LAN ports of the main router, the Wifi Extender creates a new network for itself and the devices connected to it, that can go on the Internet and reach devices in the LAN network of the main router. But in this case we are doing it with wireless networks instead.+ 
 +  - DHCP issue caused by Access Point. [[https://forum.openwrt.org/t/relayd-not-forwarding-broadcast-bootp-dhcp-responses/53607/15|OWrt forum]] 
 +  - Extremely poor upstream transfer speeds with some MT762x devices. [[https://forum.openwrt.org/t/question-xiaomi-mi-r3g-mir3g-5ghz-relayd-19-07-upload-performance/50248|Owrt forum]] [[https://bugs.openwrt.org/index.php?do=details&task_id=2816|Bug Report FS#2816]] 
 +  - [[https://forum.openwrt.org/t/relayd-double-nat-issue/134702/|Devices connected to relayd device cannot be reached.]]  [[https://forum.openwrt.org/t/wifi-bridge-only-outbound-connections-work/135973|2nd possibly similar case]] 
 +  - [[https://forum.openwrt.org/t/how-to-use-openwrt-as-a-wi-fi-repeater-using-a-different-ssid/136177|Cannot enable client and AP on same radio]] 
 +  - Additional instruction for backdoor to router since once dhcp is disabled on LAN, the router become unreachable.  This may occur if there are changes to the wireless access point.  eg. wifi SSID, channel number or security passphrase has changed.\\  
 +     - Connect a computer using ethernet cable to LAN port of the Wifi bridge.  
 +     - Configure a static IP address on the computer. eg. if the Wifi bridge uses LAN IP address of 192.168.2.1 in above example, use static IP address: 192.168.2.10. 
 +     - Access LuCI at 192.168.2.1 for above example. 
 +  - [[https://www.nerd-quickies.net/2019/08/20/setup-lan-wlan-bridge-with-openwrt-luci/|Alternative relayd setup guide ]] 
 +  - Alternative detailed Relayd setup instructions can also be found in section 9.10 of the [[https://www.dropbox.com/sh/c8cqmpc6cacs5n8/AAA2f8htk1uMitBckDW8Jq88a?dl=0|1-OpenWrt-LEDE Installation Guide for HH5A]] 
 +  - IPv6 on macOS 10.15+ does not work with a ULA prefix set on LAN [[https://github.com/openwrt/openwrt/issues/7561]] 
 + 
 +==== Using NAT ==== 
 + 
 +**<color #ed1c24>Comment:</color>**  This looks like the basic instructions for configuring a simple [[:docs:guide-user:network:wifi:connect_client_wifi|wireless client]] 
 +\\  
 +\\  
 + 
 +This method basically puts a second Wi-Fi router in cascade on the first one; i.e. usually this means that the extender's clients will be behind double NAT. 
 + 
 +It's like connecting with a cable the WAN port on the Wi-Fi extender to the LAN ports of the main router, the Wi-Fi extender creates a new network for itself and the devices connected to it, that can go on the Internet and reach devices in the LAN network of the main router. But in this case we are doing it with wireless networks instead.
  
 prerequisites: prerequisites:
-- router with two initial interfaces (lanwan)+- router with two initial interfaces (LANWAN)
  
-Setup with luci-GUI:+Setup with WebUI:
   * Go in the Network -> Interfaces page, click on edit lan interface,   * Go in the Network -> Interfaces page, click on edit lan interface,
-  * Set LAN as static IPv4 address as 192.168.x.1 (with x different from the network to which you will connect via wifi), +  * Set LAN as static IPv4 address as 192.168.x.1 (with x different from the network to which you will connect via Wi-Fi), 
-  * Go in the Network -> Wifi, click on scan and choose the "network" link and click "Join Network"+  * Go in the Network -> Wi-Fi, click on scan and choose the "network" link and click "Join Network"
-  * Enter the wifi password, leave the "name of new network" as "wwan" and select wwan (or wan) firewall zone. Click Save,+  * Enter the Wi-Fi password, leave the "name of new network" as "WWAN" and select WWAN (or WAN) firewall zone. Click Save,
   * Go in the Network -> Interfaces page, click on edit wwan interface,   * Go in the Network -> Interfaces page, click on edit wwan interface,
   * Move to the Firewall tab. Click on Save and Apply.   * Move to the Firewall tab. Click on Save and Apply.
-  * Go in the Network -> Firewall, click edit in wan zone and check wan and wwan in "covered networks", click save and apply,+  * Go in the Network -> Firewall, click edit in wan zone and check WAN and WWAN in "covered networks", click save and apply, 
 + 
 +Now you've correctly bounded WWAN with WAN, and consequently WWAN with LAN.
  
-now you've correctly bounded wwan with wan, and consequently wwan with lan 
  • Last modified: 2024/08/31 18:25
  • by richardkiss