The preparation to call zipl and the call itself were wrong.
For whatever reason the kernel image the initrd are moved
to another location prior to calling zipl. That move broke
the system because no kernel/initrd existed at the expected
place anymore. In addition the zipl call itself was issued
from a the wrong directory. Also no config file was written
as an after effect of the refactoring in Issue #1194. This
Fixes#1173 and bsc#1156694
Fedora now uses a BLS configuration by default, but this is not supported
by all distributions. So check if is supported by the grub2-mkconfig tool
and only enable the option if that's the case.
Fixes: #1248
If the attribute bootloader_console="serial" is set, the
expectation that there is no graphics hardware available is
valid. Thus the isolinux setup should not contain any ui
configuration instructions because that leads to run the
graphics initialization which blocks the system if not
present. Please note the bootloader_console allows for
multiple console configuration. In mixed setup the ui
configuration still applies. This Fixes#1153
In case of an overlay root system via overlayroot="true" all parts
of the rootfs are read-only by squashfs except for the extra boot
partition. However tools like grub's mkconfig creates temporary
files at call time and therefore /tmp needs to be writable during
the call time of the tools. Related to Issue #1194
In the same way as we need to lookup the name for the mkimage
tool we also have to lookup the name of the config tool.
That's because distributions do not handle that consistently
For ISO images that are EFI bootable as well as for EFI
secure boot configurations that are not based on shim-install
kiwi provides a fallback code that copies the grub config file
to the efi/efi-vendor boot path. This fallback code was broken
because of the recent change to let grub2 mkconfig create the
config file. The call of grub2 mkconfig happens at a later
stage which required an adaption of the fallback mechanism.
This is related to Issue #1194
Instead of creating a template based grub config file, use
grub2-mkconfig to create the config file during the build
process. This commit changes from config template to grub2
tooling for the disk based image types vmx and oem
This Fixes#1194
Not all distributions provides the grub linuxefi module anymore.
This means a static list for building an efi grub image if needed
is no longer appropriate. This patch changes the module handling
at the following places
1. Use linuxefi for building custom efi modules only if present
on the host system
2. Use linuxefi related grub2-mkconfig variables only if the
host grub2-mkconfig implementation supports it
3. Prevent building custom efi image on Fedora by extending
the search path for the distro provided efi image and also
adapt the spec file accordingly
For non EFI boot grub2-install has code which gets activated
through the GRUB_ENABLE_CRYPTODISK setting. However for the
EFI boot case no installation of boot code is needed and
therefore the grub earlyboot script has to run cryptomount
We supported luks encrypted images with the exception of the
boot partition because grub was not able to read from an
encrypted device at that time. Since some time grub is able
to read from an encrypted partition and this commit add
support for it. With this patch luks encrypted images will
no longer create an extra boot partition and the entire
system will be encrypted. The opening of the luks container
happens on the grub level only once. Customers can still
specify to use an unencrypted extra boot partition with the
bootpartition="true" flag. In this case the opening of the
luks containers happens on the systemd level as before.
This is related to Issue #1162
rsync's "compress" option just does not make any sense when rsync is
used to copy files locally, it only increases CPU usage and slows down
the process ;-)
The BootLoaderConfig class interface writes several files
e.g etc/sysconfig/bootloader, boot/grub2/grub.cfg and more.
Depending on the image type some of those files belongs
into the root directory and some belongs into the boot
directory. For standard images both locations points to
the same master root entry point. However for special
types like live systems the root tree and the boot tree
are different targets. For example live root filesystems
are a squashfs compressed image file whereas the plain
booting information lives outside. Because of that this
patch introduces a refactoring of the BootLoaderConfig
class to allow to distinguish between root_dir and
boot_dir paths. In addition the live image builder makes
use of the new concept and thus Fixes#1112
With the concept of shim being an option and not mandatory
also the fallback code has to adapt and treat the absence
of shim.efi as not fatal. In this situation we expect the
found grub.efi binary to be correctly signed which we can
only assume but not prove
Before this commit isolinux was used to boot an ISO and
thus forms a hard requirement. isolinux however only
exists for the x86 platform. This limitation did not
allow to create ISO images for other platforms. With this
commit a refactoring of the ISO boot setup is introduced.
* isolinux is only used if the bios firmware is requested
and the platform matches the x86 architecture. A runtime
check will check for this condition and exits early if
not applicable
* in case of the EFI firmware we already used grub in
EFI mode but still had isolinux in place for the legacy/CSM
boot. That part is now also replaced by a platform specific
grub eltorito image and grub's boot_hybrid.img for hybrid
boot. On platforms that do not provide those modules the
support for it will be skipped
With this change in place it's possible to control the ISO
boot layout through the firmware setup and all platform
specific modules are handled as such. Therefore we also
deleted the syslinux requirement. This Fixes#1092
On zipl we manually move the kernel and initrd file to the
zipl boot path because symlinks can't be read. That move
operation used the wrong filenames and was broken since
baseCreateCommonKernelFile is only used in the legacy
custom kiwi boot images but not in the dracut case.
This is a follow up patch for #f5bac4495d34. The change of the
location of the font file was not applied if an iso target, live
or install image is being built. This patch completes the change
and Fixes bsc#1124885
If the theme was not found at the expected place an exception
was thrown. However the alternative lookup code in /boot was
not reached with that exception. This commit fixes this
In SUSE products EFI binaries are historically located in
/usr/lib*/efi. In a recent move to package grub2 as noarch
fate#326960, a collision between x86_64 and aarch64 has been
identified, as both place platform-specific files in the same
spot. To rectify this, a new location was devised:
/usr/share/efi/$(uname -m). At the same time /usr/lib/grub2 will
move to /usr/share/grub2. This Fixes#924
grub2 is expecting the unicode font below the fonts
directory in the /boot/grub*/ depending on how the
distribution installs grub2. This Fixes bsc#1119416
This commit adds a new attribute called:
<type ... install_continue_on_timeout="true|false"/>
It allows to setup the boot timeout for install images
build with KIWI. If not set or set to 'true' the configured
boottimeout or its default applies to the install image
as it was before. If set to 'false' there will be no
timeout in the install image bootloader setup and the boot
only continues on manual intervention.
This commit makes volid attribute also available for OEM images.
The installation media makes use of the volid value. Only posix
safe names are allowed, up to 32 characters.
Fixes#811
If boottimeout is set to zero it is evaluated as "not set"
and the default applies. However it's a fairly well approach
to set a zero second boot timeout. This Fixes#789
This patch is two fold. First part replaces the import of
dedicated video modules in the grub image by the all_video
module. Second part avoids runtime module insertion which
requires access to the boot filesystem which is not
guaranteed on sophisticated rootfs structures like btrfs
plus readonly snapshots and what not. Thus we make sure
all boot code is embedded into the grub image(s) and no
extra loading of modules at runtime will be needed.
This Fixes bsc#1096937
By default we always set LOADER_LOCATION=mbr which is wrong
if EFI is in use. This patch updates the value to be correct.
It also seems that this variable is only consumed by the
yast2 bootloader module from past days. Thus we consider
it obsolete and on the to be droped list in future releases.
This Fixes#746
kiwi writes optional grub boot parameters to the GRUB_CMDLINE_LINUX
variable in default/grub. This information is then picked up by
grub2-mkconfig and written to grub.cfg However there is also another
variable named GRUB_CMDLINE_LINUX_DEFAULT which according to the
documentation should be used preferably. While it does not seem to
matter for grub it matters for yast. Thus this patch changes the
configuration variable and fixes bsc#1084117
If kiwi generates its own efi image for the boot process
it does not setup the btrfs relative path setup in the
earlyboot script embedded into the generated efi image.
This has a bad impact on the file search because the
btrfs setup done in kiwi puts root below the @ volume
which we then need to specify of the relative lookup
is not activated. Fixes bsc#1082155
Grub wants to have linuxefi/initrdefi commands to execute Linux via the UEFI
calling convention on x86. However, all other platforms simply use the normal
linux/initrd commands, because there grub assumes that an EFI grub wants to
run an EFI payload.
Reflect this architecture difference in the generated grub configuration.
Signed-off-by: Alexander Graf <agraf@suse.de>
The boot option root=install:CDLABEL= is mandatory for install
images which uses the dracut initrd system. But for the custom
kiwi oemboot descriptions this is causing a problem when detecting
the install device. Thus the above boot option is only applied
for the initrd system which actually makes use of it
Provide the capabilities of the oem install code as
dracut module. The implementation covers the result
of the installiso="true" configuration. Installation
from remote sources still needs to be done and will
follow in an extra pull request. This addresses
Issue #576