diff --git a/WHATS_NEW b/WHATS_NEW index f526fa82e..48984dc47 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,6 @@ Version 2.02.06 - ================================= + Use mirror's uuid for a core log. Add mirror log fault-handling policy. Improve mirror warning messages and tidy dmeventd syslog output. Propagate nosync flag around cluster. diff --git a/lib/mirror/mirrored.c b/lib/mirror/mirrored.c index c1abfb475..f9038c988 100644 --- a/lib/mirror/mirrored.c +++ b/lib/mirror/mirrored.c @@ -238,11 +238,21 @@ static int _add_log(struct dev_manager *dm, struct lv_segment *seg, (seg->lv->vg->status & CLUSTERED))) clustered = 1; - if (seg->log_lv && - !(log_dlid = build_dlid(dm, seg->log_lv->lvid.s, NULL))) { - log_error("Failed to build uuid for log LV %s.", - seg->log_lv->name); - return 0; + if (seg->log_lv) { + /* If disk log, use its UUID */ + if (!(log_dlid = build_dlid(dm, seg->log_lv->lvid.s, NULL))) { + log_error("Failed to build uuid for log LV %s.", + seg->log_lv->name); + return 0; + } + } else { + /* If core log, use mirror's UUID and set DM_CORELOG flag */ + if (!(log_dlid = build_dlid(dm, seg->lv->lvid.s, NULL))) { + log_error("Failed to build uuid for mirror LV %s.", + seg->lv->name); + return 0; + } + log_flags |= DM_CORELOG; } if (mirror_in_sync() && !(seg->status & PVMOVE))