Interesting question for other distributed filesystems as well, not just
There are two calls sent in the CIFS case to get this info. One requesting
"FILE_SYSTEM_ATTRIBUTE_INFO" to get f_namelen (which presumably does not
vary so does not need to be requeried every statfs and the field length is
as is) and "FILE_SYSTEM_INFO" which returns 64 bit quantities for Total and
"Allocation Units" and then a 32 bit quantity for Sectors per Allocation
and a 32 bit quantity for bytes for sector. With big SAN based arrays of
running under some of the high end CIFS based server appliances from
EMC, NetApp etc. it would not be surprising to me to see an overflow
the 32 bit statfs fields today (mapping from the values in the
returned by the server to statfs struct on i386 clients) unless the local
about the block size. For the cifs vfs adding a statfs64 func would
be technically feasible from the protocol's perspective and pretty easy.
> 2.5 has 64bit sector_t but no statfs64() system call for
>32bit architectures. How is df supposed to report it? statfs
> uses 32bit block counts.
>The currently limit depends on the block size, the bigger your
>block size the more bytes it can report.
> You can actually access NFS servers which have more
> than 2TB of disk space. NFS uses the local write size
> as block size. When you are lucky then 0xfffffffff*wsize
> is bigger than what your NFS server reports. If not
> you get wrong results.
Senior Software Engineer
Linux Technology Center - IBM Austin
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to email@example.com
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
This archive was generated by hypermail 2b29 : Wed Oct 23 2002 - 22:00:36 EST