Handle SSH Host Key Changes

Handle SSH Host Key Changes

On the GreenNode AI Platform, notebook instances are ephemeral — meaning they may receive a new IP address and regenerate their SSH host keys each time you stop and restart them. This behavior can cause SSH to refuse the connection due to changed host identification, showing an error like:


This guide shows you how to safely and effectively bypass SSH StrictHostKeyChecking to streamline your connection to GreenNode notebook instances.
Alert
SSH host key checking is designed to prevent Man-in-the-Middle (MitM) attacks. The steps below are suitable only when you're connecting to trusted GreenNode-managed environments.

Method 1: One-Time SSH Connection (No Host Key Check)

Use the following command to bypass the check for one session:
  1. ssh -p <your-instance-port> root@<your-instance-ip> -i ~/.ssh/id_rsa -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null
Use this for quick debugging or temporary access.

Method 2: SSH Config Entry for GreenNode Notebook Instances

To make SSH easier to use, add a config block to your ~/.ssh/config:
  1. Host greennode-notebook    
  2.            HostName <your-instance-ip>
  3.            Port <your-instance-port>
  4.            User root    
  5.            StrictHostKeyChecking no    
  6.            UserKnownHostsFile /dev/null
  7.            IdentifyFile ~/.ssh/id_rsa
Then connect using:
  1. ssh greennode-notebook


    • Related Articles

    • Connect to a notebook instance

      Greennode AI Platform offers three methods to connect to notebook instances: Code Editor: Directly access and edit code within the platform's web-based code editor. TCP Port: Connect to the notebook instance using a specified TCP port. SSH: Connect ...
    • Expose ports

      When you want to expose a port from your notebook instance to the public internet, it's important to understand that the internal port you use in your container will likely not match the public-facing port. Let’s walk through an example to explain ...
    • Manage API keys

      This guide will show you how to create, copy, and delete API keys in the GreenNode AI Platform. Creating an API Key To generate a new API key: Go to the API Keys section in the GreenNode Portal. Click on the Add Key button. Enter a name for your key ...
    • Function calling

      GreenNode MaaS supports function calling, allowing you to define a set of tools or functions that the model can reason about and invoke intelligently based on the conversation context. This enables the creation of dynamic, interactive agents capable ...
    • Team Role

      Team roles in GreenNode are designed to support secure and efficient collaboration by assigning clear permissions and access levels to each team member. Roles define what actions a user can take and which parts of the Team Space they can access — ...