67 lines
2.3 KiB
Diff
67 lines
2.3 KiB
Diff
WHATS_NEW | 4 ++++
|
|
lib/activate/activate.c | 5 +++++
|
|
lib/activate/activate.h | 2 ++
|
|
lib/metadata/lv_manip.c | 6 ++++++
|
|
4 files changed, 17 insertions(+)
|
|
|
|
diff --git a/WHATS_NEW b/WHATS_NEW
|
|
index 3953c7e..c8f869c 100644
|
|
--- a/WHATS_NEW
|
|
+++ b/WHATS_NEW
|
|
@@ -1,5 +1,9 @@
|
|
Version 2.03.12 -
|
|
===================================
|
|
+ Check if lvcreate passes read_only_volume_list with tags and skips zeroing.
|
|
+ Limit pool metadata spare to 16GiB.
|
|
+ Improves conversion and allocation of pool metadata.
|
|
+ Support thin pool metadata 15.88GiB, adds 64MiB, thin_pool_crop_metadata=0.
|
|
Fix problem with wiping of converted LVs.
|
|
Fix memleak in scanning (2.03.11).
|
|
Fix corner case allocation for thin-pools.
|
|
diff --git a/lib/activate/activate.c b/lib/activate/activate.c
|
|
index 7ed6441..de866fb 100644
|
|
--- a/lib/activate/activate.c
|
|
+++ b/lib/activate/activate.c
|
|
@@ -466,6 +466,11 @@ static int _passes_readonly_filter(struct cmd_context *cmd,
|
|
return _lv_passes_volumes_filter(cmd, lv, cn, activation_read_only_volume_list_CFG);
|
|
}
|
|
|
|
+int lv_passes_readonly_filter(const struct logical_volume *lv)
|
|
+{
|
|
+ return _passes_readonly_filter(lv->vg->cmd, lv);
|
|
+}
|
|
+
|
|
int library_version(char *version, size_t size)
|
|
{
|
|
if (!activation())
|
|
diff --git a/lib/activate/activate.h b/lib/activate/activate.h
|
|
index 3f4d128..53c8631 100644
|
|
--- a/lib/activate/activate.h
|
|
+++ b/lib/activate/activate.h
|
|
@@ -208,6 +208,8 @@ int lvs_in_vg_opened(const struct volume_group *vg);
|
|
|
|
int lv_is_active(const struct logical_volume *lv);
|
|
|
|
+int lv_passes_readonly_filter(const struct logical_volume *lv);
|
|
+
|
|
/* Check is any component LV is active */
|
|
const struct logical_volume *lv_component_is_active(const struct logical_volume *lv);
|
|
const struct logical_volume *lv_holder_is_active(const struct logical_volume *lv);
|
|
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
|
|
index 445c4ad..5ff64a3 100644
|
|
--- a/lib/metadata/lv_manip.c
|
|
+++ b/lib/metadata/lv_manip.c
|
|
@@ -7976,6 +7976,12 @@ static int _should_wipe_lv(struct lvcreate_params *lp,
|
|
first_seg(first_seg(lv)->pool_lv)->zero_new_blocks))
|
|
return 0;
|
|
|
|
+ if (warn && (lv_passes_readonly_filter(lv))) {
|
|
+ log_warn("WARNING: Read-only activated logical volume %s not zeroed.",
|
|
+ display_lvname(lv));
|
|
+ return 0;
|
|
+ }
|
|
+
|
|
/* Cannot zero read-only volume */
|
|
if ((lv->status & LVM_WRITE) &&
|
|
(lp->zero || lp->wipe_signatures))
|