I configured my instance. Its up and running. I can ssh in with my key (provisioned by chef/knife) before assigning an elastic IP. For example this works (before EIP):
ssh -F .ssh/config ec2-ww-xx-yy-zz.us-west1.computer.amazonaws.com
After assigning an EIP I get a:
Permission denied (publickey)
error message as its checking my home folder for the key instead of the project directory.
I even specified the config directory an the EIP:
ssh -F .ssh/config [email protected] -v
which returns a "Connection timed out message".
When I use Elastic Fox I can see the EIP was associated correctly. Am I missing an AWS setting which denies SSH to EIPs?
If you want to use SSH or Remote Desktop Connection to connect to instances within your site, you need to create an Elastic IP and assign one to each instance.
This error occurs if you created a password for your key file, but haven't manually entered the password. To resolve this error, enter the password or use ssh-agent to load the key automatically. There are a number of reasons why you might get an SSH error, like Resource temporarily unavailable.
If you can't connect to an Amazon EC2 instance or an elastic network interface that has an attached Elastic IP address, be sure that: Security group rules for inbound traffic allow connection to the port or protocol.
Once an EC2 instance is launched, it will assign a public and private IP address. An instance's private IP address will never change during the lifetime of that instance. However, its public dns address can change under certain circumstances.
So, after you associate an EIP to any instance, use that IP to login into your machine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With