Talk:ECE497 Tips and Tricks
I believe the topic of Internet connection sharing from a Windows/Linux/Mac host to BeagleBone's USB virtual network connection could be elevated to its own page as I believe this is a common use-case. In the case of Mac, I've found http://apple.stackexchange.com/questions/73485/internet-sharing-from-wifi-to-ethernet-doesnt-work-in-mountain-lion, but haven't had time to try it.
This worked for me: https://discussions.apple.com/thread/5152615
Here's my whole script:
#!/bin/sh BEAGLE_ADDR=192.168.7.2 HOST_ADDR=192.168.7.1 sudo sh -c <<SCRIPT gwdev=en0 targetdev=en1 /sbin/ifconfig $targetdev down /sbin/ifconfig bridge0 create /sbin/ifconfig bridge0 up /sbin/ifconfig bridge0 addm $gwdev /sbin/ifconfig bridge0 $HOST_ADDR /sbin/route add default -interface bridge0 -ifscope bridge0 -cloning /usr/sbin/sysctl -w net.inet.ip.forwarding=1 /sbin/ipfw add 100 divert natd ip from any to any via $gwdev /usr/sbin/natd -interface $gwdev -use_sockets -same_ports -unregistered_only -dynamic -clamp_mss -enable_natportmap -natportmap_interface $targetdev SCRIPT 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"
Jkridner (talk) 20:38, 6 July 2013 (UTC)
Good suggestion. I've moved the instructions from this page and put them in EBC_Exercise_02_Internet_Connection_via_the_Host.
I don't think the DNS problem from the Bone's side has been solved. I don't know how to make connman do what used to be done with /etc/resove.conf.
- [View source↑]