path: root/tests/bugs/glusterfs-server
diff options
authorSunil Kumar Acharya <>2019-11-14 09:24:26 +0530
committerSanju Rakonde <>2020-01-24 06:34:08 +0000
commit7cac693bba33cbba35a6d0bbe98d8ad5551d2134 (patch)
tree154d758a687fb8dbebd9dfd96b371b9d7b32565b /tests/bugs/glusterfs-server
parent7dc4122b84c93cfa6355002fa651a806706e4990 (diff)
tests: fix test failures for nfsnobody user and group
'nfsnobody' user and group is merged with 'nobody' user and group in RHEL8. Tests are modified to use appropriate user and group. BUG: 1756900 Change-Id: I59863da2262283b00b1cb417d3652ebe29a36407 Signed-off-by: Sunil Kumar Acharya <>
Diffstat (limited to 'tests/bugs/glusterfs-server')
1 files changed, 11 insertions, 3 deletions
diff --git a/tests/bugs/glusterfs-server/bug-887145.t b/tests/bugs/glusterfs-server/bug-887145.t
index 82f7cca..db2cf3c 100755
--- a/tests/bugs/glusterfs-server/bug-887145.t
+++ b/tests/bugs/glusterfs-server/bug-887145.t
@@ -29,7 +29,15 @@ chmod 600 $M0/file;
TEST mount_nfs $H0:/$V0 $N0 nolock;
-chown -R nfsnobody:nfsnobody $M0/dir;
+grep nfsnobody /etc/passwd > /dev/null
+if [ $? -eq 1 ]; then
+chown -R $usr:$grp $M0/dir;
chown -R tmp_user:tmp_user $M0/other;
TEST $CLI volume set $V0 server.root-squash on;
@@ -38,7 +46,7 @@ EXPECT_WITHIN $NFS_EXPORT_TIMEOUT "1" is_nfs_export_available;
# create files and directories in the root of the glusterfs and nfs mount
# which is owned by root and hence the right behavior is getting EACCESS
-# as the fops are executed as nfsnobody.
+# as the fops are executed as nfsnobody/nobody.
touch $M0/foo 2>/dev/null;
TEST [ $? -ne 0 ]
touch $N0/foo 2>/dev/null;
@@ -61,7 +69,7 @@ cat $N0/passwd 1>/dev/null;
TEST [ $? -eq 0 ]
# create files and directories should succeed as the fops are being executed
-# inside the directory owned by nfsnobody
+# inside the directory owned by nfsnobody/nobody
TEST touch $M0/dir/file;
TEST touch $N0/dir/foo;
TEST mkdir $M0/dir/new;