Re: [Question] Behaviour of directory listing in XFS with concurrent deletes

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

 



On Thu, Apr 05, 2018 at 11:53:18PM +0000, Vairavanathan, Emalayan wrote:
> Hi There,
> 
> 
> We have an application that  iterates through a large directory
> (that has around 1.2 million files)  and lists the names of all
> the files in the directory. 
> 
> Files stored in the directory could be concurrently deleted by
> another thread in the application while the application lists the
> files. 

XFS complies with Posix requirements for stable directory offsets.
i.e. that dirents don't change offset when other dirents are added
or removed. Hence sequential readdir calls will always start off at
the dirent offset the last call finished at.

However, this guarantees nothing about individual dirent state
when concurrent modifications occur between readdir calls.

> Our application can tolerate false positives when listing a
> directory. However false negatives in directory listing *cannot*
> be tolerated.
> 
> To this end could someone tell  me how directory listing in XFS
> behaves with concurrent deletes? Is it  possible to see false
> negatives ?

What's does "false-negative" mean? I don't know what your
application is trying to do, so I don't know what your failure
criteria is....

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux