Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 3552

Networking and servers • Re: Sharing the Ethernet port to USB0

$
0
0
It turns out that manually creating a bridge is not needed on the system acting as the router. It is enough to use nmcli in place of step 2 above:

Code:

sudo nmcli connection add type ethernet ifname usb0 ip4 172.16.3.1/24 ipv4.method shared con-name usb0-staticsudo nmcli connection up usb0-static
However, I still haven't found out what to do about the Zero2W acting as the USB gadget. This work around is needed for now:

Code:

sudo sed -i .old -e '/^\[all\]/ adtoverlay=dwc2' /boot/config.txtsudo nmcli connection add type ethernet ifname usb0 con-name usb0 connection.autoconnect yescat "@reboot root sleep 30; nmcli connection up usb0" \        | sudo tee /etc/cron.d/usb_networking
I'm not sure how long the leading pause needs to be, but 30 seconds is fine.

The original puzzle still stands.

Statistics: Posted by tpyo kingg — Mon Jan 29, 2024 8:10 am



Viewing all articles
Browse latest Browse all 3552

Trending Articles