Trying to unmount the CDROM
gives "...device busy
Trying to unmount the CDROM gives "...device busy". I know that this means that the CDROM directory is being accessed from one of my shells and that I should cd away from there, but which one is it? This is very annonying when you have a lot of terminal windows open or when the process that originally accessed the CDROM unexpectedly died. What we want to do in this case is to avoid having to close or check all the windows. The elegant (and fast!) way to do it is using the fuser command:
If you have the lsof command (list open files) that could be
useful too, especially in the more tricky case when you have quited every
CD directory that has been accessed and still you cannot unmount the CD.
Suppose for instance that you changed directory to the mount point of the
CD-ROM (something like cd /mnt/cdrom) and launched an application
from there (like xmixer &). Now because the initial working
directory of xmixer was the CD mount point, this last directory
is perceived as being in use by the umount command, and the message
will be
Have a Unix Problem
Unix Books :-
Return to : - Unix System Administration Hints and Tips (c) www.gotothings.com All material on this site is Copyright.
|