X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Ftests%2Facl%2Fpermissions.test;h=6fc47b3a6dd4276c7181c7781549805c4679ecce;hp=17f696efabb6acefb697fdabaef6218ad4621fc4;hb=a52819c3f77022ca931cac47de68d46d160ff0aa;hpb=0c36574b5bb9d52e5d5c62f3f8c08977553b143c;ds=sidebyside diff --git a/lustre/tests/acl/permissions.test b/lustre/tests/acl/permissions.test index 17f696e..6fc47b3 100644 --- a/lustre/tests/acl/permissions.test +++ b/lustre/tests/acl/permissions.test @@ -20,7 +20,7 @@ defined permissions. $ cd d $ umask 027 $ touch f - $ ls -l f | awk -- '{ print $1, $3, $4 }' + $ ls -l f | awk -- '{sub(/\\./, "", $1); print $1, $3, $4 }' > -rw-r----- root root @@ -40,7 +40,7 @@ Now, change the ownership of the file to bin:bin and verify that this gives user bin write access. $ chown bin:bin f - $ ls -l f | awk -- '{ print $1, $3, $4 }' + $ ls -l f | awk -- '{sub(/\\./, "", $1); print $1, $3, $4 }' > -rw-r----- bin bin $ su bin $ echo bin >> f @@ -200,8 +200,13 @@ only need to verify that ACL permissions make a difference. $ su bin $ echo e/* > e/h - $ echo i > e/i - > e/i: Permission denied +following 2 lines seems not valid, which also failed on ext3 in FC3 enviroment, +although it pass in FC2. commented out by CFS (agreed with HP) +Replaced "echo" with "touch" can resolve such problem. +# $ echo i > e/i +# > e/i: Permission denied + $ touch e/i 2>&1 | sed -e "s/touch .*e\\/i.*:/touch \\'e\\/i\\':/" + > touch: cannot touch 'e/i': Permission denied $ su $ setfacl -m u:bin:rwx e @@ -257,12 +262,12 @@ directories if the file has an ACL and only CAP_FOWNER would grant them. $ mkdir -m 600 x $ chown daemon:daemon x $ echo j > x/j - $ ls -l x/j | awk -- '{ print $1, $3, $4 }' + $ ls -l x/j | awk -- '{sub(/\\./, "", $1); print $1, $3, $4 }' > -rw-r----- root root $ setfacl -m u:daemon:r x - $ ls -l x/j | awk -- '{ print $1, $3, $4 }' + $ ls -l x/j | awk -- '{sub(/\\./, "", $1); print $1, $3, $4 }' > -rw-r----- root root (With the bug this gives: `ls: x/j: Permission denied'.)