今天我不能通过SSH访问我的实例,似乎所有的服务都停止了。
我决定将当前卷附加到一个新的实例来访问数据并恢复它们。 但是我无法将旧卷挂载到新实例。
这是我所做的:
安装:
mkdir /oldpartition mount /dev/xvdf2 /oldpartition
上面的代码不起作用,它会抛出mount: wrong fs type, bad option, bad superblock on /dev/xvdf2
其他信息:
fdisk -l WARNING: fdisk GPT support is currently new, and therefore in an experimental phase. Use at your own discretion. Disk /dev/xvda: 10.7 GB, 10737418240 bytes, 20971520 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk label type: gpt # Start End Size Type Name 1 2048 4095 1M BIOS boot parti 2 4096 20971486 10G Microsoft basic WARNING: fdisk GPT support is currently new, and therefore in an experimental phase. Use at your own discretion. Disk /dev/xvdf: 16.1 GB, 16106127360 bytes, 31457280 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk label type: gpt # Start End Size Type Name 1 2048 4095 1M BIOS boot parti 2 4096 31457246 15G Microsoft basic
对不起,如果这是一个愚蠢的问题,但我是一个Linux新手。
任何帮助将不胜感激,谢谢!
您需要执行以下步骤才能从停止的EC2 Linux实例中恢复数据。
1. Stop the EC2 Linux Instance 2. Detach the Root Volume 3. Launch a new Temporary Instance. We need to create a new EC2 instance with exact same settings and in the same availability zone. 4. Select same Security Group that is attached to the original instance 5. Attach the Root Volume to New Instance 6. Mount the original root volume to /mnt directory of a new temporary instance.
在开始这个练习之前,我们需要记下以下关键信息:
Instance ID, AMI ID, and Availability Zone of original Instance Name of Root Device volume such as /dev/sda1 Volume ID of Root Volume