Virtual Machines

SSH Connection VMs

Learn how to connect to your Virtual Machines using SSH (Secure Shell). SSH provides secure command-line access to both Linux and Windows VMs, enabling you to manage your systems remotely through a terminal interface.

SSH is the standard method for secure remote access to Unix-like systems and is now also supported on Windows Server. It provides encrypted communication, making it safe to manage your VMs over the internet. Unlike RDP, SSH is text-based and requires less bandwidth, making it ideal for automated tasks.

Getting Started with SSH Access

Before connecting via SSH, ensure you have:

  • SSH enabled on your VM: Port 22 open in Network Security Group
  • SSH keys configured: Public key authentication is recommended over passwords
  • VM credentials: SSH private key saved locally and securely (You can also opt for a username/password access, which is less secure)
  • SSH client installed: Built into most modern operating systems

🔐 Storing your SSH Key

Remember to download and save the SSH private key when creating your VM with SSH enabled. Store it in the proper location (typically the ~/.ssh folder) and secure it with chmod 600 permissions.

Quick Connection Example

Once your SSH keys are configured, connecting is straightforward:

  • With SSH key: ssh -i /path/to/private-key username@your-vm-ip-address
  • With password: ssh username@your-vm-ip-address
  • -- you will be prompted for the password