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:wifiextenders:bridgedap [2024/06/24 11:07] – [Wi-Fi Extender/Repeater with Bridged AP over Ethernet] bluewavenetdocs:guide-user:network:wifi:wifiextenders:bridgedap [2024/09/30 13:33] – [Populate Hostnames in Associated Stations] Improve command dpawlik
Line 1: Line 1:
-<WRAP RIGHT+<WRAP> 
-{{:doc:recipes:bridged.ap_v3.png|}}+{{:doc:recipes:bridged.ap_v3.png|?400}}
 </WRAP> </WRAP>
  
 ====== Wi-Fi Extender/Repeater with Bridged AP over Ethernet ====== ====== Wi-Fi Extender/Repeater with Bridged AP over Ethernet ======
  
-Bridged AP is to extend your existing wired host router to have wireless capabilities. Clients connecting to OpenWRT will get an IP address from the wired host router. +Bridged AP configuration will use your wireless capable device to add WiFi to your network that has an existing wired host router.
  
-OpenWrt bridges the LAN network with the WLAN of the device in Access Point mode. The advantage of bridging is that broadcast traffic from Wireless to LAN and vice versa works without further changes.  +OpenWrt bridges the LAN network with the WLAN of the device in Access Point mode. The advantage of bridging is that broadcast traffic from wireless to LAN and vice versa works without further changes. Clients connecting to the AP will get an IP address from the wired host router.
- +
-This document outlines the steps necessary to implement such a setup.   +
- +
-//Note: This recipe results in a bridged LAN that will work fine for home and small networks.+
  
 ===== Configuration ===== ===== Configuration =====
Line 33: Line 29:
         option dns 192.168.1.1         option dns 192.168.1.1
 </code> </code>
-This IP address must be an //unused// one within the network subnet of the main router. You could also change ''proto'' to ''dhcp'' and let the main router decide the access point'address, but of course from then on the access point needs a DHCP server and you will lose the ability to directly plug into your access point for maintenance.+This must be an //unused// IP within the network subnet of the main router. You could also change ''proto'' to ''dhcp'' and let the main router decide the AP address, but of course from then on the access point needs a DHCP server and you will lose the ability to directly plug into your access point for maintenance.
  
 ==== Step 2: Configure and enable the wireless network ==== ==== Step 2: Configure and enable the wireless network ====
Line 54: Line 50:
   service dnsmasq disable   service dnsmasq disable
   service dnsmasq stop   service dnsmasq stop
- 
  
 ==== Step 4: Connect host router and openwrt router correctly ==== ==== Step 4: Connect host router and openwrt router correctly ====
  
-Ensure the host router is connected with a lan port of the openwrt, not the wan port!+Ensure the host router is connected with a LAN port of the wireless AP, not the WAN port!
  
-===== Apply changes =====+==== Apply changes ====
  
 Enable the new wireless network with the following command: Enable the new wireless network with the following command:
Line 66: Line 61:
   wifi   wifi
  
 +====== Wireless Access Point - Dumb Access Point - Examples ======
  
 +This section describes in detail how to configure your device as a //wireless access point (AP)// connected to an existing network with a main router. This is often called a //dumb AP// since it will not perform duties such as routing, firewall, DHCP, or DNS, as these would be performed by the router or other device.
  
-\\ +This is commonly used to add additional wireless coverage to an existing network, maybe on a different floor or to cover a dead zone. This setup is sufficient for small home or office network, but for larger networks a more sophisticated approach is often used.
-====== Wireless Access Point - Dumb Access Point - Detailed Examples ====== +
- +
-This following describes in great detail how to configure your device as a //wireless access point (AP)// connected to an existing network with a main router. This is often called a //dumb AP// since it will not perform administrative duties such as routing, firewall, DHCP, or DNS, as these would be performed by the router or other device. +
- +
-This is commonly used to add additional wireless coverage to an existing network, maybe on a different floor or to cover a dead spot. This setup is sufficient for small home or office network, but for larger networks a more sophisticated approach is often used.+
  
 <WRAP box> <WRAP box>
