Mounting Old EBS Volume to the new Instance

1) I had an instance and sudo commands were not working do to some mistakes on this instance so i had to create a new instance.

2) I want to use old EBS volume with new instance and to stop old instance.

3) I created a new instance (New EBS Volume is created automatically with new instance)

4) I created snapshot of old volume and attached with new instance.

5) So two EBS volumes are attached with new instance.

6) When i login using SSH into new instance, i don't see old data anywhere.

7) I want every old data on new instance.


my question is..... how i can use old volume with new instance?

please help me.. i am trying it from last 10 hours continuously :(..


What you need to do is mount the old volume on the new instance. Go to the Amazon EC2 control panel, and click "Volumes" (under Elastic Block Store). Look at the attachment information for the old EBS volume. This will be something like <instance id> (<instance name>):/dev/sdg

Make a note of the path given here, so that'd be /dev/sdg in the example above. Then use SSH and connect to your new instance, and type mkdir /mnt/oldvolume and then mount /dev/sdg /mnt/oldvolume (or whatever the path given in the control panel was). Your files should now be available under /mnt/oldvolume . If this does not solve your problem, please post again with the output of your df command after doing all of this.

So, to recap, to use an EBS volume on an instance, you need to attach it to that instance using the control panel (or API tools), and then mount it on the instance itself.

链接地址: http://www.djcxy.com/p/57654.html

上一篇: java.lang.Thread本身是一个线程

下一篇: 将旧EBS卷挂载到新实例