Whamcloud - gitweb
LU-2008 utils: make label method work with mmp enabled target
authorJian Yu <jian.yu@intel.com>
Wed, 3 Apr 2013 08:46:49 +0000 (16:46 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 8 Apr 2013 15:26:12 +0000 (11:26 -0400)
commit6b4ac8000afc1565f14ea2894cbfc73c5d424a5c
treeb33f7e548a208f9442c7d17ec32373ebce30dcfd
parent3ee0fc5b77a86a0fcb2474793a3b60224ca43934
LU-2008 utils: make label method work with mmp enabled target

Commit cfef795 introduced label methods for ldiskfs and zfs to
make mount utility update the label after the first successful
mount. However, if the MMP feature was enabled on an ldiskfs
target before mounting, running mount utility on the target
will fail at ldiskfs_label_lustre() because MMP will prevent
e2label from setting the label.

This patch fixes the above issue by using "tune2fs -f -L" to force
setting the label instead of using e2label in ldiskfs_label_lustre().

Test-Parameters: envdefinitions=SLOW=yes \
clientcount=4 osscount=2 mdscount=2 \
austeroptions=-R failover=true useiscsi=true \
testlist=mmp

Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I6af753d1d841da6493402c153a695eb07ee7ce5b
Reviewed-on: http://review.whamcloud.com/5867
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/utils/mount_utils_ldiskfs.c