Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Sep 2010 20:23:06 +0300
From:      Andriy Gapon <avg@icyb.net.ua>
To:        freebsd-fs@FreeBSD.ORG, Jeremy Chadwick <freebsd@jdc.parodius.com>, Andriy Gapon <avg@icyb.net.ua>, Oliver Fromme <olli@lurza.secnetix.de>
Subject:   Re: Strange ZFS problem, filesystem claims to be full when clearly not full
Message-ID:  <4CA4C77A.2030807@icyb.net.ua>
In-Reply-To: <201009301707.o8UH7xAs026168@lurza.secnetix.de>
References:  <201009301707.o8UH7xAs026168@lurza.secnetix.de>

next in thread | previous in thread | raw e-mail | index | archive | help
on 30/09/2010 20:07 Oliver Fromme said the following:
> Last time I had a try at fstat(1), it wasn't able to print
> actual file names, while lsof was able to do it.  That's
> why I generally prefer lsof over fstat(1).  For most of my
> needs fstat(1) is useless if it can't display file names.
> (I think DragonFly's fstat(1) can do it, FWIW.)

Point taken.
However fstat still does print inode numbers.

> Of course, in this particular case it might be irrelevant
> because the files in questions don't have names anymore.

Right.

> On the other hand, I'm not sure how to use fstat(1) to
> identify files with link count zero ...  I'm looking at
> the manpage, but maybe it's just too late in the evening.
> What command line would you suggest, exactly?  At least
> it doesn't seem to be as easy as "lsof +L1".

Well, I am believer in a Unix way - each tool for its own small job, combine the
tools to get a big job done.  One tool that does all with a million obscure
options does not appeal to me.  But that's me.

And in this particular case what you ask is irrelevant.
We just need to find all processes having opened files on a particular filesystem.

-- 
Andriy Gapon



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4CA4C77A.2030807>