How do I set up SSH access for an Amazon EC2 instance?

后端 未结 13 1069
挽巷
挽巷 2021-01-29 19:20

I need SSH access to an Amazon EC2 instance running Ubuntu 10.4. All I have is the Amazon username and password. Any ideas?

13条回答
  •  一生所求
    2021-01-29 19:33

    1) First chmod the .pem file for restricting the file permissons as below

    chmod 400 my-key-pair.pem
    

    2)Then ssh with the following commands directly from .ssh folder

    ssh -i my-key-pair.pem ec2-user@ec2-198-99-90-3.compute-1.amazonaws.com

    Note:- To navigate into .ssh folder. First press Ctrl + H to display all the hidden files and finallycd .ssh

提交回复
热议问题