-
Notifications
You must be signed in to change notification settings - Fork 44
Booting HermitCore from an ISO image
Beside the registration of HermitCore's loader to the Linux system, it is also possible to build an ISO image and to boot from this image. Such images could be used to run HermitCore applications on top of a OpenStack cluster.
In this example, an image will be created for the application stream. At first, we have to create a directory with all required files.
mkdir -p isodir/boot/grub
cp /opt/hermit/x86_64-hermit/extra/benchmarks/stream isodir/boot/
cp /opt/hermit/bin/ldhermit.elf isodir/boot/
Afterwards, the configuration file isodir/boot/grub.cfg
has been created for the bootloader GRUB.
In this case, the configuration file looks as follows:
default=0
timeout=0
menuentry "stream" {
multiboot /boot/ldhermit.elf -uart=io:0x3f8
module /boot/stream
boot
}
Sometimes it is useful to define the IO port for the UART device as kernel parameter because is currently not able to detect all existing UART devices.
In this example, we define 0x3f8
as IO port.
Finally, we create the ISO image with the tool grub-mkrescue
.
grub-mkrescue -o stream.iso isodir
Now, you are able to upload the ISO image to OpenStack and to create an instance from this file. If you start this instance, you will see the results of the stream benchmarks in the log files.