Saltboot Formula
The Saltboot formula is used to configure disk images and partitioning for the selected hardware type.
The Saltboot formula is meant to be used as a group formula. Enable and configure Saltboot formula for hardware type groups. |
To apply changes to a terminal, terminal needs to be restarted. Applying highstate does not have any effect on running terminals. |
-
Open the details page for your new hardware type group, and navigate to the
Formulas
tab. -
Select the Saltboot formula and click Save.
-
Navigate to the
tab. -
In the
Disk 1
section, set these parameters:-
In the
Disk symbolic ID
field, enter a custom name for the disk (for example,disk1
). -
In the
Device type
field, selectDISK
. -
In the
Disk device
field, select the device that corresponds to the device name on the target machine or asterisk*
, see Disk Selection in Saltboot Formula. -
In the
RAID level
field, leave it empty. -
In the
Disk Label
field, selectgpt
.
-
-
In the
Partition
section, set these parameters forPartition 1
:-
In the
Partition symbolic ID
field, enter a custom name for the partition (for example,p1
). -
In the
Partition size
use value 500. -
In the
Device mount point
use/boot/efi
. -
In the
Filesystem format
usevfat
. -
In the
OS Image to deploy
field, leave it empty. -
In the
Partition encryption password
field, leave it empty. -
In the
Partition flags
useboot
.
-
-
In the
Partition
section, set these parameters forPartition 2
:-
In the
Partition symbolic ID
field, enter a custom name for the partition (for example,p2
). -
In the
Partition size
field, specify a size for the partition in Mebibytes (MiB). -
In the
Device mount point
field, select a location to mount the partition (for example,/data
). -
In the
Filesystem format
field, select your preferred format (for example,xfs
). -
In the
OS Image to deploy
field, leave it empty. -
In the
Partition encryption password
field, enter a password if you want to encrypt the partition. -
In the
Partition flags
field, leave it empty.
-
-
In the
Partition
section, set these parameters forPartition 3
:-
In the
Partition symbolic ID
field, enter a custom name for the partition (for example,p3
). -
In the
Partition size
field, specify a size for the partition in Mebibytes (MiB). -
In the
Device mount point
field, leave it empty. -
In the
Filesystem format
field, selectswap
. -
In the
OS Image to deploy
field, leave it empty. -
In the
Partition encryption password
field, enter a password if you want to encrypt the partition. -
In the
Partition flags
field, selectswap
.
-
-
In the
Partition
section, set these parameters forPartition 4
:-
In the
Partition symbolic ID
field, enter a custom name for the partition (for example,p4
). -
In the
Partition size
field, leave it empty. This will ensure the partition uses up all remaining space. -
In the
Device mount point
field, select/
. -
In the
Filesystem format
field, leave it empty. -
In the
OS Image to deploy
field, enter the name of the image to deploy. -
In the
Image version
field, leave it empty. This will ensure you use the latest available version. -
In the
Partition encryption password
field, enter a password if you want to encrypt the partition. -
In the
Partition flags
field, leave it empty.
-
-
Click Save Formula to save your configuration.
1. Special Partition Types
The Saltboot formula helps you with setting up special partition types.
For terminal to be able to boot locally, either |
1.1. BIOS grub Partition
A BIOS grub partition is needed for local booting from a GPT
disk on non-EFI machines. For more information, see https://en.wikipedia.org/wiki/BIOS_boot_partition.
In the formula, enter the following options:
Partition Symbolic ID: p1 Partition Size (MiB): 50 Partition Flags: bios_grub
Leave the other fields empty.
1.2. EFI Partition
An EFI partition is needed for local booting on EFI machines, Partition Table Type
must be GPT
. For more information, see https://en.wikipedia.org/wiki/EFI_system_partition.
In the formula, enter the following options:
Partition Symbolic ID: p1 Partition Size (MiB): 500 Device Mount Point: /boot/efi Filesystem Format: vfat Partition Flags: boot
Leave the other fields empty.
2. Disk Selection in Saltboot Formula
When there is only one disk present on target hardware (including USB drives), use an asterisk *
to automatically select the disk device.
When there are multiple disks, use an asterisk *
in the device path. In this example, SATA disks are differentiated from USB disks:
/dev/disk/by-path/*-ata-1 /dev/disk/by-path/*usb*
If the entered value does not contain /
, the entered value is automatically prepended by /dev/disk/by-path/
. For example, *usb*
is the same as /dev/disk/by-path/*usb*
.
If you prefer to select specific devices, you can this format in the disk device field:
-
symbolic names (for example:
/dev/sda
) -
by-path (for example:
/dev/disk/by-path/..
) -
by-id (for example:
/dev/disk/by-id/…
)
To see a list of available devices from the command prompt, press Esc while waiting for key approval.
3. Troubleshooting the Saltboot Formula
msdos
Disklabel Limitations-
On the
msdos
disk label, you can create a maximum of four primary partitions. Extended partitions are not supported. If you need more than four partitions, use theGPT
disk label instead.
For more information on troubleshooting problems with the Saltboot formula, see Saltboot 公式查错.