DEV Community

Cover image for Putty connection to AWS Linux instance
Z. QIU
Z. QIU

Posted on

Putty connection to AWS Linux instance

I have registered my personal AWS account today (FINALLY). The entire process was easy for me, however, I encountered an issue when I try to connect to AWS Linux instance from ssh within Windows.

I am always using Putty for connection to my Cloud servers. Thus I firstly tried Putty in same way I used to connect to AliCloud. Unfortunately I encountered the following error message.
Alt Text

Then I tried to use ssh -i xxx.pem ... command in CMD console. However, AWS sent back the following complaints:
Alt Text
It seems a permission issue which can easily been solved using chmod in Linux. However, I am using Windows and I'm really not familiar with the complicated "permission" rules in Windows. Some online articles presents solution of this issue using icacls. However, it did not work in my case.

Official doc of AWS has presented a really useful solution. It's quite simple and efficient. Following this tutorial, I executed Putty Key Generator, load my "xxx.pem" file and export an .ppk key file.
Alt Text

Then in Putty interface, I load my .ppk key file (as shown below) and try the ssh connection as usual. And it works.

Alt Text

Reference:
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/putty.html

Top comments (5)

Collapse
 
mrboogiej profile image
mrboogiej

Would you like to try cloud products on Alibaba Cloud?
alibabacloud.com/

Collapse
 
zqiu profile image
Z. QIU

In fact, i am using AliCloud intensively😀. All our current SaaS projects are running on AliCloud.

Collapse
 
mrboogiej profile image
mrboogiej

Oh really? May I know how many products are u using for now and how do you feel about the experience?

Thread Thread
 
zqiu profile image
Z. QIU

We have been using Alibaba ECS for more than 2 years. It has always been stable and quite user-friendly. I appreciate it and feel satisfied.

Thread Thread
 
mrboogiej profile image
mrboogiej

Thank you for running with us, it even shined my day to hear that. Actually, we also have many more like security and DBaaS products, and I'm in charge of database product operations, if you take a look, we have widest range of database services in the globe such as MongoDB the favorite of developers in gaming, and others in OLAP field. We would like to help if you have any interest.

And again, thanks for choosing us and may you a glooming new year.