LU-14 utils: allow formatting OST without VIRGIN flag
When reformatting a new target to replace an existing target, the
"mkfs.lustre --replace" option allows formatting an OST (or MDT?)
with the same index as a previously used OST without setting the
LDD_F_VIRGIN flag.
This is required in the case where an OST was lost due to massive
corruption or critical hardware failure. Otherwise, the newly
formatted target will try to register with the MGS as a new target,
but will be refused by the MGS due to having an already-used index.
The OFD code skips precreating all of the objects in the filesystem
if the MDS requests an object ID too much larger than the current
LAST_ID. In this case (which can happen if the OST is replaced
or restored from an older backup) only the most recent objects are
precreated, and the deletion of orphans from a too-large precreate
is left to lfsck.
Lustre-commit:
db6613f5bed1606cc8f97b46d1b298746af03a75
Lustre-change: http://review.whamcloud.com/7443
Test-Parameters: testlist=conf-sanity envdefinitions=SLOW=yes
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Sebastien Buisson <sebastien.buisson@bull.net>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Change-Id: I5b773bd7116df4d7875ff31bdd0c873377f83116
Reviewed-on: http://review.whamcloud.com/8159
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>