[Gluster-devel] metadata race confition (was: ename(2) race condition)

Emmanuel Dreyfus manu at netbsd.org
Tue May 22 08:16:06 UTC 2012

On Mon, May 21, 2012 at 10:44:30PM -0700, Anand Avati wrote:
> Even in the case where bugc1.txt got a wrong uid returned (assuming so), it
> should not influence the permissibility of it getting deleted. The
> deletability of a file is based on the permissions on the parent directory
> and not the ownership of the file (unless +t sticky bit was set on the
> directory).

This is interesting: I get the behavior you describe on Linux (ext2fs),
but NetBSD (FFS) hehaves differently (these are native test, without
glusterfs). Is it a grey area in standards?

$ ls -la test/ 
total 16
drwxr-xr-x   2 root  wheel   512 May 22 10:10 .
drwxr-xr-x  19 manu  wheel  5632 May 22 10:10 ..
-rw-r--r--   1 manu  wheel     0 May 22 10:10 toto
$ whoami
$ rm -f test/toto
rm: test/toto: Permission denied
$ uname  -sr 

Emmanuel Dreyfus
manu at netbsd.org

More information about the Gluster-devel mailing list