I had a working EC2 ubuntu instance (t1.micro) connected through an elastic IP, using an Amazon key pair for a passwordless ssh connection. After running fsck like the terminal suggested (wrong move, I know now), the system rebooted and I keep getting "Network Error: Connection Refused" when trying to connect via ssh. I managed to attach the instance's volume to an alternative instance, but I could not see what was wrong. I also tried "ssh -vvv" from an Ubuntu laptop, but got no useful output. Is there a log I can look at to see why ssh is refusing my connection? Is there an alternative way I could debug this?
Asked
Active
Viewed 2,242 times
1 Answers
1
It sounds like you did everything right. Did you do an fsck while the volume was mounted from another instance? Perhaps there's just something wrong with the filesystem.
Apparently there's a ec2-get-console-output command now: http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ec2-clt.pdf
I've never used it. But it if you could see the console, you'd hopefully see what's wrong.
Good luck
Ryan Babchishin
- 6,320
- 2
- 18
- 37
-
Thanks, I will try fsck from another instance, and will look for the console output. – Yuval F Aug 15 '16 at 06:16
auth.logis not interesting in this scenario because the error message you get indicate that the daemon you would connect to has not even started yet. Instead look for/var/log/messagesor/var/log/syslog. – kasperd Aug 22 '16 at 20:40