when a catalog is being processed by the client, just ignore
empty llogs, do not try to clean them as the client has no
direct access to the storage.
Signed-off-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Change-Id: Ida933d44475fd392fe3db96bcdd4a05076b63881
Reviewed-on: http://review.whamcloud.com/13414
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: wangdi <di.wang@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
}
/* clean old empty llogs, do not consider current llog in use */
+ /* ignore remote (lgh_obj=NULL) llogs */
hdr = llh->lgh_hdr;
if ((hdr->llh_flags & LLOG_F_ZAP_WHEN_EMPTY) &&
- hdr->llh_count == 1 &&
+ hdr->llh_count == 1 && cat_llh->lgh_obj != NULL &&
llh != cat_llh->u.chd.chd_current_log) {
rc = llog_destroy(env, llh);
if (rc)