-Summary of configuration for a Wireless AP: +Overview of configuration for a Wireless AP: 
-  - The wireless AP is connected LAN-to-LAN to the main router by some means e.g. ethernet cable, 802.11s mesh, etc.  +  - The wireless AP is connected LAN-to-LAN to the router by some means e.g. ethernet, 802.11s mesh, etc.  
-  - The wireless AP bridges its SSID wireless interface onto its LAN bridge interface. Wireless traffic on the wireless AP goes to its bridge LAN interface, then to the main router.+  - The wireless AP bridges its SSID wireless interface to its LAN bridge interface. WiFi traffic goes to its bridge LAN interface, then to the main router.
   - The wireless AP bridge LAN may have either a static or DHCP address on the same subnet as the main router bridge LAN interface.   - The wireless AP bridge LAN may have either a static or DHCP address on the same subnet as the main router bridge LAN interface.
   - The wireless AP gateway IP address is set to the address of the main router, either in the configuration or by DHCP.   - The wireless AP gateway IP address is set to the address of the main router, either in the configuration or by DHCP.
-  - The wireless AP does not provide services such as DHCP, DNS, or firewall.+  - The wireless AP does not provide services such as DHCP, DNS, or firewall as this is done on the main router or other device.
 </WRAP> </WRAP>
  
Line 88: Line 80:
 ===== Configuration via LuCI ===== ===== Configuration via LuCI =====
  
-These instructions refer to the interface found in OpenWrt 23.05. The interface of v21 upwards differs in significant ways from earlier versions of OpenWrt which we try to account for.+These instructions refer to the interface found in OpenWrt 23.05. The interface differs from earlier versions of OpenWrt which we try to account for.
  
 This setup requires two routers, a computer with an Ethernet port, and an Ethernet cable. We refer to the routers as the //main router// and the //wireless AP// and we assume default settings on both. The main router should already be properly configured and connected to the Internet. This setup requires two routers, a computer with an Ethernet port, and an Ethernet cable. We refer to the routers as the //main router// and the //wireless AP// and we assume default settings on both. The main router should already be properly configured and connected to the Internet.
Line 139: Line 131:
      
 Disable IPv6 DHCP. Same page, //DHCP Server// tab, click on the //IPv6 Settings// sub-tab. Set the //RA-Service//, //DHCPv6-Service//, and //NDP-Proxy// dropdowns to //disabled//.\\ Disable IPv6 DHCP. Same page, //DHCP Server// tab, click on the //IPv6 Settings// sub-tab. Set the //RA-Service//, //DHCPv6-Service//, and //NDP-Proxy// dropdowns to //disabled//.\\
-**In versions of OpenWrt older than 21.02:**  Under "Physical Settings" tab, ensure "Bridge interfaces" is ticked, and ensure BOTH of your interfaces (eth0, wlan0) are selected, in order to allow traffic between wireless and wired connections.\\+In versions of OpenWrt prior to 21.02:  Under "Physical Settings" tab, ensure "Bridge interfaces" is ticked, and ensure BOTH of your interfaces (eth0, wlan0) are selected, in order to allow traffic between wireless and wired connections.\\
 Click "Save". Click "Save".
  
