Set up software RAID on existing AlmaLinux 9 LVM

You can read man mdadm for the syntax of the command. Perhaps:

mdadm --create /dev/md0 --metadata=0.90 --level=1 --raid-devices=2 missing /dev/sdh1

I don’t think that you did “copy” as in “copy contents”, but did “define similar partitions” on the second drive. Partitions are listed as “first sector, last sector, type” values in partition table.

If you do follow the instructions, then you will make the sdh2 partition a LVM physical volume (PV) and after that add it to the LVM volume group (VG) “almalinux”. When the VG has more space, you can move logical volume (LV) – change where on the drives the data of that LV is, with pvmove.


The LV “swap” of VG “almalinux” is in use. The /etc/fstab has entry for it. One way to stop the use of swap is to first comment the line (insert # at start of line) in /etc/fstab and then use command swapoff (see man swapoff) or reboot.

When a filesystem or swap partition is not in use, it can be removed (see man lvremove).

To create a new swap on LV, one probably needs commands lvcreate, mkswap, and blkid.