So, one of these days, you will find yourself wanting to unmount a partition on your linux box. Problem is, most of the time, the partition is most likely still being used by some process, or by someone. So first, you need to find out which processes are keeping the drive busy, by:



root@Mach5-NX:~# fuser -m /media/prison
/media/prison__:      3196c  3285c
root@Mach5-NX:~# ps -ef | grep 3285
ikhsan    3285  3196  0 07:07 pts/1    00:00:00 vi lgf.conf

With that information in hand, you can start shutting down services, or killing the process that’s preventing you from unmounting the partititon:

root@Mach5-NX:~# kill 3285

Repeat the step above for each process listed on the previous command.

Or, if you’re feeling nasty, you can always kill all the process that’s using the partition, by issuing:

root@Mach5-NX:~# fuser -km /media/prison
/media/prison__:      3350c  3437c

Unmount the drive normally

root@Mach5-NX:~# umount /media/prison

…And we’re done 🙂

By ikhsan

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.