Whamcloud - gitweb
LU-10268 lfsck: postpone lfsck start until initialized 59/30259/5 59/30259/6
authorFan Yong <fan.yong@intel.com>
Thu, 7 Dec 2017 07:29:35 +0000 (15:29 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Sun, 17 Dec 2017 06:18:59 +0000 (06:18 +0000)
commitf95ee72ab6ecffdaf6dd4f0202d954dfc45d0ba1
treefe3fe82a600a4eac7cee77e12b782174be2fee65
parent4f50273a3ed89bc00d5f36fc2606cc40680f450f
LU-10268 lfsck: postpone lfsck start until initialized

Sometimes, the LFSCK start request may comes (from remote server)
before local target initialized. If we start the LFSCK right away
on current server, the LFSCK engine may access NULL pointer, such
as lookup FID with NULL 'ss_server_fld'.

To avoid such trouble, start LFSCK logic will return -EINPROGRESS
to the request sponsor. It is the sponsor duty to retry the start
request some time later.

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