1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-18 10:04:20 +03:00

cmirror: do not check for cmirror availability when creating deactivated cluster mirrors

When creating cluster mirrors while they're not supposed to be activated
immediately after creation, we don't need to check for cmirrord availability.
We can just create these mirrors and let the check to be done on activation
later on. This is addendum for commit cba6186325f0d5806cf1ddec276b3bb8e178687a.
This commit is contained in:
Peter Rajnoha 2015-01-06 09:59:04 +01:00
parent cba6186325
commit 509650ec4c

View File

@ -6817,8 +6817,8 @@ static struct logical_volume *_lv_create_an_lv(struct volume_group *vg,
if (!(create_segtype = get_segtype_from_string(vg->cmd, "striped"))) if (!(create_segtype = get_segtype_from_string(vg->cmd, "striped")))
return_0; return_0;
} else if (seg_is_mirrored(lp) || seg_is_raid(lp)) { } else if (seg_is_mirrored(lp) || seg_is_raid(lp)) {
if (lp->activate != CHANGE_AEY && vg_is_clustered(vg) && if (is_change_activating(lp->activate) && (lp->activate != CHANGE_AEY) &&
seg_is_mirrored(lp) && !seg_is_raid(lp) && vg_is_clustered(vg) && seg_is_mirrored(lp) && !seg_is_raid(lp) &&
!cluster_mirror_is_available(vg->cmd)) { !cluster_mirror_is_available(vg->cmd)) {
log_error("Shared cluster mirrors are not available."); log_error("Shared cluster mirrors are not available.");
return NULL; return NULL;