Plan Review: SATA SSD to NVMe Migration (LVM) & Conversion to proxmox-boot-tool

JasperE

Member
Mar 11, 2021
4
0
21
41
Hi everyone

I'm planning to upgrade the boot drive on my Proxmox VE server from a SATA SSD to a new NVMe SSD. I've spent some time researching the best method and have put together this plan. I would be very grateful if the community could review my plan and point out any potential issues or "gotchas" I might have missed.

Current System State

Proxmox VE Version: 8.4.14
Storage Setup: Single boot disk with LVM, root filesystem is ext4.
Source Disk: /dev/sda (232.9G Samsung SSD 840)
Destination Disk: /dev/nvme0n1 (2TB Samsung SSD 990 PRO)


proxmox-boot-tool status
Re-executing '/usr/sbin/proxmox-boot-tool' in new private mount namespace..
E: /etc/kernel/proxmox-boot-uuids does not exist.

This tells me my system was set up with the `grub-install` method. My plan includes converting to the `proxmox-boot-tool` during the migration for convenience.

The plan

Backup
1. Full backups of all VMs/CTs.
2. Backup `/etc`.
3. Shut down all guests VMs/CTs

Partitioning & LVM Data Migration (Online)
1. Partition the new NVMe drive to have a similar layout (BIOS boot, EFI, LVM).

sgdisk --zap-all /dev/nvme0n1
sgdisk --new=1:2048:4095 --typecode=1:ef02 --change-name=1:"BIOS boot" /dev/nvme0n1
sgdisk --new=2:4096:2099199 --typecode=2:ef00 --change-name=2:"EFI System" /dev/nvme0n1
sgdisk --new=3:2099200:0 --typecode=3:8e00 --change-name=3:"Linux LVM" /dev/nvme0n1
partprobe /dev/nvme0n1

2. Perform the LVM migration.

pvcreate /dev/nvme0n1p3
vgextend pve /dev/nvme0n1p3
pvmove /dev/sda3
vgreduce pve /dev/sda3
pvremove /dev/sda3


Bootloader Migration & Conversion to `proxmox-boot-tool`
This is the part I'm looking to get some feedback. The goal is to make `/dev/nvme0n1p2` the new managed ESP.

1. Format the new EFI partition.
proxmox-boot-tool format /dev/nvme0n1p2

2. Update `/etc/fstab` to point to the new EFI partition.
Get the UUID of the new partition
blkid /dev/nvme0n1p2
Edit /etc/fstab and replace the line for /boot/efi with the UUID of /dev/nvme0n1p2

3. Initialize the new ESP with `proxmox-boot-tool`.

umount /boot/efi
mount /boot/efi
proxmox-boot-tool init /dev/nvme0n1p2
proxmox-boot-tool refresh

Finalization
1. Reboot the server.
2. Enter BIOS/UEFI setup.
3. Change the boot order to prioritize the "UEFI: Samsung SSD 990 PRO".

Dies anybody see any issues with this approach?
My hypervisor does have some stuff installed on it that makes me want to prevent rei stalling it (borgmatic backups, mail relay, zfs storage pool snapshot ting with sanoid, etc)
 
Last edited:
have put together this plan
You are from the A-team ? I love it if a plan will function ... don't look that bad but as you know the devel sit in detail. Have you plan B too ? The problem I see is when somethink don't work as expected you may end with 2 disks and both aren't bootable anymore - hopefully not but not impossible. I would prefere to setup a new pve just on nvme and then hotplug your old ssd too after you could get all what you further need by any kind of copy over but don't touch/move any from old ssd until you aren't able to boot just with the 1 nvme and all works as expected and before - just as my 2 cents to. Good luck at plan A !
:)
 
Well I certainly like to think myself as part of the A team :).

If I end up with unbootable disks,... then that's wat backups and live boot recovery chroot methods are for.

I already moved the data volumes as shown in the plan. So I guess that part of the plan 'came together' and I quite love that.

Planning to move the boot partitions later. Any informed feedback about the suggested method is still very welcome.
 
Last edited: