Proxmox VE does not provide built-in support for creating mdadm software RAID arrays during installation. However, even if you install Proxmox on a single disk, you can still convert the system to a reliable RAID-1 setup afterward using mdadm and LVM.
Requirements
- Two identical SSDs/HDDs (same capacity; minor revision differences are okay)
- Proxmox installed on one drive
- A second empty drive of the same size or larger
- Basic familiarity with LVM, mdadm, and Debian-based tools
Environment Example
/dev/nvme0n1Drive containing a fresh Proxmox installation./dev/nvme0n1p1BIOS partition./dev/nvme0n1p2Boot partition./dev/nvme0n1p3Proxmox OS partition./dev/nvme1n1Identical empty drive.
Install mdadm
Update package lists and install mdadm:
apt update && apt install mdadm
Clone the Partition Table
Backup the partition table of the primary drive:
sfdisk -d /dev/nvme0n1 > part_table
Strip UUIDs and copy the table to the second drive:
grep -v ^label-id part_table | sed -e 's/, *uuid=[0-9A-F-]*//' | sfdisk /dev/nvme1n1
Create a Degraded RAID-1 Array
Create a RAID-1 device with only the new drive attached:
mdadm --create /dev/md0 --level 1 --raid-devices 2 /dev/nvme1n1p3 missing
Add RAID Device to LVM
Create a physical volume:
pvcreate /dev/md0
Extend the existing Proxmox volume group:
vgextend /dev/pve /dev/md0
Move Data to RAID
Do not interrupt it.
pvmove /dev/nvme0n1p3 /dev/md0 > pvmove.log 2>&1 &
Check the progress:
tail -f pvmove.log
Remove Old PV from Volume Group
vgreduce /dev/pve /dev/nvme0n1p3
Add the Original Disk to RAID
Now attach the original Proxmox OS partition to the RAID array so it can resync:
mdadm --manage --add /dev/md0 /dev/nvme0n1p3
Copy Boot and EFI Partitions
Clone partition 1 and 2 to the second drive:
dd if=/dev/nvme0n1p1 of=/dev/nvme1n1p1
dd if=/dev/nvme0n1p2 of=/dev/nvme1n1p2
Install GRUB on Both Drives
Install GRUB on each disk:
grub-install /dev/nvme0n1
grub-install /dev/nvme1n1
Update initramfs
Regenerate initramfs so the system knows about the new RAID structure:
update-initramfs -u -k all
Monitor RAID Sync Status
Check resync progress:
watch cat /proc/mdstat
Expected output (example):
md0 : active raid1 sda3[2] sdb3[0]
487729152 blocks super 1.2 [2/2] [UU]
bitmap: 1/4 pages [4KB], 65536KB chunk
Verification — Check Final Layout
A functional RAID-1 setup should show an md0 RAID-1 device backing your LVM volumes (pve-root, pve-data, etc.).
lsblk
mdadm will automatically begin syncing the array. To monitor the progress:
watch cat /proc/mdstat
Additional Notes
- You can extend this method to mirror the boot partition as well, although this has not been fully tested.
- If a drive is replaced in the future, you must manually copy partitions 1 and 2 before adding it back to the RAID array.
- After adding a replacement drive, mdadm will automatically begin the resync process.