Posts

Showing posts from December, 2019

Raspberry pi OTG cluster networking raspberry pi3 and raspberry pi zero

Let's assume you have two raspi zero and one raspi3, we want to connect pi zeros to reach internal networking with raspi3 as host and internet over raspi3. Add this to  /boot/cmdline.txt  after  rootwait pizero1 modules-load=dwc2,g_ether g_ether.host_addr=00:22:82:ff:ff: 01 g_ether.dev_addr=00:22:82:ff:ff: 11 quiet pizero2 modules-load=dwc2,g_ether g_ether.host_addr=00:22:82:ff:ff: 02 g_ether.dev_addr=00:22:82:ff:ff: 12 quiet Add this to  /boot/config.txt pizero1 and pizero2 dtoverlay=dwc2 gpu_mem=16 Add this to /etc/dhcpcd.conf  pizero1 interface usb0 static ip_address=192.168.7.2/24 static routers=192.168.7.1 static domain_name_servers=8.8.8.8 pizero2 interface usb0 static ip_address=192.168.7.2/24 static routers=192.168.7.1 static domain_name_servers=8.8.8.8 edit /etc/sysctl.conf make ip forward 1 and check if it's ok sudo sysctl -p /etc/sysctl.conf net.ipv4.ip_forward = 1 make sure ip forward is 1 an