Internet Sharing not working with the BeagleBone Black

internet-sharingNetwork

Running Mavericks on a 15" MBP. I have a BeagleBone Black running Debian Wheezy. I have connected the two with an ethernet cable. I have a working wifi connection from the MBP. So I turn on Internet Sharing to "share my connection from WiFi to computers using ethernet".

When I run ifup eth0 on the BeagleBone Black, I see the following output:

Internet Systems Consortium DHCP Client 4.2.2
Copyright 2004-2011 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

[ 3916.877981] net eth0: initializing cpsw version 1.12 (0)
[ 3916.886430] net eth0: phy found : id is : 0x7c0f1
[ 3916.891796] libphy: PHY 4a101000.mdio:01 not found
[ 3916.896888] net eth0: phy 4a101000.mdio:01 not found on slave 1
[ 3916.906939] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
Listening on LPF/eth0/c8:a0:30:ac:1f:f4
Sending on   LPF/eth0/c8:a0:30:ac:1f:f4
Sending on   Socket/fallback
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
[ 3918.891594] libphy: 4a101000.mdio:00 - Link is Up - 100/Full
[ 3918.899032] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 20
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
No DHCPOFFERS received.
No working leases in persistent database - sleeping.

Watching the output from Console on my MBP though, I can see it doing something

1/7/14 12:05:00.590 PM bootpd[18547]: DHCP DISCOVER [bridge100]: 1,c8:a0:30:ac:1f:f4 <arm>
1/7/14 12:05:00.590 PM bootpd[18547]: OFFER sent arm 192.168.2.9 pktsize 300
1/7/14 12:05:00.590 PM bootpd[18547]: service time 0.000651 seconds
1/7/14 12:05:00.590 PM bootpd[18547]: service time 0.000005 seconds
1/7/14 12:05:03.873 PM configd[16]: inet_set_autoaddr(en0, 1) failed, Resource busy (16)
1/7/14 12:05:04.137 PM bootpd[18547]: DHCP DISCOVER [bridge100]: 1,c8:a0:30:ac:1f:f4 <arm>
1/7/14 12:05:04.137 PM bootpd[18547]: OFFER sent arm 192.168.2.9 pktsize 300
1/7/14 12:05:04.137 PM bootpd[18547]: service time 0.000519 seconds
1/7/14 12:05:04.137 PM bootpd[18547]: service time 0.000002 seconds
1/7/14 12:05:10.296 PM bootpd[18547]: DHCP DISCOVER [bridge100]: 1,c8:a0:30:ac:1f:f4 <arm>
1/7/14 12:05:10.297 PM bootpd[18547]: OFFER sent arm 192.168.2.9 pktsize 300
1/7/14 12:05:10.297 PM bootpd[18547]: service time 0.001206 seconds
1/7/14 12:05:10.298 PM bootpd[18547]: service time 0.000007 seconds
1/7/14 12:05:24.813 PM bootpd[18547]: DHCP DISCOVER [bridge100]: 1,c8:a0:30:ac:1f:f4 <arm>
1/7/14 12:05:24.814 PM bootpd[18547]: OFFER sent arm 192.168.2.9 pktsize 300
1/7/14 12:05:24.814 PM bootpd[18547]: service time 0.000829 seconds
1/7/14 12:05:24.814 PM bootpd[18547]: service time 0.000004 seconds
1/7/14 12:05:32.405 PM bootpd[18547]: DHCP DISCOVER [bridge100]: 1,c8:a0:30:ac:1f:f4 <arm>
...

I don't know where to go from here. I do know that if I plug the BBB directly into my Netgear router, then it successfully fetches an IP address via DHCP. So I don't know if the problem is entirely on the Apple Internet Sharing side, but it's at least part of the problem, because the BBB, Just Works(tm) otherwise.

Best Answer

I'm on Debian Wheezy too and this worked for me:

  1. Install Mac drivers from http://beagleboard.org/Getting%20Started
  2. Connect BBB to Mac through USB
  3. On the Mac, go to System Preferences > Sharing > Internet Sharing > Beaglebone Black
  4. In System Preferences > Network, make sure BBB is in the left hand side and shows “Connected”
  5. After SSH’ing into the BBB, run “dhclient” (or "dhclient usb0” if that doesn’t work) and then try “ping google.com”.