It appears that if we think MDS asked us to delete too many
precreate objects (more than 2 MAX_PRECREATE counts)
then we don't do the precreation, but do not let MDS know it needs
to advance the last_id forward by quite a bit.
This lead to reassigning these objects to other files after recovery.
Change-Id: Icbd5b9e3cd81129f56ee5cd3aafd5f418affbecc
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/12067
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
CDEBUG(D_HA, "ofd_last_id() = "LPU64" -> diff = %d\n",
ofd_seq_last_oid(oseq), diff);
if (-diff > OST_MAX_PRECREATE) {
- /* FIXME: should reset precreate_next_id on MDS */
+ /* Let MDS know that we are so far ahead. */
+ ostid_set_id(&rep_oa->o_oi, ofd_seq_last_oid(oseq) + 1);
rc = 0;
} else if (diff < 0) {
rc = ofd_orphans_destroy(tsi->tsi_env, exp,