Move to a bigger SSD... Impossibile?!

rafpigna

New Member
Nov 21, 2023
5
2
3
I'm new to Proxmox (and Linux filesystems ) so maybe the solution to my issue is really simple but I don't know it.

I installed PVE on a mini-pc based on 11th gen Intel i5 with a 250gb nvme internal ssd.

After configured some VMs and Containers I want to change the SSD with another one with 1TB capacity.

I tried 5 different disk cloning and partitioning utilities (Acronis True Image, Symantec Ghost, Easeus Partition Manager, Gparted, Clonezilla...) booting from external usb and no One of them worked.

If i choose to clone the old ssd on the new one, the main partition keeps to be 245GB leaving a 750gb unallocated space, and after (or before) the cloning I cannot change the partition to use all the available space, because It appears to be in a RAW format that none of the softwares can resize/move.

With Clonezilla I successfully made a cloning process called "proportional" that finally made the new partition to completely use the all available space, but after booting in PVE on the new SSD, the local lvm-thin "disk" is still reported as 250gb and 93% full, like on the old SSD.

So please, could some one suggest what is the appropriate procedure to move the PVE installation to a new (and bigger) SSD in a way that PVE will use all the available space to store VMs, disks and datas?

I would like to avoid to make a complete backup and reinstall PVE and make a restore afterwards, because will require an additional disk of about 200Gb to save the backups, and I don't have it now. But if it's the only way, I will do it asap.

Thanks a lot
 
After extending the partition you still have to increase the VG, root LV + ext4 filesystem and/or thin pool via CLI. So yu have to decide if you want that new space for files or virtual disks.
 
  • Like
Reactions: rafpigna
After extending the partition you still have to increase the VG, root LV + ext4 filesystem and/or thin pool via CLI. So yu have to decide if you want that new space for files or virtual disks.
Since the thin pool is the one that occupies more than 90% of the old disk, I think that I will choose to expand it. Could you give me some advice on how to do it? Anyway I will try to Google search for it. Thanks
 
See the "vgextend" and "lvextend" commands.
Thanks a lot, I googled the commands and tried to figure out how to use them, since I dont have a deep undestranding of Phisical/Logical volumes differences and "connections", and since at least I already had a backup in case of catastrophic failure, I tried anyway, changing some examples found online.

First of all, I checked all the informations about disks and volumes

root@pve:~# [B]lvmdiskscan[/B] /dev/nvme0n1p1 [ 3.93 MiB] /dev/nvme0n1p2 [ 1.00 GiB] /dev/nvme0n1p3 [ <952.87 GiB] LVM physical volume 0 disks 2 partitions 0 LVM physical volume whole disks 1 LVM physical volume

root@pve:~# pvdisplay --- Physical volume --- PV Name /dev/nvme0n1p3 VG Name pve PV Size 237.47 GiB / not usable <1.32 MiB Allocatable yes (but full) PE Size 4.00 MiB Total PE 60793 Free PE 0 Allocated PE 60793 PV UUID 5tW7mG-Cva9-79SS-xxxM-eeCX-v30b-EJyB6x

root@pve:~# lvscan ACTIVE '/dev/pve/data' [<157.23 GiB] inherit ACTIVE '/dev/pve/swap' [8.00 GiB] inherit ACTIVE '/dev/pve/root' [<69.37 GiB] inherit

So I first tried to resize the PV to 100% of available space on disk, with

root@pve:~# pvresize /dev/nvme0n1p3 Physical volume "/dev/nvme0n1p3" changed 1 physical volume(s) resized or updated / 0 physical volume(s) not resized

and It showed that was ok

root@pve:~# pvdisplay --- Physical volume --- PV Name /dev/nvme0n1p3 VG Name pve PV Size 952.86 GiB / not usable <1.37 MiB Allocatable yes PE Size 4.00 MiB Total PE 243933 Free PE 183140 Allocated PE 60793 PV UUID 5tW7mG-Cva9-79SS-xxxM-eeCX-v30b-EJyB6x

at that point I tried to extend the LV, to occupy all the available space on the previous PV

root@pve:~# lvextend -l +100%FREE /dev/pve/data Size of logical volume pve/data_tdata changed from 157.23 GiB (40251 extents) to 872.62 GiB (223391 extents). Logical volume pve/data successfully resized.

and it seems it worked fine!

root@pve:~# lvscan ACTIVE '/dev/pve/data' [872.62 GiB] inherit ACTIVE '/dev/pve/swap' [8.00 GiB] inherit ACTIVE '/dev/pve/root' [<69.37 GiB] inherit

Thanks a lot for giving me the right direction on which commands to investigate!
 
Last edited:
  • Like
Reactions: jesmasco and Dunuin

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!