On Tue, Dec 10, 2013 at 4:57 PM, <[email protected]> wrote: > Hello, > I'm looking to connect my BeagleBone to the net by sharing my connection > from my mac through USB. > I know that this is possible and I've read many badly written explanations > for it online, but none of them really laid it out in a step by step manner > for someone who is relatively inexperienced with coding. > Could anybody explain how to do this?
Part of the challenge in explaining it clearly is that Apple has broken Internet Connection Sharing on newer updates of Mac OS X. When I want to enable connection sharing over USB, I run this script on my Mac (you'll need a replacement for ssh-copy-id): #!/bin/sh GATEWAY_DEV=en0 HOST_DEV=en1 HOST_ADDR=192.168.7.1 BEAGLE_ADDR=192.168.7.2 sudo /sbin/ifconfig $HOST_DEV down sudo /sbin/ifconfig bridge0 create sudo /sbin/ifconfig bridge0 up sudo /sbin/ifconfig bridge0 addm $GATEWAY_DEV sudo /sbin/ifconfig bridge0 $HOST_ADDR sudo /sbin/route add default -interface bridge0 -ifscope bridge0 -cloning sudo /usr/sbin/sysctl -w net.inet.ip.forwarding=1 sudo /sbin/ipfw add 100 divert natd ip from any to any via $GATEWAY_DEV sudo /usr/sbin/natd -interface $GATEWAY_DEV -use_sockets -same_ports -unregistered_only -dynamic -clamp_mss -enable_natportmap -natportmap_interface $HOST_DEV /Users/jason/gentoo/usr/bin/ssh-copy-id $BEAGLE_ADDR scp /etc/resolv.conf root@$BEAGLE_ADDR:/tmp ssh root@$BEAGLE_ADDR "cat /etc/resolv.conf >> /tmp/resolv.conf.orig" ssh root@$BEAGLE_ADDR "cp /tmp/resolv.conf /etc/resolv.conf" ssh root@$BEAGLE_ADDR "/sbin/route add default gw $HOST_ADDR" -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
