What is LVM?
LVM stage for Logical Volume Manager. LVM for Linux was developed by RedHat. Here I particularly reference lvm2.
LVM2 and mkinitramfs
LVM2 support is enabled by specifying --with-lvm2 switch. Of course you should have lvm2 binary in your path. By default LVM2 volume device files are only created under /dev/mapper, i.e. no /dev/disk/by-uuid links. Since LVM2 relies on device-mapper, you'll need to adjust device-mapper related udev rules. See DMrules for more info.
Implementation
Plugin code is rather simple:
#> cat /usr/share/mkinitramfs/lvm2 # Register our scan function SCAN="lvm2_scan $SCAN" function lvm2_scan() { grep -q dm_mod /proc/modules || modprobe dm_mod lvm vgscan --ignorelockingfailure >/dev/null 2>&1 || die lvm vgchange -ay --ignorelockingfailure >/dev/null 2>&1 || die return 1 }