1

According to official debian manual (https://www.debian.org/releases/stable/amd64/apbs04.html.en), i saw:

#d-i partman-auto/expert_recipe string                         \
#      boot-root ::                                            \
#              40 50 100 ext3                                  \
#                      $primary{ } $bootable{ }                \
#                      method{ format } format{ }              \
#                      use_filesystem{ } filesystem{ ext3 }    \
#                      mountpoint{ /boot }                     \
#              .                                               \
#              500 10000 1000000000 ext3                       \
#                      method{ format } format{ }              \
#                      use_filesystem{ } filesystem{ ext3 }    \
#                      mountpoint{ / }                         \
#              .                                               \
#              64 512 300% linux-swap                          \
#                      method{ swap } format{ }                \
#              .

But this variant for using all disk. But if i want to use 30 Gb for root / and 2 Gb for swap. Other space i don't want to use (unlocated space). How to do it ? Sorry, i tried to find, but i have not found ? Maybe you can help me ?

1 Answer 1

2

Do you want /boot as a separate filesystem? The example in your question will create it with a minimum of 40 MB, maximum of 100 MB. If you want it to be 500 MB always, then set the three numbers for /boot like 500 500 500.

For root, if you want it to always be 30 GB (= 30000 MB), specify the three numbers as 30000 30000 30000. If you don't want to use a separate /boot filesystem, move the $primary{ } $bootable{ } line to this partition and then delete the /boot partition specification.

For always 2 GB of swap, set the swap values to 2048 2048 2048.

Note: Debian's installer user powers of 10, not powers of 2. For swap, you might want to increase the values some more to match the RAM sizes, which are always based on powers of 2.

Ref: partman-auto-recipe.txt, Debian bug report #235335

When you're specifying fixed sizes (minimum = maximum) then the priority value will be unimportant. But the documentation says the priority value should normally be between the min and max size values, so all three values should then be the same, and equal to the required size in MB.

So here's a recipe for just two partitions, 30 GB for root and 2 GB for swap, using the ext4 filesystem for root, uncommented and ready for use:

 d-i partman-auto/expert_recipe string                    \
      boot-root ::                                        \
          30000 30000 30000 ext4                          \
                  $primary{ } $bootable{ }                \
                  method{ format } format{ }              \
                  use_filesystem{ } filesystem{ ext4 }    \
                  mountpoint{ / }                         \
          .                                               \
          2048 2048 2048 linux-swap                       \
                  method{ swap } format{ }                \
          .
d-i partman-auto/choose_recipe select boot-root

A more complex example can be seen at this answer.

3

You must log in to answer this question.

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