1

I followed this tutorial to set my RPi 4B up. In my basement, I have my RPi connected via cable and want to bridge a new WiFi AP (as in the last part of that post above).

The first time, everything worked fine, I was able to connect to my RPi Wifi network with my phone (or other devices) and had an address assigned by the DHCP server on my router/modem.

After a few restarts and/or after docker installation, I can't connect anymore. Android phones are stuck at "Obtaining IP address" and another computer connects, but doesn't get an IP anymore (logs are indicating that DHCP has not returned an address).

I am able to ping/curl public websites on the RPi (though it seems I have to go through the bridge via ping -I br0 -c3 google.com (-I eth0 doesn't work)).

How can I debug this?

I tried multiple restarts, restarting the services, all to no avail.

Edit: I set up my RPi to have a DNS server (pihole via docker). In order for other docker containers to use that one I changed the system's dns entries, so that I have:

➜  ~ cat /etc/resolv.conf
nameserver 192.168.0.30
nameserver 192.168.0.1
search hitronhub.home

I'm not sure, but those DNS entries should not affect DHCP on the bridge, right? I think it's more related to installing docker (or something else).

Here are a few information:

➜  ~ sudo cat /etc/wpa_supplicant/wpa_supplicant-wlan0.conf         
country=ca                                                          
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev             
update_config=1                                                     
app_scan=1                                                          
                                                                    
network={                                                           
    ssid="Basement"                                                 
    mode=2                                                          
    frequency=5220                                                  
    #key_mgmt=NONE   # uncomment this for an open hotspot           
    # delete next 3 lines if key_mgmt=NONE                          
    key_mgmt=WPA-PSK                                                
    proto=RSN WPA                                                   
    psk="***pw***"                                                  
}                                                                   
➜  ~ ifconfig                                                                                                                
br0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                                    
        inet 192.168.0.30  netmask 255.255.255.0  broadcast 192.168.0.255                                                    
        inet6 fe80::d0d9:e2ff:fe3d:699a  prefixlen 64  scopeid 0x20<link>                                                    
        inet6 fd00:a84e:3f6c:9322:d0d9:e2ff:fe3d:699a  prefixlen 64  scopeid 0x0<global>                                     
        ether d2:d9:e2:3d:69:9a  txqueuelen 1000  (Ethernet)                                                                 
        RX packets 79139  bytes 5225897 (5.2 MB)                                                                             
        RX errors 0  dropped 23748  overruns 0  frame 0                                                                      
        TX packets 11782  bytes 1277671 (1.2 MB)                                                                             
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
br-bb564efd3146: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                        
        inet 172.20.0.1  netmask 255.255.0.0  broadcast 172.20.255.255                                                       
        inet6 fe80::42:2eff:fed1:d618  prefixlen 64  scopeid 0x20<link>                                                      
        ether 02:42:2e:d1:d6:18  txqueuelen 0  (Ethernet)                                                                    
        RX packets 4470  bytes 412507 (412.5 KB)                                                                             
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 4454  bytes 462973 (462.9 KB)                                                                             
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
docker0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500                                                                        
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 172.17.255.255                                                       
        ether 02:42:9a:8c:47:de  txqueuelen 0  (Ethernet)                                                                    
        RX packets 0  bytes 0 (0.0 B)                                                                                        
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 0  bytes 0 (0.0 B)                                                                                        
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                                   
        ether dc:a6:32:9b:6e:cf  txqueuelen 1000  (Ethernet)                                                                 
        RX packets 112304  bytes 21691931 (21.6 MB)                                                                          
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 11842  bytes 1281443 (1.2 MB)                                                                             
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536                                                                                 
        inet 127.0.0.1  netmask 255.0.0.0                                                                                    
        inet6 ::1  prefixlen 128  scopeid 0x10<host>                                                                         
        loop  txqueuelen 1000  (Local Loopback)                                                                              
        RX packets 91  bytes 6848 (6.8 KB)                                                                                   
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 91  bytes 6848 (6.8 KB)                                                                                   
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
veth1032cc9: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                            
        inet6 fe80::2821:79ff:fe14:af4a  prefixlen 64  scopeid 0x20<link>                                                    
        ether 2a:21:79:14:af:4a  txqueuelen 0  (Ethernet)                                                                    
        RX packets 907  bytes 272091 (272.0 KB)                                                                              
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 924  bytes 128079 (128.0 KB)                                                                              
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
veth19ee85a: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                            
        inet6 fe80::7c0e:acff:fe85:96ac  prefixlen 64  scopeid 0x20<link>                                                    
        ether 7e:0e:ac:85:96:ac  txqueuelen 0  (Ethernet)                                                                    
        RX packets 0  bytes 0 (0.0 B)                                                                                        
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 39  bytes 2914 (2.9 KB)                                                                                   
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
veth89ca666: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                            
        inet6 fe80::5cac:a7ff:fe80:bcb1  prefixlen 64  scopeid 0x20<link>                                                    
        ether 5e:ac:a7:80:bc:b1  txqueuelen 0  (Ethernet)                                                                    
        RX packets 905  bytes 126613 (126.6 KB)                                                                              
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 928  bytes 273641 (273.6 KB)                                                                              
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
vethb7b11d8: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                            
        inet6 fe80::6013:bcff:fe15:378a  prefixlen 64  scopeid 0x20<link>                                                    
        ether 62:13:bc:15:37:8a  txqueuelen 0  (Ethernet)                                                                    
        RX packets 0  bytes 0 (0.0 B)                                                                                        
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 42  bytes 3108 (3.1 KB)                                                                                   
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
vethf67b8c4: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                            
        inet6 fe80::48ed:15ff:fe94:4f78  prefixlen 64  scopeid 0x20<link>                                                    
        ether 4a:ed:15:94:4f:78  txqueuelen 0  (Ethernet)                                                                    
        RX packets 4469  bytes 475045 (475.0 KB)                                                                             
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 4483  bytes 464811 (464.8 KB)                                                                             
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500                                                                  
        inet6 fe80::dea6:32ff:fe9b:6ed0  prefixlen 64  scopeid 0x20<link>                                                    
        ether dc:a6:32:9b:6e:d0  txqueuelen 1000  (Ethernet)                                                                 
        RX packets 439  bytes 93244 (93.2 KB)                                                                                
        RX errors 0  dropped 0  overruns 0  frame 0                                                                          
        TX packets 15318  bytes 1517332 (1.5 MB)                                                                             
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0                                                           
                                                                                                                             
➜  ~ sudo networkctl status
●          State: routable
         Address: 192.168.0.30 on br0
                  172.17.0.1 on docker0
                  172.20.0.1 on br-bb564efd3146
                  fd00:a84e:3f6c:9322:d0d9:e2ff:fe3d:699a on br0
                  fe80::dea6:32ff:fe9b:6ed0 on wlan0
                  fe80::d0d9:e2ff:fe3d:699a on br0
                  fe80::42:2eff:fed1:d618 on br-bb564efd3146
                  fe80::5cac:a7ff:fe80:bcb1 on veth89ca666
                  fe80::2821:79ff:fe14:af4a on veth1032cc9
                  fe80::48ed:15ff:fe94:4f78 on vethf67b8c4
                  fe80::6013:bcff:fe15:378a on vethb7b11d8
                  fe80::7c0e:acff:fe85:96ac on veth19ee85a
         Gateway: 192.168.0.1 (Hitron Technologies. Inc) on br0
             DNS: 192.168.0.1
  Search Domains: hitronhub.home

Jun 09 05:34:41 rpi systemd-networkd[20792]: veth89ca666: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[20792]: br-bb564efd3146: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[20792]: br0: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[20792]: wlan0: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[20792]: Enumeration completed
Jun 09 05:34:41 rpi systemd[1]: Started Network Service.
Jun 09 05:34:41 rpi systemd-networkd[20792]: br0: netdev exists, using existing without changing its parameters
Jun 09 05:34:41 rpi systemd[1]: Starting Wait for Network to be Configured...
Jun 09 05:34:41 rpi systemd[1]: Finished Wait for Network to be Configured.
Jun 09 05:34:42 rpi systemd-networkd[20792]: br0: DHCPv4 address 192.168.0.30/24 via 192.168.0.1
➜  ~ route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.0.1     0.0.0.0         UG    1024   0        0 br0
172.17.0.0      0.0.0.0         255.255.0.0     U     0      0        0 docker0
172.20.0.0      0.0.0.0         255.255.0.0     U     0      0        0 br-bb564efd3146
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 br0
192.168.0.1     0.0.0.0         255.255.255.255 UH    1024   0        0 br0
➜  ~ sudo networkctl status br0
● 4: br0
                     Link File: /usr/lib/systemd/network/99-default.link
                  Network File: /etc/systemd/network/12-br0_up.network
                          Type: bridge
                         State: routable (configured)
                        Driver: bridge
                    HW Address: d2:d9:e2:3d:69:9a
                           MTU: 1500 (min: 68, max: 65535)
                         QDisc: noqueue
  IPv6 Address Generation Mode: eui64
                 Forward Delay: 15s
                    Hello Time: 2s
                       Max Age: 20s
                   Ageing Time: 5min
 [0m                     Priority: 32768
                           STP: no
        Multicast IGMP Version: 2
                          Cost: 2000
                    Port State: disabled
          Queue Length (Tx/Rx): 1/1
              Auto negotiation: no
                         Speed: 1Gbps
                       Address: 192.168.0.30 (DHCP4 via 192.168.0.1)
                                fd00:a84e:3f6c:9322:d0d9:e2ff:fe3d:699a
                                fe80::d0d9:e2ff:fe3d:699a
                       Gateway: 192.168.0.1 (Hitron Technologies. Inc)
                           DNS: 192.168.0.1
                Search Domains: hitronhub.home
               DHCP4 Client ID: IAID:0x767f1b5a/DUID
             DHCP6 Client IAID: 0x767f1b5a
             DHCP6 Client DUID: DUID-EN/Vendor:0000ab11b181b51f9e96a95a0000

Jun 09 02:19:25 rpi systemd-networkd[1649]: br0: netdev ready
Jun 09 02:19:25 rpi systemd-networkd[1649]: br0: Link UP
Jun 09 02:19:29 rpi systemd-networkd[1649]: br0: Gained carrier
Jun 09 02:19:29 rpi systemd-networkd[1649]: br0: DHCPv4 address 192.168.0.30/24 via 192.168.0.1
Jun 09 02:19:31 rpi systemd-networkd[1649]: br0: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[1649]: br0: DHCPv6 lease lost
Jun 09 05:34:41 rpi systemd-networkd[20792]: br0: netdev ready
Jun 09 05:34:41 rpi systemd-networkd[20792]: br0: Gained IPv6LL
Jun 09 05:34:41 rpi systemd-networkd[20792]: br0: netdev exists, using existing without changing its parameters
Jun 09 05:34:42 rpi systemd-networkd[20792]: br0: DHCPv4 address 192.168.0.30/24 via 192.168.0.1

Let me know if you need more information, I'll amend this question.

Please don't suggest hostapd, unless the tutorial is totally out-of-date and should not be used anymore.

2
  • show the bridge – Jaromanda X Jun 9 at 7:09
  • done, I hope that this is what you need, if not, please also post the command :) – user2084865 Jun 9 at 21:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.