Setup with mixed PVs (on dasds forced with dasdfmt):

ubuntu@eoan-disktest:~$ sudo pvdisplay 
  "/dev/vdc1" is a new physical volume of "<6.88 GiB"
  --- NEW Physical volume ---
  PV Name               /dev/vdc1
  VG Name               
  PV Size               <6.88 GiB
  Allocatable           NO
  PE Size               0   
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               GqEvSA-Qalj-415c-01i7-0Zxb-gXTW-oUd7BW
   
  "/dev/vdd1" is a new physical volume of "<6.88 GiB"
  --- NEW Physical volume ---
  PV Name               /dev/vdd1
  VG Name               
  PV Size               <6.88 GiB
  Allocatable           NO
  PE Size               0   
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               iMkCz2-JfSi-59ZS-RCzr-nAdC-9SUf-U9EeOu
   
  "/dev/vde1" is a new physical volume of "3.51 GiB"
  --- NEW Physical volume ---
  PV Name               /dev/vde1
  VG Name               
  PV Size               3.51 GiB
  Allocatable           NO
  PE Size               0   
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               vuWlZW-lALQ-Om05-a57f-e0Qu-pE4W-6Rmqyn
   
  "/dev/vdf1" is a new physical volume of "3.51 GiB"
  --- NEW Physical volume ---
  PV Name               /dev/vdf1
  VG Name               
  PV Size               3.51 GiB
  Allocatable           NO
  PE Size               0   
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               OkVIqF-yXA3-MHPr-b3ON-A6Ua-d5GZ-QOHUae
   
ubuntu@eoan-disktest:~$ sudo blockdev --getss /dev/vdc1 /dev/vdd1 /dev/vde1 
/dev/vdf1
4096
4096
512
512

out of these creating mixed size VG and LV:
$ sudo vgcreate vol_grp1 /dev/vdc1 /dev/vdd1 /dev/vde1 /dev/vdf1
$ sudo lvcreate  -l 18 -n log_vol1 vol_grp1
$ sudo lvdisplay 
  --- Logical volume ---
  LV Path                /dev/vol_grp1/log_vol1
  LV Name                log_vol1
  VG Name                vol_grp1
  LV UUID                SNbOFb-F233-2RYv-rjy4-iGW6-Fmo0-f0NNU0
  LV Write Access        read/write
  LV Creation host, time eoan-disktest, 2019-09-09 14:51:41 +0000
  LV Status              available
  # open                 0
  LV Size                72.00 MiB
  Current LE             18
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

Updating to the test build with the requested fix (after
lvremove/vgremove).

Now the same create gives me
$ sudo vgcreate vol_grp1 /dev/vdc1 /dev/vdd1 /dev/vde1 /dev/vdf1
  Devices have inconsistent logical block sizes (4096 and 512).
  See lvm.conf allow_mixed_block_sizes.
$ echo $?
5

I can throw this line into lvm.conf devices section:
        allow_mixed_block_sizes = 1
to make it work again.


I personally miss an entry to the man page or the default .conf file.
I might need to take a look if that was added in another commit, but 
functionally it looks good already. But if anyone wants the PPA would be 
already testable.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1842436

Title:
  [UBUNTU] Avoid creation of mixed-blocksize PV on LVM volume groups

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-z-systems/+bug/1842436/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to