Date: Wed, 9 May 2001 12:40:03 -0700 (PDT) From: Garrett Wollman <wollman@khavrinen.lcs.mit.edu> To: freebsd-bugs@FreeBSD.org Subject: kern/27232: On NFSv3 mounted filesystems, stat returns st_blksize=512 Message-ID: <200105091940.f49Je3h44767@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/27232; it has been noted by GNATS. From: Garrett Wollman <wollman@khavrinen.lcs.mit.edu> To: conrad@th.physik.uni-bonn.de Cc: freebsd-gnats-submit@FreeBSD.ORG Subject: kern/27232: On NFSv3 mounted filesystems, stat returns st_blksize=512 Date: Wed, 9 May 2001 15:38:20 -0400 (EDT) <<On Wed, 9 May 2001 10:11:55 -0700 (PDT), conrad@th.physik.uni-bonn.de said: > On NFSv3 mounts, stat returns st_blksize=512 for every regular file. > This in turn is used by libc routines as a default buffer size, as it > should be the 'optimal' io blocksize. No. It should be the block size used by the underlying filesystem's block allocator, and in which the file's `st_blocks' size-on-disk is reported. While SUS describes it as a ``preferred'' block size, and the FreeBSD manual pages describe it as ``optimal ... for I/O'', the most important meaning of this field is as a multiplier of st_blocks to determine the file's size. -GAWollman -- Garrett A. Wollman | O Siem / We are all family / O Siem / We're all the same wollman@lcs.mit.edu | O Siem / The fires of freedom Opinions not those of| Dance in the burning flame MIT, LCS, CRS, or NSA| - Susan Aglukark and Chad Irschick To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200105091940.f49Je3h44767>