Skip to content

A major update to the Microkernel kernel

Compare
Choose a tag to compare
@tjmcs tjmcs released this 03 Oct 22:34
· 25 commits to master since this release

This release of the Hanlon-Microkernel has a number of improvements over previous releases; among them are the following new features/enhancements:

  • We've modified the build process so that the new Microkernel is based on a much more recent version of TinyCore Linux; previous releases were based on TCL-4.x builds which were in turn based on a 3.0.x version of the Linux kernel, whereas this release is based on the latest, TCL-5.4, builds which are in turn based on a 3.8.13 version of the Linux kernel. This should provide much better support for newer hardware directly out of the Microkernel.
  • We changed the mechanism for bundling additional kernel modules and TinyCore Linux extensions significantly. Previously, adding kernel modules or additional TCEs that were needed during the Microkernel boot process required that the user customize the bundle build script itself (and perhaps the underlying Microkernel codebase), essentially requiring that the user customize the Hanlon-Microkernel project itself in order to build a custom Microkernel. This version of the Hanlon-Microkernel adds two additional flags that can be used to specify additional kernel modules (-a, --addtnl-kmods=FILE) or TinyCore Linux Extensions (-l, --local-extents=FILE) that each point to a file on the local filesytem (the format for these files is outlined, below) that list the tcz or Debian Wheeze packages containing the kernel modules or extensions to add to the bundle. This means that extending the Microkernel to support new hardware or capabilities at boot time is now much simpler, requiring only the creation of a few files in the local filesystem.
  • Added code to support the collection of IPMI-related meta-data by the Microkernel (and reporting of those facts back to the Hanlon server) if the ipmitool is available locally on the Microkernel. This is in preparation for adding the ability to control the power state of a node to the node slice's RESTful API in the near future (provided there is a Baseboard Management Controller, or BMC, attached to the node).
  • Fixed a bug in the SMBIOS UUID reported back to Hanlon by the Microkernel. This resulted from the fact that the lshw utility used by the Microkernel to gather this value from the underlying hardware was, on some hardware, reporting an incorrect value for this field (the hexidecimal values representing the underlying SMBIOS UUID were returned in the wrong order by lshw). This resulted in an infinite sequence of boots into the Microkernel as soon as a node that had identified itself using this SMBIOS UUID was bound to an underlying model by a policy, since the SMBIOS UUID value returned by the Microkernel didn't match the (actual) value reported to Hanlon when requesting an iPXE-boot script to use for that node. Fortunately, the resolution was simply to use the dmidecode utilty to obtain this information instead of the lshw utility, since the dmidecode utility didn't suffer from this problem.
  • Fixed a bug in the script used when starting the udhcpc client in the Microkernel; with this bug fix in place a default route is now being setup for the network, allowing for access to the world outside of the Hanlon subnet.

With these changes in place, it should now be much easier to build your own custom Microkernel, and the Microkernel that you build should be useable with more modern hardware than was previously supported.

One final note: here, we show an example of the new bundle build process and the two new files that we've created in order to extend the standard Microkernel to support a custom networking card (an Emulex 10Gbe CNA) and the drivers and utilities used to collect IPMI-related facts within the Microkernel and report those facts back to Hanlon:

$ ./build-bundle-file.sh -b additional-build-files/builtin-extensions.lst \
    -m additional-build-files/mirror-extensions.lst \
    -l additional-build-files/local-extensions.lst \
    -a additional-build-files/addtnl-driver-mods.lst -d 2>&1 | tee t.t

as you can see, we've assigned files to the two new options added to this shell script (the last two options in the command); the contents of those files are as follows:

$ cat additional-build-files/local-extensions.lst
extra-extensions/open-vm-tools-modules-3.8.13-tinycore.tcz
extra-extensions/OpenIPMI-2.0.21.tcz
extra-extensions/freeipmi-1.4.5.tcz
extra-extensions/ipmitool-1.8.14.tcz
$ 

and

$ cat additional-build-files/addtnl-driver-mods.lst
extra-driver-files/be2net.tcz               be2net.ko           net/ethernet/emulex/benet/be2net.ko.gz
extra-driver-files/ipmi-kernel-mods.tcz     ipmi_msghandler.ko  char/ipmi/ipmi_msghandler.ko.gz
extra-driver-files/ipmi-kernel-mods.tcz     ipmi_si.ko          char/ipmi/ipmi_si.ko.gz
extra-driver-files/ipmi-kernel-mods.tcz     ipmi_devintf.ko     char/ipmi/ipmi_devintf.ko.gz
extra-driver-files/ipmi-kernel-mods.tcz     ipmi_poweroff.ko    char/ipmi/ipmi_poweroff.ko.gz
extra-driver-files/ipmi-kernel-mods.tcz     ipmi_watchdog.ko    char/ipmi/ipmi_watchdog.ko.gz
$ 

The first file is simply a list of the locations of the additional extensions from the local filesystem that should be included in the bundle (and installed during the bundle boot process). This includes an extension containing the open_vm_tools and several IPMI-related tools that will be used by the Microkernel. The second file contains a list of the kernel modules that should be installed during the bundle boot process. As you can see, the file has a format that lists one line per kernel module, with three fields on each line (the location of the tcz or Debian Wheezy file containing the kernel module in question, the name of the module itself, and the location where it should be installed under the standard filesystem location used in TinyCore Linux (/usr/local/lib/modules/uname -r/kernel/drivers). Once these two files have been defined, and the appropriate files are placed into the directories shown in the files, above:

$ ls extra-extensions/
freeipmi-1.4.5.tcz          ipmitool-1.8.14.tcz.md5.txt  open-vm-tools-modules-3.8.13-tinycore.tcz
freeipmi-1.4.5.tcz.md5.txt  OpenIPMI-2.0.21.tcz          open-vm-tools-modules-3.8.13-tinycore.tcz.list
ipmitool-1.8.14.tcz         OpenIPMI-2.0.21.tcz.md5.txt  open-vm-tools-modules-3.8.13-tinycore.tcz.md5.txt
$ 

and

$ ls extra-driver-files/
be2net.deb  be2net.tcz  be2net.tcz.md5.txt  ipmi-kernel-mods.tcz  ipmi-kernel-mods.tcz.md5.txt
$ 

building the bundle file used to build our customized Hanlon-Microkernel (with support for those Emulex CNAs and support for gathering IPMI-related meta-data and reporting it back to Hanlon) is a simple, one-line command.