AWS Create/change key pair for EC2 instance
Under EC2 -> Network & Security -> Key Pairs -> Create with name: Mirror
It will give you Mirror.pem
PuyttyGen:
PuttyGen -> Load this PEM -> Generate
Download public key as Mirror.pub & private key as Mirror.ppk
Login in instance:
vim ~/.ssh/authorized_keys
Open Mirror.pub, copy whole key as single line, without new line characters (after Comment: and before END SSH2 PUBLIC KEY)
ssh-rsa <copied text from above> <Mirror(without pem extension)>
e.g.,
ssh-rsa AAAAB3NzaC1yc2EAAA...urR2A5IUkqscHRU1Nc7TFz363UFJW6XMYae1116PO4 Mirror
Setup Mirror under Putty like below:
Host Name -> EC2 Host Name
Connection -> SSH -> Auth -> Add Mirror.pek path & save
Now login into EC2 as root
(it should not ask any password)
Under EC2 -> Network & Security -> Key Pairs -> Create with name: Mirror
It will give you Mirror.pem
PuyttyGen:
PuttyGen -> Load this PEM -> Generate
Download public key as Mirror.pub & private key as Mirror.ppk
Login in instance:
vim ~/.ssh/authorized_keys
Open Mirror.pub, copy whole key as single line, without new line characters (after Comment: and before END SSH2 PUBLIC KEY)
ssh-rsa <copied text from above> <Mirror(without pem extension)>
e.g.,
ssh-rsa AAAAB3NzaC1yc2EAAA...urR2A5IUkqscHRU1Nc7TFz363UFJW6XMYae1116PO4 Mirror
Setup Mirror under Putty like below:
Host Name -> EC2 Host Name
Connection -> SSH -> Auth -> Add Mirror.pek path & save
Now login into EC2 as root
(it should not ask any password)
No comments:
Post a Comment