boardOS: Debian 9 IoT
I am able to ‘screen’ into the PB (pocketbeagle). I am loosely trying to follow this video; however, this video is 4+ years old and not my environment. For example, Debian does not have the ‘udhcpc’ command.
After a few minutes, the macOS network preferences shows a warning regarding the IP self assignment of the PB:
This is not consistent with the documentation. Also, the warning explicitly says that due to this, the PB will not be able to connect to the internet.
Also note that I have added a default route per instructions and still not ability to ping Google DNS.
if you look at the console image, you will see the results of the ‘ifconfig’ showing both a usb0: 192.168.7.1 and a usb1: 192.168.6.1. You will also note the added route for the default gateway.
As I said above, there may be an issue with macOS and the network preferences and the IP disconnect shown there.
My apologies, the image was hosted elsewhere and so Thunderbird didn't
show the image. Thus I didn't see it first up.
What happens if you manually set the IP address of the network interface
Mac-side? You'll probably also need to enable IP forwarding and IP
masquerade too: I do not know how this is done on MacOS X or if it's
even possible.
I have been seeing the same thing with MacOS 10.13.2. I am able to ssh into the pocket beagle over the USB, but when I try to turn on Internet Sharing to be able to forward to the internet then the ssh connection hangs and I can no longer work on the ssh connection I had established. I vaguely remember something about Connection sharing on Mac but I can seem to find it.
@Yoda: System Preferences >> Sharing >> Internet Sharing and share with the Beaglebone.local is what I am doing. This has worked for me in past releases; however, not working for me in this configuration.
I’m not an expert in anything Apple, however I strongly suspect that enabling Internet Sharing means your Mac will do the following:
create a private subnetwork on the selected interface with a semi-random address space (e.g. 192.168.XXX.0/24)
start a DHCP service to serve addresses from selected address space to client hosts
set the Mac up as a router doing NAT for the client hosts
Unfortunately the BeagleBone’s USB network emulation has already done steps 1 and 2 on its side with pre-determined address spaces 192.168.6.0/24 and 192.168.7.0/24. This creates an address conflict between the BB and Mac which makes connectivity impossible.
I’d suggest connecting your BB and Mac via Ethernet (buy a cheap USB-Ethernet adapter if needed) and enabling Internet Sharing on that interface. In this case the sharing feature should work as intended. Plus you’ll always have the same USB network emulation to ssh into the BB in a tight spot.
What you say sounds good. If that is the case, there should be a way to tell the BB to accept the DHCP config. On Ångstrom, that would be with udhcpc. I am trying to figure out how to do that with Debian. I am currently exploring ‘connman’ but I just have not found the time. If that works, I will definitely post the solution here.
Assuming you’re using Robert’s Debian images - the actual Ethernet interface requires zero effort to accept the DHCP config. It’s configured as a DHCP client out of box. Just connect it to anything - a router, your Mac with Internet Sharing enabled, … - and it’ll be online immediately.
Only the network emulation on USB requires hacking boot scripts (/opt/scripts/boot/autoconfigure_usb(0|1).sh, around the last 20 lines) to disable hardcoded network configuration and switch from DHCP server to client. Frankly, I wouldn’t bother.