===========================================================================
*edit: DEC 1, 2024 - After sleeping and thinking about it, I've decided to use LVM Thin Pools and Thin Logical Volumes for more efficient usage of the disks instead of regular LVM storage. I'm leaving my instructions below incase anyone else wants to use regular LVMs. I'll update this thread after I've created and updated the storage from regular LVM to LVM-Thin Pools.
===========================================================================
I've decided to use regular Logical Volumes (LVMs) rather than LVM-Thin Pools and Thin LVMs within those pools (Thin LVMs are one to one with a guest VM). I'm using regular LVMs because it's more like a Datastore (as used in my esxi setup) in my mind than storage of Thin LVMs. I'm still learning the pros and cons of each, but that's my decision for now. Regular LVM.
That said, I'm allocating the Volume Groups (VGs) as a one to one with each physical SSD (sda, sdb, sdc, sdd), the idea being that it is much easier to detach and rotate out physical SSDs as they fill up with guest VMs, if each SSD has it's own unique VG. And likewise, each LVM will be a one to one with each VG, for the same reason when it comes time to detach and rotate out hotswap SSDs. Multiple guest VMs in each LVM.
*here is what this does:
- list the devices, partitions, logical volumes and their mountpoints, using lsblk (shows how it looks before running the following).
- create Physical Volumes of each SSD device
- create Volume Goups, one to one with each Physical Volume (SSD)
- create Logical Volumes, one to one with each Volume Group (and therefore a one to one with each Physical Volume, i.e. SSD)
- define those Logical Volumes as EXT4
- make the directory paths of where the Logical Volumes will be mounted
- mount the Logical Volumes to those directory paths
- edit the /etc/fstab so that when the proxmox server reboots it will remount those volumes again
- test the edited fstab by forcing it to run and remount everythign: using 'mount -a'
- list the volume groups and mountpoints again using lsblk
root@miniprox1:~# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 3.6T 0 disk
sdb 8:16 0 3.6T 0 disk
sdc 8:32 0 3.6T 0 disk
sdd 8:48 0 3.6T 0 disk
sde 8:64 0 465.8G 0 disk
├─sde1 8:65 0 1007K 0 part
├─sde2 8:66 0 1G 0 part /boot/efi
└─sde3 8:67 0 464.8G 0 part
├─pve-swap 252:0 0 32G 0 lvm [SWAP]
├─pve-root 252:1 0 120.2G 0 lvm /
├─pve-data_tmeta 252:2 0 3G 0 lvm
│ └─pve-data 252:4 0 291.6G 0 lvm
└─pve-data_tdata 252:3 0 291.6G 0 lvm
└─pve-data 252:4 0 291.6G 0 lvm
sdf 8:80 1 29.9G 0 disk
├─sdf1 8:81 1 242K 0 part
├─sdf2 8:82 1 8M 0 part
├─sdf3 8:83 1 1.3G 0 part
└─sdf4 8:84 1 300K 0 part
root@miniprox1:~# pvcreate /dev/sda
pvcreate /dev/sdb
pvcreate /dev/sdc
pvcreate /dev/sdd
Physical volume "/dev/sda" successfully created.
Physical volume "/dev/sdb" successfully created.
Physical volume "/dev/sdc" successfully created.
Physical volume "/dev/sdd" successfully created.
root@miniprox1:~# vgcreate miniprox1_VG1 /dev/sda
vgcreate miniprox1_VG2 /dev/sdb
vgcreate miniprox1_VG3 /dev/sdc
vgcreate miniprox1_VG4 /dev/sdd
Volume group "miniprox1_VG1" successfully created
Volume group "miniprox1_VG2" successfully created
Volume group "miniprox1_VG3" successfully created
Volume group "miniprox1_VG4" successfully created
root@miniprox1:~# lvcreate -L 3.5T -n lv_vmdata001 miniprox1_VG1
lvcreate -L 3.5T -n lv_vmdata002 miniprox1_VG2
lvcreate -L 3.5T -n lv_vmdata003 miniprox1_VG3
lvcreate -L 3.5T -n lv_vmdata004 miniprox1_VG4
Logical volume "lv_vmdata001" created.
Logical volume "lv_vmdata002" created.
Logical volume "lv_vmdata003" created.
Logical volume "lv_vmdata004" created.
root@miniprox1:~# mkfs.ext4 /dev/miniprox1_VG1/lv_vmdata001
mkfs.ext4 /dev/miniprox1_VG2/lv_vmdata002
mkfs.ext4 /dev/miniprox1_VG3/lv_vmdata003
mkfs.ext4 /dev/miniprox1_VG4/lv_vmdata004
mke2fs 1.47.0 (5-Feb-2023)
Discarding device blocks: done
Creating filesystem with 939524096 4k blocks and 234881024 inodes
Filesystem UUID: 3368a770-7100-4757-9e4f-6b6c3160b0a3
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848, 512000000, 550731776, 644972544
Allocating group tables: done
Writing inode tables: done
Creating journal (262144 blocks): done
Writing superblocks and filesystem accounting information: done
mke2fs 1.47.0 (5-Feb-2023)
Discarding device blocks: done
Creating filesystem with 939524096 4k blocks and 234881024 inodes
Filesystem UUID: 8b4e51dc-71cb-4d2d-b47a-5a18d7e0ec53
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848, 512000000, 550731776, 644972544
Allocating group tables: done
Writing inode tables: done
Creating journal (262144 blocks): done
Writing superblocks and filesystem accounting information: done
mke2fs 1.47.0 (5-Feb-2023)
Discarding device blocks: done
Creating filesystem with 939524096 4k blocks and 234881024 inodes
Filesystem UUID: 0b847866-c2f5-4b87-9967-5027d578cdbe
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848, 512000000, 550731776, 644972544
Allocating group tables: done
Writing inode tables: done
Creating journal (262144 blocks): done
Writing superblocks and filesystem accounting information: done
mke2fs 1.47.0 (5-Feb-2023)
Discarding device blocks: done
Creating filesystem with 939524096 4k blocks and 234881024 inodes
Filesystem UUID: 5745582c-c96b-48ad-9d50-13ee11fd3dbd
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848, 512000000, 550731776, 644972544
Allocating group tables: done
Writing inode tables: done
Creating journal (262144 blocks): done
Writing superblocks and filesystem accounting information: done
root@miniprox1:~# mkdir /storage/vmdata001
mkdir /storage/vmdata002
mkdir /storage/vmdata003
mkdir /storage/vmdata004
root@miniprox1:~# mount /dev/miniprox1_VG1/lv_vmdata001 /storage/vmdata001
mount /dev/miniprox1_VG2/lv_vmdata002 /storage/vmdata002
mount /dev/miniprox1_VG3/lv_vmdata003 /storage/vmdata003
mount /dev/miniprox1_VG4/lv_vmdata004 /storage/vmdata004
root@miniprox1:~# cat /etc/fstab
# <file system> <mount point> <type> <options> <dump> <pass>
/dev/pve/root / ext4 errors=remount-ro 0 1
UUID=D3E2-40E2 /boot/efi vfat defaults 0 1
/dev/pve/swap none swap sw 0 0
proc /proc proc defaults 0 0
#########################################################
# BRTA - Benny R. Tate II - November 30, 2024
# Adding the following lines for the SSD disk LVMs.
#########################################################
/dev/miniprox1_VG1/lv_vmdata001 /storage/vmdata001 ext4 defaults,nofail 0 2
/dev/miniprox1_VG2/lv_vmdata002 /storage/vmdata002 ext4 defaults,nofail 0 2
/dev/miniprox1_VG3/lv_vmdata003 /storage/vmdata003 ext4 defaults,nofail 0 2
/dev/miniprox1_VG4/lv_vmdata004 /storage/vmdata004 ext4 defaults,nofail 0 2
root@miniprox1:~# mount -a
root@miniprox1:~# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 3.6T 0 disk
└─miniprox1_VG1-lv_vmdata001 252:5 0 3.5T 0 lvm /storage/vmdata001
sdb 8:16 0 3.6T 0 disk
└─miniprox1_VG2-lv_vmdata002 252:6 0 3.5T 0 lvm /storage/vmdata002
sdc 8:32 0 3.6T 0 disk
└─miniprox1_VG3-lv_vmdata003 252:7 0 3.5T 0 lvm /storage/vmdata003
sdd 8:48 0 3.6T 0 disk
└─miniprox1_VG4-lv_vmdata004 252:8 0 3.5T 0 lvm /storage/vmdata004
sde 8:64 0 465.8G 0 disk
├─sde1 8:65 0 1007K 0 part
├─sde2 8:66 0 1G 0 part /boot/efi
└─sde3 8:67 0 464.8G 0 part
├─pve-swap 252:0 0 32G 0 lvm [SWAP]
├─pve-root 252:1 0 120.2G 0 lvm /
├─pve-data_tmeta 252:2 0 3G 0 lvm
│ └─pve-data 252:4 0 291.6G 0 lvm
└─pve-data_tdata 252:3 0 291.6G 0 lvm
└─pve-data 252:4 0 291.6G 0 lvm
sdf 8:80 1 29.9G 0 disk
├─sdf1 8:81 1 242K 0 part
├─sdf2 8:82 1 8M 0 part
├─sdf3 8:83 1 1.3G 0 part
└─sdf4 8:84 1 300K 0 part
root@miniprox1:~# df -H
Filesystem Size Used Avail Use% Mounted on
udev 68G 0 68G 0% /dev
tmpfs 14G 1.7M 14G 1% /run
/dev/mapper/pve-root 127G 3.0G 117G 3% /
tmpfs 68G 45M 68G 1% /dev/shm
tmpfs 5.3M 0 5.3M 0% /run/lock
efivarfs 525k 388k 132k 75% /sys/firmware/efi/efivars
/dev/sde2 1.1G 13M 1.1G 2% /boot/efi
/dev/fuse 135M 25k 135M 1% /etc/pve
tmpfs 14G 0 14G 0% /run/user/0
/dev/mapper/miniprox1_VG1-lv_vmdata001 3.8T 29k 3.6T 1% /storage/vmdata001
/dev/mapper/miniprox1_VG2-lv_vmdata002 3.8T 29k 3.6T 1% /storage/vmdata002
/dev/mapper/miniprox1_VG3-lv_vmdata003 3.8T 29k 3.6T 1% /storage/vmdata003
/dev/mapper/miniprox1_VG4-lv_vmdata004 3.8T 29k 3.6T 1% /storage/vmdata004
root@miniprox1:~#