Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to make a installation usb stick for a equipment we have here. I would like to automate linux installation, because we have a lot of these machines to install.

The machine has a 30GB SSD . I want preseed to use the entire disk to create an ext4 partition (mount point '/') and do not create a swap (it's a SSD, so no swap to avoid more read/write).

I read some blog's and articles on the internet where you define an expert_recipe to partman. But I wasn't able to find and option to say use the whole free space. There's the defaut option for partman but I believe (not sure of that) partman would create a swap partition.

How could I do that? Tell preseed to create a single partition using the entire disk and not create a swap partition ?

share|improve this question
up vote 2 down vote accepted

partman indeed creates swap partitions by default, unless you use the expert option. The following expert_recipe creates a single root partition for the entire disk.

d-i partman-basicfilesystems/no_swap boolean false
d-i partman-auto/expert_recipe string myroot :: 1000 50 -1 ext4 \
     $primary{ } $bootable{ } method{ format } \
     format{ } use_filesystem{ } filesystem{ ext4 } \
     mountpoint{ / } \
d-i partman-auto/choose_recipe select myroot

Line 1 disables the partman warning about a missing swap partition. Lines 2-6 create a single partition with a minimum size of 1000 MB. The -1 indicates the maximum size (infinite), which makes partman grow the partition to the size of the disk.

share|improve this answer
I don't even work in that company anymore, but very good to know that. =) – lcguida May 29 '15 at 8:47

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.