Prabal Nandi
Prabal Nandi

Reputation: 141

Amazon EC2: Unable to unmount and remove EBS drive file system

I have create an EBS drive, attached it to the Instance and created file system using mkfs.ext3. Now i want to unmount and delete the drive, i've tried many things but nothing seems to work. Although i am able to detach the drive from instance and delete using EC-2 Console, but when i am checking partition using df -hk it is still showing the drive.

[ec2-user@XXXXXXXXXXXXXX ~]$ df -hk
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/xvda1             8256952   1075740   7097356  14% /
tmpfs                   304368         0    304368   0% /dev/shm
/dev/xvdf             30963708    176196  29214648   1% /media/newdrive

And more over when i try to use any other command like "fdisk -l" or and all or trying to browse the drive's folders, the putty session hangs. I am new to EC2 cloud and also to Linux.

Upvotes: 3

Views: 10348

Answers (2)

rposky
rposky

Reputation: 2256

How about this?
You need to run as:
sudo umount /dev/xvdf

Upvotes: 6

Shadja Chaudhari
Shadja Chaudhari

Reputation: 21

umount -dRf /media/newdrive

umount needs mountpoint not a devicetype like /dev/xvdf

Upvotes: 2

Related Questions