amd64/74811: [nfs] df, nfs mount,
negative Avail -> 32/64-bit confusion
astrodog at gmail.com
Tue Sep 18 08:28:51 PDT 2007
On 9/18/07, Astrodog <astrodog at gmail.com> wrote:
> > I cannot see how to get the correct result non-accidentally without
> > using the hack of passing negative values as large unsigned ones.
> > Passing negative values as the difference of two unsigned values works
> > with NetBSD's extension to statvfs (f_bresvd), but it doesn't work for
> > nfs because it requires an extra value which the protocol doesn't
> > support AFAIK (not far).
> > Bruce
> From the above, it doesn't appear that NFS can support negative
> values, in any reasonable way... and I suppose that saying "There are
> zero blocks avalible for non-privileged users" is accurate, when
> bavail <= 0.
> I'm going to dig through the RFCs and see if there's an otherwise
> unused or underused variable that could be used to store bresvd, for
> clients that could support it.
> Thanks for the detailed explaination,
> --- Harrison
The only thing I've found, thus far, is to hijack the "NULL" NFSv3
operation. From what I can tell, clients are expected to discard the
On clients that are supported, the returned value can be what should
be subtracted from bfree to get bavail. bavail can be handled as it is
now in the server, so non-supporting clients wouldn't see any change
in behavior, beyond a NULL nfs operation taking a few cycles longer.
Any thoughts? I'm aware that this certainly isn't proper behavior...
but I also can't find anything that actually uses the NULL return.
More information about the freebsd-fs