Skip to content

[Req]: Option to disable KVM-clock without disabling KVM in general #580

@llsant

Description

@llsant

Component

Other

What problem are you facing?

While running VirtualBox on Windows 11, with a Debian 13 UEFI guest, I can enable KVM paravirtualization to make it faster. However, by default, that also includes the kvm-clock clocksource as seen by the guest. An apparently frequent issue is that kvm-clock is not precise, the system date lags back, dmesg shows kernel warnings about clock skips and things such as a ping command (which runs once per second) may get very irregular.

For me, the tsc clocksource works much better. So I put "no-kvmclock" in the bootloader cmdline to tell the Debian 13 guest not to use that clocksource, while keeping KVM enabled in VirtualBox to have better performance than with full virtualization. However, detecting the problem, finding the correct parameter, editing the bootloader config and rebooting is a bit cumbersome.

How can we fix this?

Ideally, add an option to disable support for the KVM clock without disabling all of KVM. Maybe this is not possible, I don't know if the KVM API requires to expose the clock to the guest for full compliance. But in case this is not mandatory, being able to enable KVM but disable KVM-clock from VirtualBox would be more convenient than doing so by modifying the guest bootloader cmdline.

What alternatives or workarounds exist?

Modifying the guest bootloader and adding the "no-kvmclock" option.

Anything else we should know?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions