Whamcloud - gitweb
LU-8151 obd: Show correct shadow mountpoints for server 31/47131/14
authorArshad Hussain <arshad.hussain@aeoncomputing.com>
Tue, 3 May 2022 08:27:09 +0000 (04:27 -0400)
committerOleg Drokin <green@whamcloud.com>
Tue, 8 Nov 2022 08:52:10 +0000 (08:52 +0000)
commit0171801df517988b0eb1023378c2c8c07a0a36f1
tree91bfde0e2a8cebb3610573ddb50db77f6fd950ae
parent26e765e0d23ba37577775331ac77ec857affd845
LU-8151 obd: Show correct shadow mountpoints for server

server_fill_super_common() preps the server for mounting
and forces "Read only" (SB_RDONLY) flag to restrict IO on
the server. This when running the mount command reflects
FS always as "ro" although they are "rw"

This patch double checks the obd statfs (FS) state for
"read only" flag (OS_STATFS_READONLY) and if not found
to be really "read only" toggles (removes) SB_RDONLY flag.

The client output remains unchanged.

Output before patch:
/dev/.../mds1_flakey on /mnt/lustre-mds1 type lustre (ro,svname=...)
/dev/.../ost1_flakey on /mnt/lustre-ost1 type lustre (ro,svname=...)

Output after patch:
/dev/.../mds1_flakey on /mnt/lustre-mds1 type lustre (rw,svname=...)
/dev/.../ost1_flakey on /mnt/lustre-ost1 type lustre (rw,svname=...)

Test case conf-sanity/113 added.

Test-Parameters: trivial fstype=zfs testlist=conf-sanity
Signed-off-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Change-Id: Ie92a686ae97dd62885f415b453bad6bdc0ed3d28
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/47131
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/target/tgt_mount.c
lustre/tests/conf-sanity.sh