Some success with Raspberry Pi 3 onboard wifi bridge.

355 views
Skip to first unread message

William Hill

unread,
Feb 6, 2017, 7:38:34 AM2/6/17
to ClusterHAT
The wifi in built in to the Raspberry Pi can't be bridged - see here for why: https://wiki.openwrt.org/doc/howto/clientmode#bridged_client_mode_issues

However, there's "pseudo-bridging", and I found this guide: https://wiki.debian.org/BridgeNetworkConnectionsProxyArp

So, I've set up my Pi3 with static IP 192.168.1.140 - Here's my interfaces file:

source-directory /etc/network/interfaces.d
auto lo wlan0
iface lo inet loopback
allow-hotplug eth0
iface eth0 inet dhcp
iface wlan0 inet static
  address 192.168.1.140
  gateway 192.168.1.1
  netmask 255.255.255.0
  wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

And static IPs for the Zeros - Here's the interfaces from "p1":

source-directory /etc/network/interfaces.d
auto lo usb0
iface lo inet loopback
iface usb0 inet static
  address 192.168.1.141
  gateway 192.168.1.1
  netmask 255.255.255.0

Then what I did on the controller to get everything working:

root@controller:~# echo 1 > /proc/sys/net/ipv4/conf/all/proxy_arp
root@controller:~# echo 1 > /proc/sys/net/ipv4/ip_forward
root@controller:~# controllerhat on p1 p2
Turning on P1
Turning on P2
...wait...wait...wait...
root@controller:~# ifconfig ethpi1 up
root@controller:~# ifconfig ethpi2 up
root@controller:~# ip ro add 192.168.1.141/32 dev ethpi1
root@controller:~# ip ro add 192.168.1.142/32 dev ethpi2

(I've only got the 2 PiZero, so far...)

This will need automating, but I can ssh the Zeros over wifi now.

Alexis Iglauer

unread,
Mar 19, 2017, 11:03:34 AM3/19/17
to ClusterHAT
I've not done this with the clusterHAT, but have set up a wireless bridge before using this set of instructions: https://wiki.debian.org/BridgeNetworkConnectionsProxyArp  Key is to use parprouted (and avahi, but that's installed already).  No need to fix the IPs of the zeros (for this purpose).

Best regards
Alexis

William Hill

unread,
Mar 2, 2018, 12:49:46 PM3/2/18
to ClusterHAT
I've updated for the Debian9/Stretch based OS now.

Here's the snippet of my /etc/rc.local
  echo 1 > /proc/sys/net/ipv4/ip_forward
  clusterhat on
  sleep 15
  ifconfig ethpi1 up || true
  ip ro add 192.168.1.141/32 dev ethpi1 || true
  ifconfig ethpi2 up || true
  ip ro add 192.168.1.142/32 dev ethpi2 || true
  ifconfig ethpi3 up || true
  ip ro add 192.168.1.143/32 dev ethpi3 || true
  ifconfig ethpi4 up || true
  ip ro add 192.168.1.144/32 dev ethpi4 || true
  parprouted -d ethpi1 ethpi2 ethpi3 ethpi4 wlan0

I haven't added anything to /etc/network/interfaces and wpa_supplicant.conf is setup for my default SSID.
Reply all
Reply to author
Forward
0 new messages