In an OEM deployment that requested the creation of a swap partition via <oem-swap> that swap partition was created at first boot and was always the last partition on the disk. This was required because it could not be placed before any other partition without destroying those partition contents. This process leaves the system in an inflexible condition if the storage device can change its geometry dynamicly as it's the case for SAN systems. The typical deployment target for OEM images are SAN storage clusters and it's cumbersome to resize the root partition if swap is last. This commit Fixes #1231 and changes the handling of swap if requested via <oem-swap> as follows: 1. The swap space is created as part of the image build process and no longer on first boot of the image via dracut code. This increases the size of the non compressed .raw disk image by the configured swap space size or the default. The compressed versions are not affected since zero initialized swap space compresses to almost no space. Deployment of the image however also deploys the swap partition which increases deployment time. For big swap configurations it's advisable to switch off image verification via oem-skip-verify. For very big swap configurations it's also recommended to prevent kiwi from adding them as part of the image and let them be created on first boot via a systemd service that e.g places a swap file, or creates a swap volume when possible such that the fexibility to resize the rootfs is still available. 2. The setup of the swap space is now explicit. It's no longer calculated by twice times RAM size because on newer machines this could lead to huge numbers. Either the kiwi encoded default swap size applies or the user configured value. 3. LVM based oem disks creates the swap space as logical volume. The volume is created as part of the image build process and no longer on first boot. The swap volume at build time of the image is of a minimal size and gets resized on first boot. 4. The move of the swap creation into the builder code also handles swap per configured device persistency schema like any other devices. This means by default swap is mounted via by-uuid name and thus also Fixes #1259
41 lines
1.5 KiB
XML
41 lines
1.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
|
|
<image schemaversion="7.1" name="LimeJeOS-openSUSE-13.2">
|
|
<description type="system">
|
|
<author>Marcus Schäfer</author>
|
|
<contact>ms@suse.com</contact>
|
|
<specification>
|
|
openSUSE 13.2 JeOS, is a small text based image
|
|
</specification>
|
|
</description>
|
|
<preferences>
|
|
<version>1.13.2</version>
|
|
<packagemanager>zypper</packagemanager>
|
|
<locale>en_US</locale>
|
|
<keytable>us.map.gz</keytable>
|
|
<timezone>Europe/Berlin</timezone>
|
|
<rpm-excludedocs>true</rpm-excludedocs>
|
|
<rpm-check-signatures>false</rpm-check-signatures>
|
|
<bootsplash-theme>openSUSE</bootsplash-theme>
|
|
<bootloader-theme>openSUSE</bootloader-theme>
|
|
<type image="oem" filesystem="btrfs" boot="oemboot/suse-13.2" installiso="true" bootloader="grub2" kernelcmdline="splash" firmware="efi">
|
|
<oemconfig>
|
|
<oem-inplace-recovery>true</oem-inplace-recovery>
|
|
<oem-recovery-part-size>200</oem-recovery-part-size>
|
|
<oem-swap>true</oem-swap>
|
|
</oemconfig>
|
|
</type>
|
|
</preferences>
|
|
<repository>
|
|
<source path="obs://13.2/repo/oss"/>
|
|
</repository>
|
|
<packages type="image">
|
|
<package name="patterns-openSUSE-base"/>
|
|
</packages>
|
|
<packages type="bootstrap">
|
|
<package name="udev"/>
|
|
<package name="filesystem"/>
|
|
<package name="glibc-locale"/>
|
|
</packages>
|
|
</image>
|