Whamcloud - gitweb
LU-6380 scrub: handle update_log during initial scrub 92/15192/3
authorFan Yong <fan.yong@intel.com>
Sat, 23 May 2015 14:38:02 +0000 (22:38 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Sat, 4 Jul 2015 01:34:23 +0000 (01:34 +0000)
commit342149e654cdde71b34ad0148749adc7cf9f7cfe
treee137026015f5b995341984a6686c51ff148a2be3
parent0ee3487737bd876e233213ccec4e6fca4690093e
LU-6380 scrub: handle update_log during initial scrub

The normal OI scrub will not run until recovery finished. But the
update logs (update_log, and sub-items under update_log_dir) will
be accessed during the recovery. So if the the OI mapping for the
update log cannot be handled before the recovery, then the normal
OI scrub cannot be started/resumed. To resolve above dependency,
the initial OI scrub (that will be triggered by the mount process
with sync mode before the recovery) will handle the update logs'
OI mappings in advance.

In DNE2, each MDT will have a special FID for update log, during
recovery, the failover MDT can retrieve update logs on remote MDT
by this FID, that said the FID is special and it also has to be
located globally (not local FID). So the MDT index is packed into
the FID (as f_oid), then FLD can locate the special FID. To handle
such special FIDs, OI scrub needs to know the target index.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: Iac71c20c1f1631efbe19a03e380822cead6c00d1
Reviewed-on: http://review.whamcloud.com/15192
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-ldiskfs/osd_internal.h
lustre/osd-ldiskfs/osd_scrub.c
lustre/tests/sanity-lfsck.sh
lustre/tests/sanity-scrub.sh