Default acls disappearing on ext2/ext3 - script to reproduce included

"Jochen Tuchbreiter" <[email protected]> Tue, 18 Jan 2005 15:01:05 +0100
Newsgroups gmane.linux.file-systems.acl.devel
Message-ID <[email protected]>
Hello,

after using the default-attribute for acls on directories for a while I
noticed that those entries seemed to randomly disappear. An entry that
looked this way:


# file: acltest/test/1/1
# owner: root
# group: root
user::rwx
group::---
group:apache:r-x
mask::r-x
other::---
default:user::rwx
default:group::---
default:group:apache:r-x
default:mask::r-x
default:other::---


sometimes came out looking this way (esp after a reboot):

# file: acltest/test/1/1
# owner: root
# group: root
user::rwx
group::---
group:apache:r-x
mask::r-x
other::---


As this problem has also been spotted before
(http://www.linuxforum.com/forums/index.php?showtopic=94525) but the person
reporting it was unable to provide a script for reproduction I thought that
I'd look for a way to reproduce this. I can now reproduce it easily on my
system on vanilla 2.6.10 and 2.4.28 with the latest acls patches enabled.
The problem only occurs with ext2 and ext3, when I run the script on an xfs
partition it works just fine. (-> Maybe this is a problem of ext2/3 extended
attributes?)

To reproduce you can download a package for this on
http://flachtaucher.de/aclbreak.tar.gz . It contains three files:

acltest.sh - Shell-Script that provokes the problem, you must edit it before
execution
aclcheck.pl - Tool for recurively checking if acls exist on a directory
acltest_root.tgz - Some random files (copy of GPL'ed "gallery" PHP-Script)

In order to reproduce this you need a free partition that can be used. Attn:
All contents on this partition will be destroyed. The script will create a
directory /acltest and mount the partition there. The script only runs if
user and group "daemon" exist. 

Edit acltest.sh and configure the partition you want to use. cd into the
directory containing acltest.sh. Run sh ./actltest.sh as root.

This will create a fs on the selected partition, create a directory with
default-acls and then create serveral directories below this. It will fill
the directories with data from the tgz. It will then show you four
getfacl-outputs BEFORE umounting the partition. It will then umount,mount
and show you getfacl-outputs for the same directories again. These will
hopefully differ although it should not. In addition to this the perl script
will be run and should list all directories that do not have default-entries
(should only be " " and /lost+found, nothing more).

This way of reproduction works every time for me, if you can not reproduce
please let me know so that I can provide you with a machine for testing.

If there is anything else I can do to help you fix this please let me know.


best regards,
Jochen

_______________________________________________
acl-devel mailing list
[email protected]
http://acl.bestbits.at/mailman/listinfo/acl-devel