Hey all, I'm absolutely pathetic at networks so hopefully someone can point me in the right direction.

I've got a laptop connected via wlan0 to a 3G modem. It connects to the internet without any issues. Connected to it via eth1 using an ethernet cable is a beaglebone (think raspberry pi) running angstrom linux. on the network, it's known as 192.168.7.2. it currently cannot connect to the internet:

You can either set your laptop up as a router
I suppose you have Gentoo there :)

Or you can run PPP between the laptop and beaglebone and give both endpoints addresses in the 192.168.0.0/24 subnet.
Then it will all JustWork. You will need a script to start PPP on the laptop. This is what I used to do or my iPaq.

says the beaglebone has the link-local IP of 169.254.149.95, which is not what you claimed

Moult wrote:

it's known as 192.168.7.2

At least, at the time of the ping you posted, it had the IP address of 169.254.149.95. ssh would not work like that, so something in the data set is not self consistent.

-- edit --
Reading more carefully, the ping is going out of eth0 on the beaglebone, you need it to go over usb0.
That suggests the default route on the beaglebone is via eth0, not usb0_________________Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.

Thanks for your fast reply. The beagle is connected via eth1 and usb0 to the laptop. The usb powers it and the eth allows me to connect to it (i hadn't worked out how to do Internet over usb). I say 192.168.7.2 because that's the ip I ssh to if I want to connect to the beagle from my laptop. So yes, the ping is going through eth and not usb. I thought that was the way it should be? Or am I misunderstanding something?

Also, if I am on the beagle, I can ssh back into the laptop by sshing into 192.168.7.1. Hopefully that helps explain something.

As for the solutions you suggested, I think ppp would be easier than a router. Have you got a guide for that?_________________thinkMoult - blog and stuff
WIPUP - share your works-in-progress for long-term, ambitious projects.

As Neddy says, the Ethernet interface on the Beaglebone has not received a valid address via DHCP, so it assigned one via APIPA. The USB interface does have a valid address, which is how you are able to ssh to and from the device. For any address on the same subnet as the address assigned to usb0, the device will prefer using usb0, which is why it can answer your ssh connection from the laptop and why it can ssh to the laptop. However, for any other address, it will rely on the default route, which appears to have been set to eth0. Since eth0 is not configured to route traffic properly, this means the traffic fails.

You have two options. We can change the routing table to prefer usb0, so that both subnet-local and general traffic is sent over USB. We could try to fix eth0 so that you can pass traffic over it. For the former, please try ip route del default ; ip route add default via 192.168.7.1. For the latter, you would need to arrange to provide DHCP service when eth0 requests an address.

# bring up the PC end of the link with IP addr PC_ADDR
# exit if it fails for some reason
/sbin/ifconfig usb0 inet $PC_ADDR up
if [ $? -ne 0 ]; then
echo "Could not set up usb0"
echo "Is the iPaq connected and switched on?"
exit 1
fi

# set up proxy_arp for our usb interface
echo "1" >/proc/sys/net/ipv4/conf/usb0/proxy_arp
UPLINK=`/sbin/ifconfig $UPLINK_IF >/dev/null 2>&1`
# exit if it fails for some reason
if [ $? -ne 0 ]; then
echo "Could not set up proxy_arp for usb0"
exit 1
fi

# set up proxy_arp for eth0, so this better be our
# internet connection
echo "1" >/proc/sys/net/ipv4/conf/eth0/proxy_arp