after connecting usb to nano, it is getting detected , and connected via ssh .
But as said in the document
Linux for Tegra configures a very low priority default IPv4 route on the USB
Ethernet device(s), and configures Google's public DNS server (8.8.8.8) as the
fallback DNS server for use when no other network connection is available.
This allows your host machine to act as an Intranet or Internet gateway for
Jetson.
It is not getting access to the host gateway.
some more configurations need to be done??
Ok so after reading further I came across that the following should be done-
Evenhough if I ping 192.168.55.100 from jetson it is showing packet transmission. But it is still not getting the access to internet.
Can anybody suggest me where I am going wrong?
I have not set up forwarding on an Ubuntu host, but basically the host setup for forwarding is what you have to complete. In the case of a removable interface (which USB is) you might need some extra step to make a temporary forwarding permanent. I’m only guessing, but this should probably be correct if there is no firewall involved: https://tecadmin.net/enable-ip-forwarding-linux/
Your Nano would also have to have the default route set to “192.168.55.100”. If the above doesn’t work, then also post the Nano and PC’s outputs for:
So on the Jetson side there won’t be a route unless through the USB virtual ethernet. Wired did not receive an address.
The host PC shows enp0s29u1u2i5 as the address for the host side of the USB virtual ethernet, 192.168.55.100. Your host also has a working gateway, so if forwarding is enabled, then your Jetson should be able to talk through the virtual USB ethernet.
Even if forwarding is not enabled, you should be able to “ping 192.168.55.100”. Can you verify this works? If it does, then what you are missing is forwarding on the host PC.
One more thing to test before looking at NAT. The address used for nvidia.com is “216.228.121.209”. I assume you can ping this from the PC, but not the Nano. If you can ping this from the Nano, then forwarding and NAT are not the problems…it would be a DNS problem. If you can’t ping that from the Nano, then you would indeed need to configure NAT (and this probably is the issue, but I wouldn’t want to find out it isn’t after spending a lot of time trying to configure the host PC).
I have not spent a lot of time working on Ubuntu NAT (I tend to do that with Fedora), so someone else might jump in if there is NAT setup advice. However, the program “ufw” is for configuring the Ubuntu firewall. If you don’t have ufw, then:
I’ve used UFW before and find it easier than editing files, but you would still need to edit some non-firewall files. Logging is important because then you can run “dmesg --follow” while changing things and see what errors or successes occurred. Try to run “dmesg --follow” before starting any kind of configuration work. If you do see messages from any of the config steps, then post what you see (I’m not actually configuring NAT on an Ubuntu host, so it is a bit of going bump in the dark and stumbling around).
In the above URL I see more than just ip_forward is set to 1. You can probably ignore the IPv6, but some software may use this. As long as you use the test address I gave earlier to “ping 216.228.121.209”, then you know you are testing IPv4. For the most part you can ignore IPv6, but this may not always be the case. Try the Ubuntu NAT advice on that URL.
So this verifies it isn’t just a DNS issue. I don’t know if I am reading this correctly (I’m using a Fedora host), but it looks like the firewall is blocking (the “[UFW BLOCK]”). Is wlp3s0 the PC’s connection to the outside world? The blocked networking could be a result of something other than the Nano, but if it is the Nano, then the solution would be opening the firewall. Run “dmesg --follow” and watch for new messages which occur as you try to use the Nano…if the messages occur from your attempts to talk to the outside world, then you’ve found the issue. If not, then it is something else (but be sure logging is on or you’ll definitely not see logs).
I dont know it is error in “README-usb-dev-mode Linux for Tegra USB Device Mode” manual or not, but a small change in the documentation worked like a charm for me.
#!/bin/sh
# Share one network's internet connection with another network.
# eg: If your Wifi adapter with internet is called wlan0
# and your local Ethernet adapter is called eth0,
# then run:
# ./share_my_internet.sh wlan0 eth0
# This will only last until you reboot your computer.
sudo iptables --flush
sudo iptables --table nat --flush
sudo iptables --delete-chain
sudo iptables --table nat --delete-chain
sudo iptables --table nat --append POSTROUTING --out-interface $1 -j MASQUERADE
sudo iptables --append FORWARD --in-interface $2 -j ACCEPT
sudo sysctl -w net.ipv4.ip_forward=1
chmod +x share_my_internet.sh
Run by
./share_my_internet.sh <Host's internet interface name> <Host's nano's usb interface>
For me that’s sharing laptops wifi = wlp4s0 to usb interface enp0s20u3
After a bit of struggle with window’s gui I got it working there too.
It’s rather trivial, but confusing gui had me lost for a while :D
Steps would go something like this (Win 8.1),
On plugin Tegra driver should auto install, new ethernet RNDIS adapter is added. At this point 192.168.55.1 (:8888) is visible to host.
Control panel → Network and Internet → Network and Sharing Center → Change adapter settings → Select host’s adaper with internet + Properties → Sharing tab → Check “Allow other network users to connect…” + Select new RNDIS adapter. Nice thing is that windows auto set up passthrough with nat, but also decide to set their own dhcp, disregarding jetson’s. Easy fix is to open RNDIS adapter’s Properties → Scroll to IPV4 adapter item → Properties → Set either static ip, for example 192.168.55.100 with gateway at .1 or select automatically obtain IP.
After that it should work.
Can’t ping host from jetson, unless you change firewall rules on host. One way would be to chnage adapter from public to private, but not sure how to do that. Other way to manually change in public inbound firewall settings. Third easiest, maybe risky, exempt jetson’s adapter from public profile protected network connections list.
Hy,
I am new with the jetson nano 4gb kit. I manage to connect in ssh from my windows10 PC to the jetson nano card via usb, but I cannot get my jetson card to connect to the internet to follow the “start with IA jetson nano” tutorial. The ping goes in both directions with 192.168.55.1 and 192.168.55.100 (USB cable and Ethernet). My PC is connected to the internet: ping google.com correct on my PC but not on my card ?!
I removed the firewalls without success.
If you have an idea.
I thank you in advance.
Have a nice day
This should probably be a new topic. Briefly though, you have to tell Windows to allow forwarding from the Jetson device (one virtual wired ethernet) to the internet (a different ethernet). The original problem of this thread (routing lost) is a different topic.