Skip to content

feat(host-dom0): add a dom0-only host kernel variant - #296

Merged
89luca89 merged 1 commit into
mainfrom
89luca89/res-155-host-kernel-optimizations
Nov 10, 2026
Merged

89luca89 merged 1 commit into
mainfrom
89luca89/res-155-host-kernel-optimizations

Conversation

@89luca89

@89luca89 89luca89 commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

As Xen installs boot the host kernel only as dom0, we can tailor a minimized kernel config in
order to reduce space and attack surface. This adds a host-dom0 variant on top of host,
published as host-dom0-kernel, while host stays as it is for KVM hosts.

Image Module squashfs Modules CVEs in built code CVEs avoided
x86_64 host 13.27 MB 92.8 MB 3,399 11,471 (64.3%)
x86_64 host-dom0 12.64 MB (−4.8%) 47.0 MB (−49.4%) 2,069 8,046 (45.1%) 3,425 (29.9%)
arm64 host 17.58 MB 90.1 MB 4,225 12,352 (69.3%)
arm64 host-dom0 12.59 MB (−28.4%) 41.2 MB (−54.2%) 2,203 8,277 (46.4%) 4,075 (33.0%)

We drop what a dom0 never runs, like KVM, VFIO, vhost and the x86 IOMMU and cpufreq drivers, and
what our hosts don't need, like audio, video, radios, legacy buses, host GPU drivers, unused
protocols and services, and arm64 platforms other than Graviton and Grace. Xen backends, cloud
NICs and disks, Hyper-V and Grace support stay.

CVEs are counted from the 17,828 kernel CNA records whose fix touches C code the build compiles;
all rows are lko builds of 6.18-lts 8a4c2881a (6.18.60). Switching protect's Xen installs to
host-dom0-kernel is a follow-up.

Fixes RES-155

As Xen installs boot the host kernel only as dom0, we can tailor a minimized
kernel config in order to reduce space and attack surface.

Signed-off-by: Luca Di Maio <luca.dimaio1@gmail.com>

@bleggett bleggett left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, the module savings are great.

We'll need to do some installer work to use a unique host kernel for Xen installs vs KVM, but that should be trivial and we should definitely do it.

@89luca89

Copy link
Copy Markdown
Contributor Author

In order to check that host-dom0 can replace the host kernel on Xen installs, I ran a smoke test on
an AWS m6i.xlarge with Ubuntu 24.04. I installed Edera Protect with the staging installer,
which sets up Xen with the current host kernel, then I installed host-dom0 the same way and rebooted
into it. On both kernels I checked that dom0 runs under Xen from the right image, that the Xen devices
and protect services are up, and that a zone can run a workload with network. Everything passed.

@89luca89

Copy link
Copy Markdown
Contributor Author

Merging this now, then @azenla we can decide the work on the installer, the tests, and next steps 👍

@89luca89
89luca89 merged commit 530e23b into main Nov 10, 2026
14 checks passed
@89luca89
89luca89 deleted the 89luca89/res-155-host-kernel-optimizations branch November 10, 2026 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants