[Discuss] Debian 11 -> 12

Steve Litt slitt at troubleshooters.com
Wed May 22 21:22:30 EDT 2024


Rich Pieri said on Wed, 22 May 2024 16:01:33 -0400

>On Wed, 22 May 2024 15:07:27 -0400
>Steve Litt <slitt at troubleshooters.com> wrote:
>
>> Unless you're encrypting the root partition, I can't think of any use
>> of LVM that can't be done other ways. I view LVM as yet another layer
>> of abstraction and yet another way to lose your data.  
>
>My most common use case at work:
>
>Add vDisk to VM in vCenter.
>Create partition on vDisk with gdisk.
>pvcreate /dev/${DEV}1
>vgextend ${VG} /dev/${DEV}1
>lvextend -r -l 100%VG /dev/mapper/${LV}
>
>Where VG = volume group and LV = logical volume. We're running with
>large monolithic database files. Bind mounts cannot expand the
>filesystem where these files are stored.

True. I forgot about this use case.

>A much less common use but something we do on our product soak testing
>machines with pools of NVMe storage is to use LVM to stripe across the
>volume group:
>
>lvcreate -i $N -I $X -n $VG
>where N = number of stripe devices, X = stripe size (typically 128KB)
>
>Simpler and less overhead than using mdadm where we don't need device
>redundancy but we do want to distribute writes across the entire pool
>to balance wear. Simple concatenation or bind mounts would cluster
>writes to one device leading to it aging faster than the other devices
>in the pool. Plus we get ludicrous I/O performance which is beneficial
>for soak testing.

True. I never thought of lots of NVMe drives.

>
>I have seen filesystems (notably XFS and early ext4) lose or damage
                                          ^^^^^

I've never seen ext4 do anything worse than recover from journal.

>data. I have seen the VFS layer damage data. But not LVM. Maybe it has
>happened to others. But in 25+ years and somewhere on the order of
>three thousand Linux machines that I have previously managed and
>currently manage as part of my job or used/use personally, I have never
>seen LVM lose or damage data.

My concern is recovering from user error. The fewer layers of
abstraction, the easier it is.

By the way, this isn't discussed in this thread, but my finding is that
formatting thumb drives ext4 instead of leaving them at that windows
format makes them *much* more reliable.

SteveT

Steve Litt 

Autumn 2023 featured book: Rapid Learning for the 21st Century
http://www.troubleshooters.com/rl21


More information about the Discuss mailing list