AWS SSH into EC2 server timing out












-1















About 6 months ago I created an AWS EC2 instance to mess around with on the free tier. After months of having no issues remoting into my AWS EC2 server, I've recently been unable to access it via SSH. I am using the following command:



ssh -i my-key-pair.pem ec2-user@ec2-**-**-***-***.us-****-*.compute.amazonaws.com


...and after a minute or two, am getting this response



ssh: connect to host ec2-**-**-***-***.us-****-*.compute.amazonaws.com port 22: Operation timed out


What's strange is that



1) I can read and write to my RDS database just fine



2) I can ping into the server



3) My port 22 is open



4) The instance is running and healthy



5) In the Inbound section of the security group of the EC2 server it allows for all traffic and SSH from any location via port 22.



6) I'm using the same key-pair as always



I went through this documentation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) and can confirm that the VPC, subnet, network ACL and route tables all line up (I haven't changed anything with those since the SSH stopped working). Any insight would be extremely helpful!










share|improve this question























  • Did you consider speaking with AWS support?

    – mustaccio
    Nov 23 '18 at 23:29
















-1















About 6 months ago I created an AWS EC2 instance to mess around with on the free tier. After months of having no issues remoting into my AWS EC2 server, I've recently been unable to access it via SSH. I am using the following command:



ssh -i my-key-pair.pem ec2-user@ec2-**-**-***-***.us-****-*.compute.amazonaws.com


...and after a minute or two, am getting this response



ssh: connect to host ec2-**-**-***-***.us-****-*.compute.amazonaws.com port 22: Operation timed out


What's strange is that



1) I can read and write to my RDS database just fine



2) I can ping into the server



3) My port 22 is open



4) The instance is running and healthy



5) In the Inbound section of the security group of the EC2 server it allows for all traffic and SSH from any location via port 22.



6) I'm using the same key-pair as always



I went through this documentation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) and can confirm that the VPC, subnet, network ACL and route tables all line up (I haven't changed anything with those since the SSH stopped working). Any insight would be extremely helpful!










share|improve this question























  • Did you consider speaking with AWS support?

    – mustaccio
    Nov 23 '18 at 23:29














-1












-1








-1








About 6 months ago I created an AWS EC2 instance to mess around with on the free tier. After months of having no issues remoting into my AWS EC2 server, I've recently been unable to access it via SSH. I am using the following command:



ssh -i my-key-pair.pem ec2-user@ec2-**-**-***-***.us-****-*.compute.amazonaws.com


...and after a minute or two, am getting this response



ssh: connect to host ec2-**-**-***-***.us-****-*.compute.amazonaws.com port 22: Operation timed out


What's strange is that



1) I can read and write to my RDS database just fine



2) I can ping into the server



3) My port 22 is open



4) The instance is running and healthy



5) In the Inbound section of the security group of the EC2 server it allows for all traffic and SSH from any location via port 22.



6) I'm using the same key-pair as always



I went through this documentation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) and can confirm that the VPC, subnet, network ACL and route tables all line up (I haven't changed anything with those since the SSH stopped working). Any insight would be extremely helpful!










share|improve this question














About 6 months ago I created an AWS EC2 instance to mess around with on the free tier. After months of having no issues remoting into my AWS EC2 server, I've recently been unable to access it via SSH. I am using the following command:



ssh -i my-key-pair.pem ec2-user@ec2-**-**-***-***.us-****-*.compute.amazonaws.com


...and after a minute or two, am getting this response



ssh: connect to host ec2-**-**-***-***.us-****-*.compute.amazonaws.com port 22: Operation timed out


What's strange is that



1) I can read and write to my RDS database just fine



2) I can ping into the server



3) My port 22 is open



4) The instance is running and healthy



5) In the Inbound section of the security group of the EC2 server it allows for all traffic and SSH from any location via port 22.



6) I'm using the same key-pair as always



