Is there a simple way to be able to create custom sized LVM partitions when installing Debian (using Debian 8, jessie)?

If you use the guided partitioner, and even accept its helpful options to create the extra partitions that you often would like (ie, /home, /var, /tmp) it then doesn't seem to be possible (as far as I can tell) to change the sizes of those partitions in the installation process from that which they were created as before finally continuing to go on and partition the disk for real, other than by deleting and then re-creating each partition that you need to change? That would seem to defeat the purpose of both LVM (which I thought was supposed to help make disk partitioning more flexible?) and in having a "helpful" guided partitioning tool?

Is there no other way to create a "fine tuned" partitioning setup other than to set up the disk and LVM entirely from scratch ("Manual partitioning" option) and create each partition that you want individually (which unfortunately does seem rather laborious)?

  • 1
    I'm not sure this is what you're after, but I extend the installer with an option where I can specify all LVM partitions in a single string like root:/:5G:xfs,home:/home:1G:xfs:nodev:nosuid,var:/var:15G:xfs:nodev,swap:none:1G:swap. This is a couple of scripts bunched up in an additional initramfs image. Apr 11, 2017 at 13:03
  • My apologies for not responding sooner, I got diverted with other things! Your suggestion sounds as though it could potentially make things less of a hassle, could you perhaps explain further how it works? (It does sound as though you need to make a custom Debian installer, however?)
    – dave559
    Jul 21, 2017 at 15:20
  • I use the stock installer, just extend it with an additional initramfs image, which contains a couple of scripts implementing a new menu item in partman. If you boot from read-only media, you'll have to remaster it to include that extra initramfs image and the adjusted bootloader (isolinux) configuration, which loads it. If you boot from hard disk or network, you can simply create the new image file and edit the bootloader config. Jul 24, 2017 at 14:10
  • Sorry to hijack, but @FerencWágner, you seem to suggest there's a way to modify partman. I just posted a question looking for something along those lines: unix.stackexchange.com/q/461814/8506. Could you perhaps share more details about how to achieve this? Thanks! Aug 10, 2018 at 14:05

1 Answer 1


LVM does make partitioning more flexible, but the Debian installer simply doesn't have the functionality you're looking for. But, you can always resize the LVM volumes post-installation.

For example, lets say you want the /, /home, /var, /tmp, and swap partitioning scheme but with a larger /home filesystem. What you can do is take the scheme as-is to complete the installation, then once you've confirmed all is OK:

  1. Log out all users except root
  2. Run umount /home
  3. Run lvresize -L<SIZE IN GB>G -r /dev/path/to/home/volume
  4. Run mount /home
  • There’s no need to log users out and unmount the file system, lvresize -r works fine on mounted volumes. Apr 14, 2017 at 12:20
  • Well @StephenKitt, it depends on the filesystem. For example, ext2 doesn't support online resizing, and ext3 only when resize_inode is enabled. Nevertheless, thank you for pointing online resizing as a possibility. Apr 14, 2017 at 23:22
  • Note the context: the OP is using the guided partitioning tool in the Debian 8 installer; that tool creates ext4 file systems. Apr 15, 2017 at 22:34

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .