Add protectional internall error whenever we spot activation
of 'exclusive' only segments in 'non-exclusive' mode.
TODO: possibly the activation locking could be enhanced to handle
this fully behind the scene - as for now this works purely for
lvchange/vgchange activation.
Version 2.02.178 -
=====================================
+ Avoid non-exclusive activation of exclusive segment types.
Fix trimming sibling PVs when doing a pvmove of raid subLVs.
Preserve exclusive activation during thin snaphost merge.
Suppress some repeated reads of the same disk data at the device layer.
struct lvinfo info;
int r = 0;
+ if (!laopts->exclusive &&
+ (lv_is_origin(lv) ||
+ lv_is_pvmove(lv) ||
+ seg_only_exclusive(first_seg(lv)))) {
+ log_error(INTERNAL_ERROR "Trying non-exlusive activation of %s with "
+ "a volume type %s requiring exclusive activation.",
+ display_lvname(lv), lvseg_name(first_seg(lv)));
+ return 0;
+ }
+
if (!activation())
return 1;