OPTION(osd_scrub_sleep, OPT_FLOAT, 0) // sleep between [deep]scrub ops
OPTION(osd_deep_scrub_interval, OPT_FLOAT, 60*60*24*7) // once a week
OPTION(osd_deep_scrub_stride, OPT_INT, 524288)
+OPTION(osd_deep_scrub_update_digest_min_age, OPT_INT, 2*60*60) // objects must be this old (seconds) before we update the whole-object digest on scrub
OPTION(osd_scan_list_ping_tp_interval, OPT_U64, 100)
OPTION(osd_auto_weight, OPT_BOOL, false)
OPTION(osd_class_dir, OPT_STR, CEPH_LIBDIR "/rados-classes") // where rados plugins are stored
map<hobject_t,ScrubMap::object>::const_iterator i;
map<pg_shard_t, ScrubMap *>::const_iterator j;
set<hobject_t> master_set;
+ utime_t now = ceph_clock_now(NULL);
// Construct master set
for (j = maps.begin(); j != maps.end(); ++j) {
if (okseed &&
auth_object.digest_present && auth_object.omap_digest_present &&
(!auth_oi.is_data_digest() || !auth_oi.is_omap_digest())) {
- dout(20) << __func__ << " noting missing digest on " << *k << dendl;
- missing_digest[*k] = make_pair(auth_object.digest,
- auth_object.omap_digest);
+ utime_t age = now - auth_oi.local_mtime;
+ if (age > g_conf->osd_deep_scrub_update_digest_min_age) {
+ dout(20) << __func__ << " noting missing digest on " << *k << dendl;
+ missing_digest[*k] = make_pair(auth_object.digest,
+ auth_object.omap_digest);
+ } else {
+ dout(20) << __func__ << " missing digest but age " << age
+ << " < " << g_conf->osd_deep_scrub_update_digest_min_age
+ << " on " << *k << dendl;
+ }
}
-
}
}