📁
EdmundHee
  • Edmund's How to
  • Python
    • Virtual Environment
      • Setup for Windows
      • Setup for Mac
      • How to use VirtualEnvWrapper
  • Git
    • Setup Git Environment
      • Setup Git for Windows
      • Setup Git for Mac
    • Github's How-to
      • Create a repository
      • Repository Branch
      • Update Repository
  • AWS
    • EC2
      • [Raw] EC2 - Recovery Instance
  • Web Development
    • NodeJS
Powered by GitBook
On this page

Was this helpful?

  1. AWS
  2. EC2

[Raw] EC2 - Recovery Instance

  • Stop Instance

  • Detach the root volume of your instance

  • Attach the volum to a rescue instance ( one which you can SSH in to). Make sure the rescue instance is in the same availability zone as your original instance.

  • Mount the root volume to a temporary mount point on the rescue instance For example: sudo mount /dev/xvdf1/mnt/recovery

  • You can see instance log messages under /mnt/recovery/var/log/ directory.

  • cd /mnt/recovery/var/log/

  • sudo cat boot.log

  • sudo cat messages

  • sudo cat dmesg

  • You can display current SSH settings

  • sudo cat /etc/ssh/sshd_config

  • sudo cat /etc/ssh/ssh_config

  • 1)To return the volume to the original instance

  • Unmount the volume.

  • sudo unmount /mnt/recovery

  • 2)Detach the volume from the recovery instance

  • 3) Remount the volume on the original instance as the root volume ( e.g /dev/sda1 )

  • 4) Start the instance

PreviousEC2NextNodeJS

Last updated 5 years ago

Was this helpful?