Subject: Re: problems unmounting an apparently non-busy filesystem
To: NetBSD-current Discussion List <current-users@NetBSD.ORG>
From: Greg A. Woods <woods@weird.com>
List: current-users
Date: 04/09/2001 17:36:20
[ On , April 9, 2001 at 13:20:23 (-0700), Chris G. Demetriou wrote: ]
> Subject: Re: problems unmounting an apparently non-busy filesystem
>
> woods@weird.com (Greg A. Woods) writes:
> > [ On , April 9, 2001 at 13:06:40 (-0700), Chris G. Demetriou wrote: ]
> > > Subject: Re: problems unmounting an apparently non-busy filesystem
> > >
> > > For things like this, i often find that a culprit is a device alias.
> > 
> > Indeed there's been a full /altroot/dev directory on that partition, however
> 
> however what?  8-)

nothing's supposed to be using that directory....   :-)

> usually, when i recognize the symptoms (basically, a vnd that i just
> created and populated has a busy file system when i bloody well _know_
> that it shouldn't be busy), i just umount -f the file system.
> 
> "pstat -v" may help.

Ah ha!  I hadn't used "pstat -v" in some time and forgot that it would
sort by device:

	*** MOUNT ffs /dev/sd1a on /altroot (local)
	ADDR     TYP VFLAG  USE HOLD TAG FILEID IFLAG RDEV|SZ
	d0a8a380 dir     R    0    1   1      2     -     512
	d0ab56f4 non     O    1    0  21
	d0be2ac8 reg     -    4    0   1  61969     -  445249
	d0be2180 reg     -    4    0   1  62294     -    8538
	d0a2a990 reg     -    4    0   1  64801     -   53248

Now silly me I've done an "rm -rf *" in there already because the reason
I'd wanted to unmount it was to do a newfs, so now I can't find those
inode numbers any more....

However the use count of '4' makes it sound suspiciously like one of the
NFS processes still has some reference even though I've "un-exported"
the filesystem and restarted mountd.

THANKS!

I guess I'll just have to reboot to see if they stay away....  :-)

(or if anything really was legitimately using it)

(but not right away.... other things to do first....)

-- 
							Greg A. Woods

+1 416 218-0098      VE3TCP      <gwoods@acm.org>     <woods@robohack.ca>
Planix, Inc. <woods@planix.com>;   Secrets of the Weird <woods@weird.com>