Whamcloud - gitweb
LU-6033 tests: inject failure before counting the objects 98/13098/4
authorFan Yong <fan.yong@intel.com>
Thu, 9 Oct 2014 09:36:11 +0000 (17:36 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 29 Dec 2014 17:21:12 +0000 (17:21 +0000)
commit93452566b13360c76852b3d7ae3daa08912925f4
treefc0a4057138582f88c0a68aa1a793ac48d8fa2e0
parentfabd01968d0fac83e4855da5a5dfe8f68c038ceb
LU-6033 tests: inject failure before counting the objects

Some test cases need to inject some failure stub on OST that will
be triggered when creating the OST objects. For that, we need to
calculate how many objects to be created to guarantee that all the
pre-created OST-objects on the MDT can be exhausted. Under some
race cases, the MDT may be in pre-creating OST-objects and finished
the pre-creation just after the precreated_ost_obj_count() returning
zero to the caller but before the caller injecting the failure stub
on the OST. Then the subsequent failure injection will be useless.
To resolve such trouble, the caller of precreated_ost_obj_count()
should inject related failure stub before calculating the pre-created
OST-objects count.

Signed-off-by: Fan Yong <fan.yong@intel.com>
Change-Id: I01c98c0eb67aa0974c3223356557ae76f23ddb77
Reviewed-on: http://review.whamcloud.com/13098
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Bobi Jam <bobijam@hotmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/sanity-lfsck.sh
lustre/tests/sanity-scrub.sh
lustre/tests/test-framework.sh