Line 157: Line 149:
  
 Use an Ethernet cable to connect one of the LAN ports on your main router to one of the LAN ports (**not** the //WAN/////Internet// port) of the wireless AP. Use an Ethernet cable to connect one of the LAN ports on your main router to one of the LAN ports (**not** the //WAN/////Internet// port) of the wireless AP.
-You may need to reboot either or both routers, the device connecting your main router to the Internet, and potentially any connected devices. In many cases this will not be necessary.+You may need to reboot either or both routers, the device connecting your main router to the Internet, and potentially any connected devices. In many cases this will not be necessary.\\
 Done!\\ Done!\\
  
Line 295: Line 287:
 <code>rm /usr/sbin/wpa_supplicant</code> <code>rm /usr/sbin/wpa_supplicant</code>
  
-===== Apply changes =====+==== Apply changes ====
  
 Reloading the network config should be enough, it should automatically restart if necessary. Alternatively, reboot. Reloading the network config should be enough, it should automatically restart if necessary. Alternatively, reboot.
Line 330: Line 322:
 Dumb APs will not have the data to display hostnames of the associated devices.  Only MAC addresses are known to it.  Users wanting to see the corresponding hostnames in the Associated Stations display in LuCI can manually populate ''/etc/ethers'' on the dumb AP: Dumb APs will not have the data to display hostnames of the associated devices.  Only MAC addresses are known to it.  Users wanting to see the corresponding hostnames in the Associated Stations display in LuCI can manually populate ''/etc/ethers'' on the dumb AP:
  
-On the router, one can extract this data with the following one-liner:+On the router, one can extract these data with the following one-liner:
 <code> <code>
 < dhcp.leases | awk '{print $2" "$4}' < dhcp.leases | awk '{print $2" "$4}'
 +# or
 +awk '$4 != "*"{print $2" "$4}' /tmp/dhcp.leases
 </code> </code>
  
Line 344: Line 338:
 DLNA and UPnP clients, and printer or SMB discovery protocols tend to work by using multicast packets. For example PlayStation, Xbox, and TVs use DLNA to detect, communicate with and stream audio/video over the network. By default on bridged interfaces on OpenWrt multicast snooping is turned off. This means all network interfaces connected to a bridge (such as a WiFi SSID and ethernet VLAN) will receive multicast packets as if they were broadcast packets. DLNA and UPnP clients, and printer or SMB discovery protocols tend to work by using multicast packets. For example PlayStation, Xbox, and TVs use DLNA to detect, communicate with and stream audio/video over the network. By default on bridged interfaces on OpenWrt multicast snooping is turned off. This means all network interfaces connected to a bridge (such as a WiFi SSID and ethernet VLAN) will receive multicast packets as if they were broadcast packets.
  
-On WiFi the //slowest// modulation available is used for multicast packets (so that everyone can hear them). If you have "enabled legacy 802.11b rates" on your WiFi (Advanced settings checkbox in LuCI under the WiFi settings, or  ''option legacy_rates '1''' in /etc/config/wireless file) then 1Mbps is the rate that will be used. This can completely use up the WiFi airtime with even fairly light multicast streaming. +On WiFi the //slowest// modulation available is used for multicast packets (so that everyone can hear them). If you have "enabled legacy 802.11b rates" on your WiFi (Advanced settings checkbox in LuCI under the WiFi settings, or ''option legacy_rates '1''' in /etc/config/wireless file) then 1Mbps is the rate that will be used. This can completely use up the WiFi airtime with even fairly light multicast streaming. 
  
 There are two possible fixes for this, one is to //enable// multicast snooping: ''option igmp_snooping '1''' under the appropriate /etc/config/network settings for the bridge. This will cause the bridge to forward only on bridge ports that have requested to receive the particular multicast group. On the other hand, if someone on WiFi requests the group, it will still flood the multicast there, and some people have reported problems with certain devices such as android phones and with ipv6 when igmp_snooping is enabled (requires further debugging to identify if there is really a problem or not). By //disabling// legacy 802.11b rates (''option legacy_rates '0''') you can at least force the use of 6Mbps or more on the WiFi multicast packets, and this opens up more airtime for other uses.  There are two possible fixes for this, one is to //enable// multicast snooping: ''option igmp_snooping '1''' under the appropriate /etc/config/network settings for the bridge. This will cause the bridge to forward only on bridge ports that have requested to receive the particular multicast group. On the other hand, if someone on WiFi requests the group, it will still flood the multicast there, and some people have reported problems with certain devices such as android phones and with ipv6 when igmp_snooping is enabled (requires further debugging to identify if there is really a problem or not). By //disabling// legacy 802.11b rates (''option legacy_rates '0''') you can at least force the use of 6Mbps or more on the WiFi multicast packets, and this opens up more airtime for other uses. 
  
-===== External Videos for Reference =====+===== External Videos =====
  
 Several videos are available on the topic which may be useful for background information.\\ Several videos are available on the topic which may be useful for background information.\\
Line 368: Line 362:
 ===== Notes ===== ===== Notes =====
  
-  - Dumb AP wireless can be configured to control access as Open/WPA/WPA2/etc. MAC-based access control is controlled by the main router. +  - Dumb AP wireless can be configured to control access via Open/WPA/WPA2/WPA3However MAC-based access control is controlled by the main router. 
-  - 'Static DHCPis not covered here: this procedure creates an AP that provides wired/wireless access and won't interfere with Static DHCP+  - Static DHCP is not covered here. This procedure creates an AP that provides wired/wireless access and won't interfere with Static DHCP.
-  - This recipe is similar to the "Bridged AP" recipe at [[docs:guide-user:network:wifi:BridgedAP|Bridged AP]]. These pages should probably be merged.+
   - Firewall bridge mode support in OpenWrt is provided by the [[packages:pkgdata:kmod-br-netfilter|kmod-br-netfilter]] module.   - Firewall bridge mode support in OpenWrt is provided by the [[packages:pkgdata:kmod-br-netfilter|kmod-br-netfilter]] module.
  
  • Last modified: 2024/11/04 17:49
  • by palebloodsky