Internet Connection Sharing Xavier

Hello,

I am having some trouble figuring out what is preventing internet connection sharing from working with a Linux host and the Jetson Xavier NX on a Seeed A203 Carrier Board.

Host information (uname -a):

Linux debian 6.1.0-16-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.67-1 (2023-12-12) x86_64 GNU/Linux     

Jetpack Information:

# R35 (release), REVISION: 1.0, GCID: 31346300, BOARD: t186ref, EABI: aarch64, DATE: Thu Aug 25 18:41:45 UTC 2022

Followed the direction in README-usb-dev-mode.txt. So on host with the USB cable connected to the Jetson Xavier ip a s enxf2bfc334e0bc shows:

6: enxf2bfc334e0bc: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN group default qlen 1000
link/ether [...]
inet 192.168.55.100/24 brd 192.168.55.255 scope global dynamic noprefixroute enxf2bfc334e0bc
   valid_lft 10sec preferred_lft 10sec
[...]

So my interface is enxf2bfc334e0bc and IPv4 is 192.168.55.100 I have enabled IP forwarding and added the SNAT rule from the documentation and verified with the following:

 cat /proc/sys/net/ipv4/ip_forward
 1
 sudo iptables -t nat -v -L POSTROUTING -n --line-numbers
 Chain POSTROUTING (policy ACCEPT 0 packets, 0 bytes)
 num   pkts bytes target     prot opt in     out     source               destination         
 1       52  7420 SNAT       0    --  *      enxf2bfc334e0bc  0.0.0.0/0            0.0.0.0/0            to:192.168.55.100     

The Jetson Xavier is accessible by ssh when logged in the following can be pinged:

  • 192.168.55.100 (enxf2bfc334e0bc)
  • 192.168.1.98 (wifi interface)

However, a ping of 8.8.8.8 , the fallback DNS, fails. And hostname resolution fails. For example:

getent hosts nvidia.com

So no internet access from the Jetson Xaiver over usb.

Notes:

  • I have the other usb interface disabled in NetworkManager.
  • Internet connection sharing with the same software load and Windows 11 is working.

Any ideas on what I might be missing?

Thanks

Hi,
This would need other users to check and shar experience. There is ethernet port on Xavier NX developer kit and we generally use it.

The latest Jetpack 5 release is 5.1.2 and it would be great if you can upgrade to latest version.

A careful reading of README-usb-dev-mode.txt revealed my mistake:

iptables -t nat -A POSTROUTING -o eth0 -j SNAT --to 192.168.1.100

where:
 eth0 is the name of your host's upstream Ethernet interface.
192.168.1.100 is your host's IP address on that interface.

In my original post the output from iptables was:

sudo iptables -t nat -v -L POSTROUTING -n --line-numbers
Chain POSTROUTING (policy ACCEPT 0 packets, 0 bytes)
num   pkts bytes target     prot opt in     out     source               destination         
1       52  7420 SNAT       0    --  *      enxf2bfc334e0bc  0.0.0.0/0            0.0.0.0/0           to:192.168.55.100

But, I should be using my host interface and IP the iptables output should be:

1     383 35456 SNAT       0    --  *      wlp59s0  0.0.0.0/0            0.0.0.0/0            to:192.168.1.98

So using my upstream interface and IP address as described in README-usb-dev-mode.txt resolves this isssue.

In short:

My internet connected interface is wlp59s0 and the IP is 192.168.1.98. So rule for iptables should read:

iptables -t nat -A POSTROUTING -o wlp59s0 -j SNAT --to 192.168.1.98

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.