Merge ~paelzer/ubuntu/+source/lvm2:fix-1657646-thin-provisioning-tools-MIR-1828887-complete into ubuntu/+source/lvm2:ubuntu/eoan-devel
- Git
- lp:~paelzer/ubuntu/+source/lvm2
- fix-1657646-thin-provisioning-tools-MIR-1828887-complete
- Merge into ubuntu/eoan-devel
Status: | Merged |
---|---|
Approved by: | Christian Ehrhardt |
Approved revision: | 4d20b23c9af7252aec97b7b4509b1f35e607be52 |
Merge reported by: | Christian Ehrhardt |
Merged at revision: | 4d20b23c9af7252aec97b7b4509b1f35e607be52 |
Proposed branch: | ~paelzer/ubuntu/+source/lvm2:fix-1657646-thin-provisioning-tools-MIR-1828887-complete |
Merge into: | ubuntu/+source/lvm2:ubuntu/eoan-devel |
Diff against target: |
392 lines (+338/-2) 6 files modified
debian/changelog (+12/-0) debian/control (+3/-2) debian/patches/lp-1842436-make-generate-example-config.patch (+37/-0) debian/patches/lp-1842436-restrict-PVs-with-mixed-block-size.patch (+215/-0) debian/patches/lp-1842436-tests-allow-mixed-block-sizes.patch (+68/-0) debian/patches/series (+3/-0) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Dimitri John Ledkov (community) | Approve | ||
Canonical Server packageset reviewers | Pending | ||
Canonical Server | Pending | ||
git-ubuntu developers | Pending | ||
Review via email: mp+372393@code.launchpad.net |
Commit message
Description of the change
Christian Ehrhardt (paelzer) wrote : | # |
Christian Ehrhardt (paelzer) wrote : | # |
Christian Ehrhardt (paelzer) wrote : | # |
To ensure this is not a crazy to fix late gcc9/glibc build issue I have a PPA at
https:/
Christian Ehrhardt (paelzer) wrote : | # |
@Reviewer - the change is minimal please sponsor right away once (if) you approve
Dimitri John Ledkov (xnox) wrote : | # |
This is all good, but i would also want to take in a cherrypick from upstream to fix this: https:/
Christian Ehrhardt (paelzer) wrote : | # |
Thank Dimitri, ack to the extra fix that should go on top.
I'll add that somewhen later today.
- 903e636... by Christian Ehrhardt
-
d/p/lp-
1842436- restrict- PVs-with- mixed-block- size.patch: Avoid creation of mixed-blocksize PV on LVM volume groups (LP: #1842436) Signed-off-by: Christian Ehrhardt <email address hidden>
- 94beead... by Christian Ehrhardt
-
changelog: Avoid creation of mixed-blocksize PV on LVM volume groups (LP: #1842436)
Signed-off-by: Christian Ehrhardt <email address hidden>
Christian Ehrhardt (paelzer) wrote : | # |
Preliminary changes for these extra changes are in the MP now and building in the PPA.
Need to test it later on ...
- 6ee59e1... by Christian Ehrhardt
-
d/p/lp-
1842436- restrict- PVs-with- mixed-block- size.patch: backporting changes Signed-off-by: Christian Ehrhardt <email address hidden>
Christian Ehrhardt (paelzer) wrote : | # |
Needs to use the older dev_get_block_size, WIP and iterating on builds.
Christian Ehrhardt (paelzer) wrote : | # |
Functionally this works, I'd love to see a man page or default conf entry for it.
Will take a look for it tomorrow.
- 405b29b... by Christian Ehrhardt
-
d/p/lp-1842436-*: add self tests
Signed-off-by: Christian Ehrhardt <email address hidden>
- 5aef8fa... by Christian Ehrhardt
-
d/p/lp-1842436-*: add example config entry
Signed-off-by: Christian Ehrhardt <email address hidden>
- 139f961... by Christian Ehrhardt
-
changelog: extend 1842436 fix to multiple patches
Signed-off-by: Christian Ehrhardt <email address hidden>
Christian Ehrhardt (paelzer) wrote : | # |
Upstream generates these config snippets - lets take the respective snippet from 08396b4bce45fb8
Tests are in cd8a0133fa28a0d
On install I see the (expected) conffile prompt and the example I want in the config
# Configuration option devices/
# Allow PVs in the same VG with different logical block sizes.
# When allowed, the user is responsible to ensure that an LV is
# using PVs with matching block sizes when necessary.
- e0ff7df... by Christian Ehrhardt
-
d/control: add thin-provisioni
ng-tools build-dep as configure wants it around for some checks Signed-off-by: Christian Ehrhardt <email address hidden>
- 4d20b23... by Christian Ehrhardt
-
changelog: mention thin-provisioni
ng-tools build-dep addition Signed-off-by: Christian Ehrhardt <email address hidden>
Christian Ehrhardt (paelzer) wrote : | # |
Finally there were plenty of warnings (working fine eventually, but could easily become more required) from the configure about thin-provisioni
Since we now properly enable it lets add it as build dep as well, as configure would like to check some detaily (paths, version, ...) about it.
This gets the warnings down by 19 which won't hurt to find actual issues.
Christian Ehrhardt (paelzer) wrote : | # |
Ok, all new changes pushed.
Ready for review and sponsoring.
Dimitri John Ledkov (xnox) : | # |
Christian Ehrhardt (paelzer) wrote : | # |
This is on the bring, but I think it needs no FFe as it is really much more a fix than a feature.
Thanks for the review xnox!
Tagged and uploaded to Eoan.
Christian Ehrhardt (paelzer) wrote : | # |
This migrated, closing forgotten MP
Preview Diff
1 | diff --git a/debian/changelog b/debian/changelog |
2 | index ff71edc..c22d661 100644 |
3 | --- a/debian/changelog |
4 | +++ b/debian/changelog |
5 | @@ -1,3 +1,15 @@ |
6 | +lvm2 (2.03.02-2ubuntu6) eoan; urgency=medium |
7 | + |
8 | + * d/control: stop dropping thin-provisioning-tools to Suggests as it |
9 | + is ready to be promoted via MIR LP 1828887. Fixes usability issues |
10 | + of thin-provisioning-tools not being installed by default (LP: #1657646). |
11 | + - d/control: also add thin-provisioning-tools build-dep as configure |
12 | + wants it around for some checks at build time. |
13 | + * d/p/lp-1842436-*: Avoid creation of mixed-blocksize PV on LVM |
14 | + volume groups as it can cause FS corruption (LP: #1842436) |
15 | + |
16 | + -- Christian Ehrhardt <christian.ehrhardt@canonical.com> Fri, 06 Sep 2019 08:23:10 +0200 |
17 | + |
18 | lvm2 (2.03.02-2ubuntu5) eoan; urgency=medium |
19 | |
20 | * Detect systemd in udev rule at runtime. |
21 | diff --git a/debian/control b/debian/control |
22 | index 3d0ef7f..8dd64a8 100644 |
23 | --- a/debian/control |
24 | +++ b/debian/control |
25 | @@ -25,7 +25,8 @@ Build-Depends: |
26 | python3-dbus, |
27 | python3-pyudev, |
28 | pkg-config, |
29 | - systemd |
30 | + systemd, |
31 | + thin-provisioning-tools |
32 | Standards-Version: 4.1.1 |
33 | Homepage: http://sources.redhat.com/lvm2/ |
34 | Vcs-Git: https://salsa.debian.org/lvm-team/lvm2.git |
35 | @@ -34,7 +35,7 @@ Vcs-Browser: https://salsa.debian.org/lvm-team/lvm2 |
36 | Package: lvm2 |
37 | Architecture: linux-any |
38 | Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base, dmsetup (>= 1.02.145-2~), dmeventd |
39 | -Suggests: thin-provisioning-tools |
40 | +Recommends: thin-provisioning-tools |
41 | Conflicts: clvm |
42 | Multi-Arch: foreign |
43 | Description: Linux Logical Volume Manager |
44 | diff --git a/debian/patches/lp-1842436-make-generate-example-config.patch b/debian/patches/lp-1842436-make-generate-example-config.patch |
45 | new file mode 100644 |
46 | index 0000000..b814788 |
47 | --- /dev/null |
48 | +++ b/debian/patches/lp-1842436-make-generate-example-config.patch |
49 | @@ -0,0 +1,37 @@ |
50 | +From 08396b4bce45fb8311979250623f04ec0ddb628c Mon Sep 17 00:00:00 2001 |
51 | +From: Zdenek Kabelac <zkabelac@redhat.com> |
52 | +Date: Fri, 9 Aug 2019 12:56:28 +0200 |
53 | +Subject: [PATCH] make: generate |
54 | + |
55 | +Run make generate. |
56 | + |
57 | +Backport-Note: only take the snippet related to allow_mixed_block_sizes |
58 | +Origin: backport, https://sourceware.org/git/?p=lvm2.git;a=commit;h=08396b4bce45fb8311979250623f04ec0ddb628c |
59 | +Bug-Ubuntu: https://bugs.launchpad.net/bugs/1842436 |
60 | +Last-Update: 2019-09-10 |
61 | + |
62 | +--- |
63 | + conf/example.conf.in | 18 ++++++----- |
64 | + man/lvconvert.8_pregen | 70 +++++++++++++++++++++++------------------- |
65 | + 2 files changed, 48 insertions(+), 40 deletions(-) |
66 | + |
67 | +diff --git a/conf/example.conf.in b/conf/example.conf.in |
68 | +index 154f621bc..91ce5bec6 100644 |
69 | +--- a/conf/example.conf.in |
70 | ++++ b/conf/example.conf.in |
71 | +@@ -347,6 +347,12 @@ devices { |
72 | + # Enabling this setting allows the VG to be used as usual even with |
73 | + # uncertain devices. |
74 | + allow_changes_with_duplicate_pvs = 0 |
75 | ++ |
76 | ++ # Configuration option devices/allow_mixed_block_sizes. |
77 | ++ # Allow PVs in the same VG with different logical block sizes. |
78 | ++ # When allowed, the user is responsible to ensure that an LV is |
79 | ++ # using PVs with matching block sizes when necessary. |
80 | ++ allow_mixed_block_sizes = 0 |
81 | + } |
82 | + |
83 | + # Configuration section allocation. |
84 | +-- |
85 | +2.23.0 |
86 | + |
87 | diff --git a/debian/patches/lp-1842436-restrict-PVs-with-mixed-block-size.patch b/debian/patches/lp-1842436-restrict-PVs-with-mixed-block-size.patch |
88 | new file mode 100644 |
89 | index 0000000..06fd1ae |
90 | --- /dev/null |
91 | +++ b/debian/patches/lp-1842436-restrict-PVs-with-mixed-block-size.patch |
92 | @@ -0,0 +1,215 @@ |
93 | +From 0404539edb25e4a9d3456bb3e6b402aa2767af6b Mon Sep 17 00:00:00 2001 |
94 | +From: David Teigland <teigland@redhat.com> |
95 | +Date: Thu, 1 Aug 2019 10:06:47 -0500 |
96 | +Subject: [PATCH] vgcreate/vgextend: restrict PVs with mixed block sizes |
97 | + |
98 | +Avoid having PVs with different logical block sizes in the same VG. |
99 | +This prevents LVs from having mixed block sizes, which can produce |
100 | +file system errors. |
101 | + |
102 | +The new config setting devices/allow_mixed_block_sizes (default 0) |
103 | +can be changed to 1 to return to the unrestricted mode. |
104 | + |
105 | +Backport-Notes: |
106 | +- tools/lvmcmdline.c misses the context of the new change |
107 | +- dev_get_direct_block_sizes didn't exist, use dev_get_block_size |
108 | + |
109 | +Origin: backport, https://sourceware.org/git/?p=lvm2.git;a=commit;h=0404539edb25e4a9d3456bb3e6b402aa2767af6b |
110 | +Bug-Ubuntu: https://bugs.launchpad.net/bugs/1842436 |
111 | +Last-Update: 2019-09-09 |
112 | + |
113 | +--- |
114 | + lib/commands/toolcontext.h | 1 + |
115 | + lib/config/config_settings.h | 5 ++++ |
116 | + lib/metadata/metadata-exported.h | 1 + |
117 | + lib/metadata/metadata.c | 44 ++++++++++++++++++++++++++++++ |
118 | + tools/lvmcmdline.c | 2 ++ |
119 | + tools/toollib.c | 47 ++++++++++++++++++++++++++++++++ |
120 | + tools/vgcreate.c | 2 ++ |
121 | + 7 files changed, 102 insertions(+) |
122 | + |
123 | +--- a/lib/commands/toolcontext.h |
124 | ++++ b/lib/commands/toolcontext.h |
125 | +@@ -153,6 +153,7 @@ struct cmd_context { |
126 | + unsigned include_shared_vgs:1; /* report/display cmds can reveal lockd VGs */ |
127 | + unsigned include_active_foreign_vgs:1; /* cmd should process foreign VGs with active LVs */ |
128 | + unsigned vg_read_print_access_error:1; /* print access errors from vg_read */ |
129 | ++ unsigned allow_mixed_block_sizes:1; |
130 | + unsigned force_access_clustered:1; |
131 | + unsigned lockd_gl_disable:1; |
132 | + unsigned lockd_vg_disable:1; |
133 | +--- a/lib/config/config_settings.h |
134 | ++++ b/lib/config/config_settings.h |
135 | +@@ -448,6 +448,11 @@ cfg(devices_allow_changes_with_duplicate |
136 | + "Enabling this setting allows the VG to be used as usual even with\n" |
137 | + "uncertain devices.\n") |
138 | + |
139 | ++cfg(devices_allow_mixed_block_sizes_CFG, "allow_mixed_block_sizes", devices_CFG_SECTION, 0, CFG_TYPE_BOOL, 0, vsn(2, 3, 6), NULL, 0, NULL, |
140 | ++ "Allow PVs in the same VG with different logical block sizes.\n" |
141 | ++ "When allowed, the user is responsible to ensure that an LV is\n" |
142 | ++ "using PVs with matching block sizes when necessary.\n") |
143 | ++ |
144 | + cfg_array(allocation_cling_tag_list_CFG, "cling_tag_list", allocation_CFG_SECTION, CFG_DEFAULT_UNDEFINED, CFG_TYPE_STRING, NULL, vsn(2, 2, 77), NULL, 0, NULL, |
145 | + "Advise LVM which PVs to use when searching for new space.\n" |
146 | + "When searching for free space to extend an LV, the 'cling' allocation\n" |
147 | +--- a/lib/metadata/metadata-exported.h |
148 | ++++ b/lib/metadata/metadata-exported.h |
149 | +@@ -608,6 +608,7 @@ struct pvcreate_params { |
150 | + unsigned is_remove : 1; /* is removing PVs, not creating */ |
151 | + unsigned preserve_existing : 1; |
152 | + unsigned check_failed : 1; |
153 | ++ unsigned check_consistent_block_size : 1; |
154 | + }; |
155 | + |
156 | + struct lvresize_params { |
157 | +--- a/lib/metadata/metadata.c |
158 | ++++ b/lib/metadata/metadata.c |
159 | +@@ -669,12 +669,40 @@ int vg_extend_each_pv(struct volume_grou |
160 | + { |
161 | + struct pv_list *pvl; |
162 | + unsigned int max_phys_block_size = 0; |
163 | ++ unsigned int physical_block_size, logical_block_size; |
164 | ++ unsigned int prev_lbs = 0; |
165 | ++ int inconsistent_existing_lbs = 0; |
166 | + |
167 | + log_debug_metadata("Adding PVs to VG %s.", vg->name); |
168 | + |
169 | + if (vg_bad_status_bits(vg, RESIZEABLE_VG)) |
170 | + return_0; |
171 | + |
172 | ++ /* |
173 | ++ * Check if existing PVs have inconsistent block sizes. |
174 | ++ * If so, do not enforce new devices to be consistent. |
175 | ++ */ |
176 | ++ dm_list_iterate_items(pvl, &vg->pvs) { |
177 | ++ logical_block_size = 0; |
178 | ++ physical_block_size = 0; |
179 | ++ |
180 | ++ if (!dev_get_block_size(pvl->pv->dev, &physical_block_size, &logical_block_size)) |
181 | ++ continue; |
182 | ++ |
183 | ++ if (!logical_block_size) |
184 | ++ continue; |
185 | ++ |
186 | ++ if (!prev_lbs) { |
187 | ++ prev_lbs = logical_block_size; |
188 | ++ continue; |
189 | ++ } |
190 | ++ |
191 | ++ if (prev_lbs != logical_block_size) { |
192 | ++ inconsistent_existing_lbs = 1; |
193 | ++ break; |
194 | ++ } |
195 | ++ } |
196 | ++ |
197 | + dm_list_iterate_items(pvl, &pp->pvs) { |
198 | + log_debug_metadata("Adding PV %s to VG %s.", pv_dev_name(pvl->pv), vg->name); |
199 | + |
200 | +@@ -685,6 +713,22 @@ int vg_extend_each_pv(struct volume_grou |
201 | + return 0; |
202 | + } |
203 | + |
204 | ++ logical_block_size = 0; |
205 | ++ physical_block_size = 0; |
206 | ++ |
207 | ++ if (!dev_get_block_size(pvl->pv->dev, &physical_block_size, &logical_block_size)) |
208 | ++ log_warn("WARNING: PV %s has unknown block size.", pv_dev_name(pvl->pv)); |
209 | ++ |
210 | ++ else if (prev_lbs && logical_block_size && (logical_block_size != prev_lbs)) { |
211 | ++ if (vg->cmd->allow_mixed_block_sizes || inconsistent_existing_lbs) |
212 | ++ log_debug("Devices have inconsistent block sizes (%u and %u)", prev_lbs, logical_block_size); |
213 | ++ else { |
214 | ++ log_error("Devices have inconsistent logical block sizes (%u and %u).", |
215 | ++ prev_lbs, logical_block_size); |
216 | ++ return 0; |
217 | ++ } |
218 | ++ } |
219 | ++ |
220 | + if (!add_pv_to_vg(vg, pv_dev_name(pvl->pv), pvl->pv, 0)) { |
221 | + log_error("PV %s cannot be added to VG %s.", |
222 | + pv_dev_name(pvl->pv), vg->name); |
223 | +--- a/tools/lvmcmdline.c |
224 | ++++ b/tools/lvmcmdline.c |
225 | +@@ -2312,6 +2312,8 @@ static int _get_current_settings(struct |
226 | + if (cmd->cname->flags & CAN_USE_ONE_SCAN) |
227 | + cmd->can_use_one_scan = 1; |
228 | + |
229 | ++ cmd->allow_mixed_block_sizes = find_config_tree_bool(cmd, devices_allow_mixed_block_sizes_CFG, NULL); |
230 | ++ |
231 | + cmd->partial_activation = 0; |
232 | + cmd->degraded_activation = 0; |
233 | + activation_mode = find_config_tree_str(cmd, activation_mode_CFG, NULL); |
234 | +--- a/tools/toollib.c |
235 | ++++ b/tools/toollib.c |
236 | +@@ -5363,6 +5363,8 @@ int pvcreate_each_device(struct cmd_cont |
237 | + struct pv_list *vgpvl; |
238 | + struct device_list *devl; |
239 | + const char *pv_name; |
240 | ++ unsigned int physical_block_size, logical_block_size; |
241 | ++ unsigned int prev_pbs = 0, prev_lbs = 0; |
242 | + int must_use_all = (cmd->cname->flags & MUST_USE_ALL_ARGS); |
243 | + int found; |
244 | + unsigned i; |
245 | +@@ -5415,6 +5417,51 @@ int pvcreate_each_device(struct cmd_cont |
246 | + pd->dev = dev_cache_get(cmd, pd->name, cmd->filter); |
247 | + |
248 | + /* |
249 | ++ * Check for consistent block sizes. |
250 | ++ */ |
251 | ++ if (pp->check_consistent_block_size) { |
252 | ++ dm_list_iterate_items(pd, &pp->arg_devices) { |
253 | ++ if (!pd->dev) |
254 | ++ continue; |
255 | ++ |
256 | ++ logical_block_size = 0; |
257 | ++ physical_block_size = 0; |
258 | ++ |
259 | ++ if (!dev_get_block_size(pd->dev, &physical_block_size, &logical_block_size)) { |
260 | ++ log_warn("WARNING: Unknown block size for device %s.", dev_name(pd->dev)); |
261 | ++ continue; |
262 | ++ } |
263 | ++ |
264 | ++ if (!logical_block_size) { |
265 | ++ log_warn("WARNING: Unknown logical_block_size for device %s.", dev_name(pd->dev)); |
266 | ++ continue; |
267 | ++ } |
268 | ++ |
269 | ++ if (!prev_lbs) { |
270 | ++ prev_lbs = logical_block_size; |
271 | ++ prev_pbs = physical_block_size; |
272 | ++ continue; |
273 | ++ } |
274 | ++ |
275 | ++ if (prev_lbs == logical_block_size) { |
276 | ++ /* Require lbs to match, just warn about unmatching pbs. */ |
277 | ++ if (!cmd->allow_mixed_block_sizes && prev_pbs && physical_block_size && |
278 | ++ (prev_pbs != physical_block_size)) |
279 | ++ log_warn("WARNING: Devices have inconsistent physical block sizes (%u and %u).", |
280 | ++ prev_pbs, physical_block_size); |
281 | ++ continue; |
282 | ++ } |
283 | ++ |
284 | ++ if (!cmd->allow_mixed_block_sizes) { |
285 | ++ log_error("Devices have inconsistent logical block sizes (%u and %u).", |
286 | ++ prev_lbs, logical_block_size); |
287 | ++ log_print("See lvm.conf allow_mixed_block_sizes."); |
288 | ++ return 0; |
289 | ++ } |
290 | ++ } |
291 | ++ } |
292 | ++ |
293 | ++ /* |
294 | + * Use process_each_pv to search all existing PVs and devices. |
295 | + * |
296 | + * This is a slightly different way to use process_each_pv, because the |
297 | +--- a/tools/vgcreate.c |
298 | ++++ b/tools/vgcreate.c |
299 | +@@ -47,6 +47,8 @@ int vgcreate(struct cmd_context *cmd, in |
300 | + /* Don't create a new PV on top of an existing PV like pvcreate does. */ |
301 | + pp.preserve_existing = 1; |
302 | + |
303 | ++ pp.check_consistent_block_size = 1; |
304 | ++ |
305 | + if (!vgcreate_params_set_defaults(cmd, &vp_def, NULL)) |
306 | + return EINVALID_CMD_LINE; |
307 | + vp_def.vg_name = vg_name; |
308 | diff --git a/debian/patches/lp-1842436-tests-allow-mixed-block-sizes.patch b/debian/patches/lp-1842436-tests-allow-mixed-block-sizes.patch |
309 | new file mode 100644 |
310 | index 0000000..5494984 |
311 | --- /dev/null |
312 | +++ b/debian/patches/lp-1842436-tests-allow-mixed-block-sizes.patch |
313 | @@ -0,0 +1,68 @@ |
314 | +From cd8a0133fa28a0dff2714c80f822e8c665fe6237 Mon Sep 17 00:00:00 2001 |
315 | +From: David Teigland <teigland@redhat.com> |
316 | +Date: Thu, 1 Aug 2019 10:13:41 -0500 |
317 | +Subject: [PATCH] tests: allow-mixed-block-sizes |
318 | + |
319 | + |
320 | +Origin: upstream, https://sourceware.org/git/?p=lvm2.git;a=commit;h=cd8a0133fa28a0dff2714c80f822e8c665fe6237 |
321 | +Bug-Ubuntu: https://bugs.launchpad.net/bugs/1842436 |
322 | +Last-Update: 2019-09-10 |
323 | + |
324 | +--- |
325 | + test/shell/allow-mixed-block-sizes.sh | 44 +++++++++++++++++++++++++++ |
326 | + 1 file changed, 44 insertions(+) |
327 | + create mode 100644 test/shell/allow-mixed-block-sizes.sh |
328 | + |
329 | +diff --git a/test/shell/allow-mixed-block-sizes.sh b/test/shell/allow-mixed-block-sizes.sh |
330 | +new file mode 100644 |
331 | +index 000000000..18032561f |
332 | +--- /dev/null |
333 | ++++ b/test/shell/allow-mixed-block-sizes.sh |
334 | +@@ -0,0 +1,44 @@ |
335 | ++#!/usr/bin/env bash |
336 | ++ |
337 | ++# Copyright (C) 2019 Red Hat, Inc. All rights reserved. |
338 | ++# |
339 | ++# This copyrighted material is made available to anyone wishing to use, |
340 | ++# modify, copy, or redistribute it subject to the terms and conditions |
341 | ++# of the GNU General Public License v.2. |
342 | ++# |
343 | ++# You should have received a copy of the GNU General Public License |
344 | ++# along with this program; if not, write to the Free Software Foundation, |
345 | ++# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
346 | ++ |
347 | ++SKIP_WITH_LVMPOLLD=1 |
348 | ++ |
349 | ++. lib/inittest |
350 | ++ |
351 | ++dd if=/dev/zero of=loopa bs=$((1024*1024)) count=2 2> /dev/null |
352 | ++dd if=/dev/zero of=loopb bs=$((1024*1024)) count=2 2> /dev/null |
353 | ++LOOP1=$(losetup -f loopa --sector-size 4096 --show) |
354 | ++LOOP2=$(losetup -f loopb --show) |
355 | ++ |
356 | ++echo $LOOP1 |
357 | ++echo $LOOP2 |
358 | ++ |
359 | ++aux extend_filter "a|$LOOP1|" |
360 | ++aux extend_filter "a|$LOOP2|" |
361 | ++ |
362 | ++not vgcreate --config 'devices {allow_mixed_block_sizes=0 scan="/dev"}' $vg $LOOP1 $LOOP2 |
363 | ++vgcreate --config 'devices {allow_mixed_block_sizes=1 scan="/dev"}' $vg $LOOP1 $LOOP2 |
364 | ++vgs --config 'devices {allow_mixed_block_sizes=1 scan="/dev"}' $vg |
365 | ++ |
366 | ++wipefs -a $LOOP1 |
367 | ++wipefs -a $LOOP2 |
368 | ++ |
369 | ++vgcreate --config 'devices {allow_mixed_block_sizes=1 scan="/dev"}' $vg $LOOP1 |
370 | ++vgs --config 'devices {allow_mixed_block_sizes=1 scan="/dev"}' $vg |
371 | ++not vgextend --config 'devices {allow_mixed_block_sizes=0 scan="/dev"}' $vg $LOOP2 |
372 | ++vgextend --config 'devices {allow_mixed_block_sizes=1 scan="/dev"}' $vg $LOOP2 |
373 | ++ |
374 | ++losetup -d $LOOP1 |
375 | ++losetup -d $LOOP2 |
376 | ++rm loopa |
377 | ++rm loopb |
378 | ++ |
379 | +-- |
380 | +2.23.0 |
381 | + |
382 | diff --git a/debian/patches/series b/debian/patches/series |
383 | index b8eaedc..ce362dc 100644 |
384 | --- a/debian/patches/series |
385 | +++ b/debian/patches/series |
386 | @@ -13,3 +13,6 @@ blkdeactivate-use-usr-bin-sort.patch |
387 | 0010-make-generate-config-update.patch |
388 | fix-systemd-run-location.patch |
389 | Detect-systemd-at-run-time-in-69-dm-lvm-metad.rules.patch |
390 | +lp-1842436-restrict-PVs-with-mixed-block-size.patch |
391 | +lp-1842436-tests-allow-mixed-block-sizes.patch |
392 | +lp-1842436-make-generate-example-config.patch |
IMHO no FF violation as it already was a dependency before.
But we could sort out the promotion in Eoan which would be great (some 20.04 work done already).