I went through this documentation (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/TroubleshootingInstancesConnecting.html) and can confirm that the VPC, subnet, network ACL and route tables all line up (I haven't changed anything with those since the SSH stopped working). Any insight would be extremely helpful!







amazon-web-services networking amazon-ec2 ssh






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Nov 23 '18 at 20:45









Saints14Saints14

1




1













  • Did you consider speaking with AWS support?

    – mustaccio
    Nov 23 '18 at 23:29



















  • Did you consider speaking with AWS support?

    – mustaccio
    Nov 23 '18 at 23:29

















Did you consider speaking with AWS support?

– mustaccio
Nov 23 '18 at 23:29





Did you consider speaking with AWS support?

– mustaccio
Nov 23 '18 at 23:29












1 Answer
1






active

oldest

votes


















-1















  • Sometimes the instance fails, you can check the screen of it via AWS
    console.

  • Run another instance in the same security group and try to
    connect to it and then from there to your original one - to verify if
    ssh is still open (even if you do not have the ssh key, the error
    will not be 'timeout')

  • You can create a snapshot of your instance and
    attach it as another volume in a new one and you can investigate
    logs, maybe something went wrong.

  • You can restart the instance, if
    for example i ran out of memory it will most likely work after the
    reboot (hopefully for a long enough time for you to investigate).

  • You can contact AWS support.






share|improve this answer























    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53452764%2faws-ssh-into-ec2-server-timing-out%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    -1















    • Sometimes the instance fails, you can check the screen of it via AWS
      console.

    • Run another instance in the same security group and try to
      connect to it and then from there to your original one - to verify if
      ssh is still open (even if you do not have the ssh key, the error
      will not be 'timeout')

    • You can create a snapshot of your instance and
      attach it as another volume in a new one and you can investigate
      logs, maybe something went wrong.

    • You can restart the instance, if
      for example i ran out of memory it will most likely work after the
      reboot (hopefully for a long enough time for you to investigate).

    • You can contact AWS support.






    share|improve this answer




























      -1















      • Sometimes the instance fails, you can check the screen of it via AWS
        console.

      • Run another instance in the same security group and try to
        connect to it and then from there to your original one - to verify if
        ssh is still open (even if you do not have the ssh key, the error
        will not be 'timeout')

      • You can create a snapshot of your instance and
        attach it as another volume in a new one and you can investigate
        logs, maybe something went wrong.

      • You can restart the instance, if
        for example i ran out of memory it will most likely work after the
        reboot (hopefully for a long enough time for you to investigate).

      • You can contact AWS support.






      share|improve this answer


























        -1












        -1








        -1








        • Sometimes the instance fails, you can check the screen of it via AWS
          console.

        • Run another instance in the same security group and try to
          connect to it and then from there to your original one - to verify if
          ssh is still open (even if you do not have the ssh key, the error
          will not be 'timeout')

        • You can create a snapshot of your instance and
          attach it as another volume in a new one and you can investigate
          logs, maybe something went wrong.

        • You can restart the instance, if
          for example i ran out of memory it will most likely work after the
          reboot (hopefully for a long enough time for you to investigate).

        • You can contact AWS support.






        share|improve this answer














        • Sometimes the instance fails, you can check the screen of it via AWS
          console.

        • Run another instance in the same security group and try to
          connect to it and then from there to your original one - to verify if
          ssh is still open (even if you do not have the ssh key, the error
          will not be 'timeout')

        • You can create a snapshot of your instance and
          attach it as another volume in a new one and you can investigate
          logs, maybe something went wrong.

        • You can restart the instance, if
          for example i ran out of memory it will most likely work after the
          reboot (hopefully for a long enough time for you to investigate).

        • You can contact AWS support.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Nov 24 '18 at 12:46









        petrchpetrch

        31626




        31626






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53452764%2faws-ssh-into-ec2-server-timing-out%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Berounka

            Sphinx de Gizeh

            Different font size/position of beamer's navigation symbols template's content depending on regular/plain...