The Discussion:
We had a good discussion about various topics including:
- How to troubleshoot a microphone using Jitsi on Firefox
- TPM vs. Secure Boot
- Check for presence of a Trusted Platform Module in Linux (dmesg | grep -i tpm)
- Lynis and security recommendations
- Pat recommended this page to help understanding LVM
The Presentation:
Carl provided a live demonstration about block devices and filesystems. Using a virtual machine with a fresh installation of Linux Mint, he showed how to query and manage devices and filesystems on a Linux platform. Here are the key commands that were demoed.
- mount
displays mounted devices including filesystems - df -h
lists mounted filesystems - lsblk
lists block devices - lsblk -e7
ignores loop devices - lsblk -f
includes filesystem information, if available - blkid
gives more detailed information about devices - pvs, vgs, and lvs
shows summary of LVM physical volumes, volume groups, and logical volumes - pvdisplay, vgdisplay, and lvdisplay
shows details about physical volumes, volume groups, and logical volumes - lvcreate and mkfs.ext4
creates and formats a new logical volume in a volume group
lvcreate -L 6G -n home vgmint
lvcreate -L 100%FREE -n tmp vgmint
mkfs.ext4 /dev/vgmint/home
mkfs.ext4 /dev/vgmint/tmp - mount
mounts newly formatted logical volumes
mkdir -p /home2
mount /dev/vgmint/home /mnt/home2 - pvcreate
formats a new physical volume
after using fdisk to create a partition of type 8E:
pvcreate /dev/vdb1
to use entire harddrive:
pvcreate /dev/vdc - vgextend
adds one or more physical volumes to a volume group
vgextend vgmint /dev/vdb1 /dev/vdc - lvresize and resize2fs
increases size of a logical volume and resizes filesystem
lvresize -L 10G /dev/vgmint/home
resize2fs -p /dev/vgmint/home - pvmove, pvreduce, and pvremove
removes device from LVM
pvmove /dev/vdb1
pvreduce vgmint /dev/vdb1
pvremove /dev/vdb1 - lvremove
removes a logical volume from a volume group
lvremove /dev/vgmint/tmp