Connect SSH to EC2 instance via Putty thru VPC

Posted under » AWS on 11 May 2021

Setting up an EC2 instance is straightforward. Here are some of my settings

For linux you use

ssh -i /path/my-key-pair.pem ubuntu@

For Putty, you need to convert the pem to ppk

$ sudo apt-get install putty-tools
$ sudo puttygen pemKey.pem -o ppkKey.ppk -O private
// or 
$ sudo puttygen ppkkey.ppk -O private-openssh -o pemkey.pem

If you encounter the 'It is required that your private key files are NOT accessible by others' then chmod 400 your .pem file.

The security group is the one that enables or disable you from connecting. It is connected to the default VPC that has enabled all access but still I was unable to connect. So I created a new security group and enable SSH access as it was closed by default. I allow access via a single IP address.

This address might not be static if your computer is on a corporate network or if you are connecting through an internet service provider (ISP). Instead, you should specify the range of IP addresses used by client computers.

web security linux ubuntu python django git Raspberry apache mysql php drupal cake javascript css AWS