How to repartition Debian install for Proxmox LVM?

postcd

Renowned Member
Sep 16, 2013
41
0
71
Hello,

Debian stretch (9) 64bit was installed for me and i would like to install Proxmox VE on it according to this tutorial: https://pve.proxmox.com/wiki/Install_Proxmox_VE_on_Debian_Stretch

First issue i have as a a Linux partitioning, LVM and Proxmox newbie following that tutorial is:

i do not know how to properly re-partition my disk space (hw raid 10) to work with Proxmox VE and enjoy modern possibilities like on the fly snapshots. I read that LVM is recommended.

Here is how the partitioning looks like now (by default after OS installation):
https://pastebin.com/E0DHUhrG

It seems like 550GB space in total.
My all current VPS OS templates are 12GB total, i would like to have around 30GB for templates.
Largest VPS on the server would be 350GB. Backups would be stored on other server over network.
Rest of the space would be used on small VPSs.
I do not have any other space requirements.

Please which commands can i do to re-partition my current disk space?

# apt-get install lvm2
The following NEW packages will be installed:
dmeventd libdevmapper-event1.02.1 liblvm2app2.2 liblvm2cmd2.02 libreadline5 lvm2

Please can you include also space values for particular "partitions"/volumes that you would personally use in my usage scenario?
I am sure this would help not only me but also future readers.

Thank You
 
Last edited:
Hello,

for me this default values are really bad, why should you ever need 64 GB for swap and why they add a extended partition if there are 3 primary left.

I would not repartition on this system if you use it, you should backup all your data, boot into a rescue system and debootstrap the installation or boot a iso and use the installer.

Partition sheme if you want to use GPT instead of MBR partition table and not UEFI.
Code:
Number  Start (sector)    End (sector)  Size       Code  Name
   1            2048            6143   2.0 MiB     EF02  BIOS boot partition
   2            6144       104863743   50.0 GiB    FD00

SW RAID (you can ignore it if you don't use it or have only 1 HDD
Code:
md0 : active raid1 sda2[0] sdb2[1]
      52396032 blocks super 1.2 [2/2] [UU]

All the space of partition 2 will go to the LVM
Code:
pvs
  PV                     VG      Fmt  Attr PSize  PFree
  /dev/md0               system  lvm2 a--  49.96g 14.96g
----------
lvscan
  ACTIVE            '/dev/system/boot' [1.00 GiB] inherit
  ACTIVE            '/dev/system/swap' [4.00 GiB] inherit
  ACTIVE            '/dev/system/root' [30.00 GiB] inherit

There are many tutorials around for debootstrap and how you use LVM, but if you are new to this it would not be easy. So you should test this on a local computer before you rollout this to your server.
 

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!