18 December 2010

Can't SSH to Amazon Elastic Compute Cloud (EC2) Instance

I've decided that I'm going to learn about Amazon Elastic Compute Cloud (EC2) over this Holiday break.  I've read a few articles, listened to a few podcasts so I have an idea what it's about, just haven't actually gone thru the motions myself.

What am I going to do with a virtual machine (VM) in the cloud?  Not much quite yet.  I have some ideas but first need to figure out how things work.

So on Friday night I signed up for an EC2 account and started to follow the Getting Started Guide on the Amazon site.  As usual, things went smooth for the first few minutes but as usual, progress came to an immediate screeching.

I started an plain vanilla Basic 64-bit Amazon Linux Amazon Machine Image (AMI) just to get things going and verify that I could SSH into the thing per the getting started guide.  But when I SSH'd, nothing, nada, zip.  Timeout.


This darn thing acts like it's not running.  I started, restarted, used different AMI, mucked with security group setting without any progress.  I even edited the default security group to open the thing wide open:


Still nothing.  Did the google thing to see what other people are doing and came across a few hits in the Amazon Web Services forums where people are claiming the the web services aren't starting up correctly in the US-East zone.  Hey, that's me!  Ok, I'm not stupid, its just some tech problem.  I'll take a break and try it again in a few hours.

Few hours later:  nothing, nada, zip.  Ok, I am stupid.  I can't even log into a stupid instance.  I probably started/stopped an EC2 AMI 10 times but can't do anything with it.  This new thing I've learned is frickin' amazing.

And as usual, as soon as I've convinced myself that all hope is lost, ding.  Wait, doesn't my Westell DSL modem block SSH?  Oh, frick of course it does.  Damn it so, the last 3-4 hours of trouble was caused by my own firewall??

Of course it was.  I really hate this Verizon provided modem and keep telling myself that I'm going to buy a different one.  But this is free and I'm cheap.  So I'll keep shooting myself in the foot and someday get smarter and dump this junk.

In the Firewall->Port Forwarding menu, I just added the SSH service to a dynamic host.


And now when I launch a new instance, I get this:


Amazing.  Only hours and hours of work to launch and connect.  Let the fun begin.

What do you think? Leave a comment.

3 comments:

Anonymous said...

What do I think? You're an idiot. You should've checked your firewall as one of the first things.

Anonymous said...

Yeah, I have to agree with anon. You should've checked that you could ssh to other boxes within your local net to check connectivity. You would've easily seen that you could connect to local machines but not in the internet. And then you would've remember about your firewall. And you would've of wasted yours on this crap. You're an idiot

Anonymous said...

The above two comments are disgusting and should be erased. Anonymously calling a stranger "an idiot" is shameful. Those tow anonymous guys should tray and cure their inferiority complexes.