tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: How NFS keeps state for getdents()?



On Sun, Sep 14, 2014 at 03:41:28AM +0200, Emmanuel Dreyfus wrote:
 > Retreiving a directory content through getdents() can split in multiple
 > calls. State is kept using the offset argument which tells where in the
 > directory listing buffer we want to start reading, and it is allowed to
 > use lseek() to move inside the directory listing buffer.
 > 
 > How does this handle the case when a directory entry is added or removed
 > between two getdents() calls? Is a directory listing cached and attached
 > to the file descriptor?
 > 
 > And how does this works in the NFS case? We do not even have file
 > descriptor here, just a file handle which let us retreive the vnode. 

The answer is approximately "cthulu ph'tagn". HTH

-- 
David A. Holland
dholland%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index