Hello,
I am working an official Pocket Beagle image, kernel v. 4.19.94-ti-r68, and I set up an Internet-over-USB connection successfully , as described here. Basically, I add a default gateway to be my host PC (sudo /sbin/route add default gw 192.168.7.1
), I add nameservers into the /etc/resolv.conf, and on my host PC (Win10), I enable share connection on my WiFi adapter. And it worked like a charm for a couple of weeks.
Then it broke down. My PB is not able to connect to the Internet anymore.
I looked into the file /etc/network/interfaces
, and into ifconfig
, and ip route
, and all seems OK. On my host PC everything is also as it used to be. Don’t know where to look anymore. dmesg
is in the attachment: dmesg.txt (20.4 KB)
Any suggestion what may have happened and how to fix it?
Hi @WesPeros , sadly this is very fun to debug. While the usb-ethernet interface is very useful. It really isn’t 100% reliable, as in the default state, the interface relies on Power and Communications from your USB Host device (Your Win10 PC)… If said USB host decides to ‘reset’ the bus for any local reason, the Pocket Beagle will reboot/reset after the loss of power/etc. Thus you end up debugging both devices. If you want to debug this, make sure your PocketBeagle is running off external power, and make sure you logging all kernel events on both devices…
Regards,
It gets even funner.
I tried installing the wifi dongle, and was successful with my PB recognizing it
debian@beaglebone:~$ lsusb
Bus 002 Device 002: ID 0bda:8179 Realtek Semiconductor Corp. RTL8188EUS 802.11n Wireless Network Adapter
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
debian@beaglebone:~$ ifconfig wlan0
wlan0: flags=-28605<UP,BROADCAST,RUNNING,MULTICAST,DYNAMIC> mtu 1500
inet 192.168.0.241 netmask 255.255.255.0 broadcast 192.168.0.255
inet6 fe80::7ec2:c6ff:fe2a:6e13 prefixlen 64 scopeid 0x20<link>
ether 7c:c2:c6:2a:6e:13 txqueuelen 1000 (Ethernet)
RX packets 643 bytes 281667 (275.0 KiB)
RX errors 0 dropped 53 overruns 0 frame 0
TX packets 524 bytes 213648 (208.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
debian@beaglebone:~$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.7.1 0.0.0.0 UG 0 0 0 usb0
192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 wlan0
192.168.0.1 0.0.0.0 255.255.255.255 UH 0 0 0 wlan0
192.168.6.0 0.0.0.0 255.255.255.0 U 0 0 0 usb1
192.168.7.0 0.0.0.0 255.255.255.0 U 0 0 0 usb0
195.58.161.123 192.168.0.1 255.255.255.255 UGH 0 0 0 wlan0
212.186.211.21 192.168.0.1 255.255.255.255 UGH 0 0 0 wlan0
But I cant connect to the Internet!
Pinging any website (both as URL or as IPv4 address) always returns the same:
debian@beaglebone:~$ ping beagleboard.org
PING beagleboard.org (44.226.162.25) 56(84) bytes of data.
From 192.168.7.2 (192.168.7.2) icmp_seq=1 Destination Host Unreachable
From 192.168.7.2 (192.168.7.2) icmp_seq=2 Destination Host Unreachable
From 192.168.7.2 (192.168.7.2) icmp_seq=3 Destination Host Unreachable
From 192.168.7.2 (192.168.7.2) icmp_seq=4 Destination Host Unreachable
what the heck is going on? how can it not work?
If it helps, here are some relevant files:
dmesg.txt (20.8 KB)
interfaces (819 Bytes) i.e. /etc/network/interfaces
resolv.conf (99 Bytes), i.e. /etc/resolv.conf
EDIT:
This might have been solved. I’ve noticed that ping emits from 192.168.7.2, what can’t be right, since I’m on a wifi, and that IP address is on the USB-Ethernet connection. So, without much knowing what I’m doing, I added a new default gateway route add default gw 192.168.0.1
, that is my home wifi router. And after some time, it worked. I’m not sure why was it necessary, since that gateway was already in my ip tables (route -n above).
It’s fun when we have 2-3 possible network connections…
Regards,