X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Ftests%2Facl%2Fpermissions.test;h=6fc47b3a6dd4276c7181c7781549805c4679ecce;hp=bcf947cb0ebddd5248204a9c1aa9f156e11f2823;hb=a52819c3f77022ca931cac47de68d46d160ff0aa;hpb=770725e676ad5c378705a3c678105523cc80a12c diff --git a/lustre/tests/acl/permissions.test b/lustre/tests/acl/permissions.test index bcf947c..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 @@ -202,8 +202,11 @@ only need to verify that ACL permissions make a difference. > e/h 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 @@ -259,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'.)