svn commit: samba r25689 - in
ronniesahlberg at gmail.com
Thu Oct 18 07:57:14 GMT 2007
While most nfs clients (solaris,linux and bsd?) are careful and never
try to read beyond the end of file based on the end-of-file field of
the GETATTR calls,
There are some nfs clients that are "less careful" (all versions of
HPUX and at least old versions of AIX) that always read a full nfs
page/block at a time.
This is perfectly ok in the nfs spec, the server will just return
the partially requested data up to eof and have the eof flag set in
the read reply.
So if a file is reported as 5 bytes and the nfs blocksize is 8kb,
solaris, linux, bsd will do a read of only 5 bytes from offset 0
while hpux and (at least old versions of) aix will do a request to
read a full 8kb from offset.
in both cases the server will respond with 5 bytes of data and the eof flag set.
On 10/18/07, tridge at samba.org <tridge at samba.org> wrote:
> > wouldn't it be better to test with a zero file and with a non-zero one?
> > If there's a difference we should really test both.
> With current NFS v2/v3 servers and clients it will never work with a
> zero length file, as the oplock break code gets called on read or
> write, and the NFS client doesn't send any read or write requests for
> zero length files.
> With NFSv4 it can work with zero length files though, and you're right
> that we could test with both when looking for correct interaction
> between NFSv4 and CIFS.
> Cheers, Tridge
More information about the samba-technical