[AWS][EC2] Connecto to your instance

Connecto to your instance

Connection method: A standalone SSH client
To access your instance:
1. Open an SSH client. (find out how to connect using PuTTY)
2. Locate your private key file (mijung.pem). The wizard automatically detects the key you used to launch the instance.

USING PSCP TO TRANSFER FILES SECURELY(https://www.ssh.com/ssh/putty/putty-manuals/0.68/Chapter5.html)

STARTING PSCP
To start PSCP it will need either to be on your PATH or in your current directory.
set PATH=C:\Program Files\PuTTY;%PATH%

USING PUBLIC KEY AUTHENTICATION WITH PSCP

Firstly, PSCP can use PuTTY saved sessions in place of hostnames. So you would do this:
Run PuTTY, and create a PuTTY saved session (https://www.ssh.com/ssh/putty/putty-manuals/0.68/Chapter5.html#pscp-usage-basics-host) which specifies your private key file. You will probably also want to specify a username to log in.


In PSCP, you can now use the name of the session instead of a hostname: type pscp sessionname:file localfile, where sessionname is replaced by the name of your saved session.
example) pscp C:\Users\mijung\.ssh\mijung.pem Dev:/home/ec2-user/.ssh/mijung.pem

3. Your key must not be publicly viewable for SSH to work. Use this command if needed:
chmod 400 mijung.pem

4. Connect to your instance using its Private IP:
Example:
ssh -i "mijung.pem" ec2-user@10.30.250.129

Please note that in most cases the username above will be correct, however please ensure that you read your AMI usage instructions to ensure that the AMI owner has not changed the default AMI username.

Comments

Popular posts from this blog

VPC

Essential git commands

Basic Concept of Docker