[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: who owns a mount

On Tue, Mar 30, 1999 at 10:16:28AM -0800, Kenneth Scharf wrote:
> >From time to time I have tried to unmount a disk (removable disk such as
> a CD or Floppy, or Bernoulii) and gotten the message "device is busy". 
> This can happen if I am currently logged into a directory on that
> device, or if a process is using the device.  However sometimes It
> appears that the device should not be in use, yet I still get this
> message.  ps -a does not give any clue (shows no process running that
> should   be using the device).  Is there a command to show why a mounted
> device might be busy (ie: who the hell is using it?).  In my case it
> could be nfs (my removeable is mountable as a share under windows via
> samba).

The lsof (list open files) package should be able to point you in the
proper direction.  A word of warning, tho... it's VERY specific to
whichever kernel it was compiled for.  If you're not running one of
Debian's "stock" kernels, you'll probably need to compile it yourself
(if you need a quick rundown of the "debianized recompile" procedure,
let me know... it's REALLY easy, tho).

Reply to: