Deep Learning AMI
Developer Guide

Configure a Windows Client


Be sure you have the following information, which you need to set up the SSH tunnel:

  • The public DNS name of your Amazon EC2 instance. You can find the public DNS name in the EC2 console.

  • The key pair for the private key file. For more information about accessing your key pair, see Amazon EC2 Key Pairs in the Amazon EC2 User Guide for Linux Instances.

Set up PuTTY

The following step-by-step instructions explain how to connect to your EC2 instance and set up an SSH tunnel using PuTTY, a free SSH client for Windows. If you receive an error while attempting to connect to your instance, see Troubleshooting Connecting to Your Instance. As a prerequisite, download and install PuTTY from the PuTTY download page. If you already have an older version of PuTTY installed, we recommend that you download the latest version. Be sure to install the entire suite.

  1. For connecting to your EC2 instance using PuTTY, you first need to convert your private key file (.pem) generated by Amazon EC2 to a format that is recognized by PuTTY (.ppk). You can find the instructions for creating the .ppk file at Connecting to Your Linux Instance from Windows Using PuTTY. Search for “Converting Your Private Key Using PuTTYgen” in that topic.

  2. Now open PuTTY and navigate to Session under Category in the left pane. Enter the following information:

    Connection type: SSH

    Host Name: ubuntu@YourInstancePublicDNS

    Port: 22

    Be sure to specify the appropriate user name for your AMI. For example:

    • For an Amazon Linux AMI, the user name is ec2-user.

    • For a RHEL AMI, the user name is ec2-user or root.

    • For an Ubuntu AMI, the user name is ubuntu or root.

    • For a Centos AMI, the user name is centos.

    • For a Fedora AMI, the user name is ec2-user.

    • For SUSE, the user name is ec2-user or root.

    Otherwise, if ec2-user and root don't work, check with the AMI provider.

    putty connection and config
  3. Now expand Connection on left pane. Navigate to Auth under SSH. Browse and add the .ppk file you created in Step 1 before. Then click Open at the bottom of the screen.

    login screen
  4. If this is the first time you have connected to this instance, PuTTY displays a security alert dialog box that asks whether you trust the host you are connecting to. Choose Yes. A window opens and you are connected to your instance.

  5. Now to set up the SSH tunnel to your EC2 instance, right click on the top left corner of your instance’s window as highlighted below. It will open a dropdown menu. Select Change Settings from the menu to bring up PuTTY Reconfiguration screen.

    ssh example
  6. Navigate to Tunnels under SSH on the left pane. Fill up the Source port and Destination as shown below. Select Local and Auto as port forwarding options. Finally, click Add followed by Apply to finish setting up the SSH tunnel.

    login screen

The above simplified instructions give you a quick and easy way to connect to your EC2 instance using PuTTY. If you want to learn more about the topic, you can look at our Connect to Your Linux instance from Windows guide.

Next Step

Test by Logging in to the Jupyter notebook server

On this page: