March 3, 2025
maksure You same version of the k3s in both Servers (if the jetson is connected to another machine with Integrnet access )  – if it is a direct connection using rj45 it should be a cross over cable . remeber when 2 same type of devices are connected you have to use the cross over cable. else it should go through. a switch
“curl -LO https://github.com/k3s-io/k3s/releases/download/v1.29.1+k3s1/k3s-arm64 curl -LO https://github.com/k3s-io/k3s/releases/download/v1.29.1+k3s1/k3s-airgap-images-arm64.tar.gz. ” 

after download of the files (k3s-arm64 and k3s-airgap-images-arm64.tar.gz) onto a USB drive using the curl commands, we can proceed with installing K3s on your Jetson (running Ubuntu) and joining it as an agent to your existing RHEL K3s server cluster. Here are the tailored steps based on your current progress:

Steps to Install K3s on Jetson and Join the RHEL Cluster

1. Transfer Files from USB to Jetson

    • Plug the USB drive into your Jetson.
    • Locate the USB mount point (e.g., /media/<username>/USB_NAME). You can find it by running:
        • lsblk (look for a device like /dev/sdb1 mounted under /media)
        • Or check ls /media/<username>/ to see the USB’s name.
    • Copy the files to your Jetson’s home directory (or another preferred location):
        • cp /media/<username>/USB_NAME/k3s-arm64 ~
        • cp /media/<username>/USB_NAME/k3s-airgap-images-arm64.tar.gz ~
    • Replace <username> and USB_NAME with the actual values (e.g., /media/user/MyUSB).

2. Gather Info from RHEL Server

    • Node Token: On your RHEL server (where K3s is already running), get the cluster token:
        • sudo cat /var/lib/rancher/k3s/server/node-token
        • It’ll look like K10…::node:mysecretk3stoken. Write this down or copy it somewhere safe.
    • Server IP: Note the RHEL server’s IP address (e.g., 192.168.1.100). Ensure the Jetson can ping it on your local network:
        • From Jetson: ping <RHEL-IP> (if this fails, fix network connectivity first).

3. Install K3s on Jetson (Agent Mode)

    • On the Jetson, assuming the files are in your home directory (~):
        • Make the binary executable:
            • chmod +x ~/k3s-arm64
        • Move it to a system path:
            • sudo mv ~/k3s-arm64 /usr/local/bin/k3s
        • Place the airgap images in the correct directory:
            • sudo mkdir -p /var/lib/rancher/k3s/agent/images/
            • sudo mv ~/k3s-airgap-images-arm64.tar.gz /var/lib/rancher/k3s/agent/images/
        • Start the K3s agent, connecting to the RHEL server:
            • sudo k3s agent –server https://<RHEL-IP>:6443 –token <your-token>
            • Replace <RHEL-IP> with the RHEL server’s IP (e.g., 192.168.1.100) and <your-token> with the token from step 2.

4. Verify the Cluster from RHEL Server

    • On the RHEL server, check if the Jetson has joined the cluster:
        • sudo k3s kubectl get nodes
        • You should see a new node (likely named after the Jetson’s hostname or IP) with a status of Ready.

Additional Notes

    • Permissions: Ensure you run commands with sudo where required, as K3s needs root access to set up directories and services.
    • Networking: The Jetson must reach the RHEL server on port 6443. If it doesn’t join, verify connectivity and check RHEL’s firewall (sudo firewall-cmd –list-ports on RHEL; ensure 6443/tcp is open if firewalld is active).
  • Logs: If something goes wrong, check logs on Jetson:
      • sudo journalctl -u k3s-agent
    • Or on RHEL: sudo journalctl -u k3s.

Leave a Reply

Your email address will not be published. Required fields are marked *

Share via
Copy link
Powered by Social Snap