Whamcloud - gitweb
LU-10321 lfsck: not start lfsck during umount 13/30513/2
authorFan Yong <fan.yong@intel.com>
Wed, 13 Dec 2017 05:35:39 +0000 (13:35 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 4 Jan 2018 02:48:11 +0000 (02:48 +0000)
commit0cabe06be1fcc6c3ff690889b1e86bbe4690b854
tree2d1f43cb6029ed8edbba8a92c8e80f08c76939d3
parent9c9a05fee6c0fce557dfa578ff7116b905d4e00a
LU-10321 lfsck: not start lfsck during umount

There is race condition bewtween lfsck_start and umount:
the LFSCK may be triggered just after the LFSCK stopped
during umount the target, then nobody will stop the new
started LFSCK, as to the umount may be blocked.

This patch sets flag on the lfsck instance when umount
that will prevent subsequent lfsck_start.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I779f862d4195d4289bb9dd96575cd7746ac4b35b
Reviewed-on: https://review.whamcloud.com/30513
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/lfsck/lfsck_internal.h
lustre/lfsck/lfsck_lib.c