Creds for jetson nano intro course

Hello -
i have the dli course image up and running fine so far in headless mode via usb, but was wondering if the credentials used in setting that image up are available so that i can puTTY in to set up headless mode over my local network.
it would just be more convenient as i am only able pick up small chunks of the course when i catch a moment. not being tethered to the nano would also open up more time slots as well that aren’t possible otherwise.

thanks in advance!

Yes. It will work if you know the ip or hostname and have the Nano plugged into your local network. The ssh daemon is running by default and set up to use password authentication. It should “just work” as expected with putty.

thanks for the quick response but i think i may need to be a bit more specific.

this is in regards to the image provided by the DLI for coursework, not the image for general development/usage. this course image seems to be intended for jupyter notebook interaction only with the nano (at least from what i’ve seen so far).

the USB headless connectivity and 192.168.55.1:8888 works very well for the coursework, but because its not your “normal” network topology/protocol, the addressing fails (can’t ping address when hooked up only to ethernet).

the exposed address nvidia provided is 192.168.55.1, where the C-class portion of the address is: 55; my (and most other home networks, obvious or not) is 1 (192.168.1.X) with a 255.255.255.0 sub-net mask. i guess i could look into how to change the sub-net mask on my ISP provided DHCP router… something i’ve not looked forward to doing with my ISP .

it would seem logical enough that they intentionally would want to enforce usb tethering somehow, but i’m still just wondering if i can’t somehow find a way to go headless over ethernet on the DLI image. i could certainly do it if i had the creds to the primary login of the image… i get it, not a great look on the security front, but really just need a way to drop the nano loaded with course work off in the basement on rj-45, while i roam around and drop in with the laptop when i can. i know this is very possible w/nano in general, but for the course image, it doesn’t appear so and it would great if it could!

Don’t change your router to match. You will have conflicts instead of what you want. Use the “ip address” command on the nano to find the ip address of each interface. USB is …55.1 always. Instead connect to 192.168.1.whatever:8888 (if that is the port you want) if you want port 8888 where “whatever” is the ip address your nano’s eth0 interface is assigned by your router. It should work.

i hear you, mdegans - i wasn’t truly thinking about messing around with my local network… i think this post has come full circle as i have no way to access the nano’s NIC IP info b/c this is the DLI coursework image (not the clean, never before used image with no user configured) and not knowing the nano’s local login creds… having said that, i wrote a simple app that spins thru the possible urls (http://192.168.1.{x}:8888) and kicks back responsive (http resp code 200) requests. it works. thanks for your help and time; it is truly appreciated.

There shouldn’t be a need to scan your whole network. You should be able to just access hostname:8888

If dns is not configured to allow that or your local dns server is having issues, you can find the nano’s ip address (and possibly hostname) through your router (instructions will vary) or through the actual Nano by running the “ip address” command or similar (ifconfig, etc…). Login credentials for dli image are in documentation, I believe.

Ip address will be assigned by your local DHCP server (usually your router). In you case you can probably log in to 193.168.1.1 and have a look at the DHCP section of the configuration. You may wish to assign a static IP to your nano through your router so it’s always the same ip address.

just had the “ah ha!” moment - i’m new to jupyter notebooks and i’m now guessing that you mean that i should run the “ip address” command within a terminal window in jupyter… i thought you were suggesting that i do that via putty (which wouldn’t make sense b/c that’s what i was trying to do even posting my question in first place). anyways, thanks for sticking out my jupyter noobness.

for clarity and summary of solution for others w/same question/issue:

  1. follow DLI course instructions headless nano setup using USB connection; this should conclude with you successfully logged in to jupyter notebook
  2. reboot nano with ethernet cord plugged in (not 100% sure need to reboot, but that's what i did) along with USB; wait the standard 30-45 seconds
  3. go to USB IP:port (192.168.55.1:8888) and log in if prompted
  4. in jupyter, find the "Launcher" tab/page in main window on right; find/click on "Terminal" card in "Other" section at bottom
  5. within terminal session, run "ip address" command and find "eth0" listing for your nano's DHCP-issued IP address (as suggested by mdegans)

Nope. But if you can log into jupyter the ip address should be in the url. If a hostname (abcd:8888) is in the url instead, you don’t need the ip address, but to get it you could just “ping abcd” from any command prompt, either in windows or linux, provided you disconnect the usb first.

If you are accessing jupyter through usb, you can find the IP address of the eth0 interface (the ethernet port on the Nano) by pasting this into a cell:

import socket
import fcntl
import struct

def get_ip_address(ifname):
    s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
    return socket.inet_ntoa(fcntl.ioctl(
        s.fileno(),
        0x8915,  # SIOCGIFADDR
        struct.pack('256s', ifname[:15])
    )[20:24])

get_ip_address('eth0')  # '192.168.0.110'

source:
https://stackoverflow.com/questions/24196932/how-can-i-get-the-ip-address-from-nic-in-python

Nope, I was actually suggesting you find out by plugging in a keyboard and monitor, if you can’t find it in your router. Sorry for not being clear.

That works if your jupyter instance allows it.

thanks for the clarifications, alternate solutions, and keeping up with the posts.

If you want to get the IP address of whichever interface is used to connect to the network without having to know its name, you can use this:

import socket
def get_ip_address():
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
s.connect((“8.8.8.8”, 80))
return s.getsockname()[0]

You do not have to have a route to 8.8.8.8 to use this. All it is doing is opening a socket, but not sending any data.