When running on a laptop host: Host: hw.acpi.battery.rate: 17946 Guest: hw.acpi.battery.rate: 851050 This causes false warnings and possible automatic shutdown of the guest, depending on the battery monitor running.
Still seeing this issue with 13.1-RELEASE and virtualbox-ose-6.1.36. Tried changing kern.hz and kern.timecounter.hardware. Neither had any effect. Any suggestions appreciated.
I don't know whether this option is even available but check what you have set as Paravirtualization and try other options. This once fixed a time drift for me in a Linux guest on a Windows host.
(In reply to Daniel Tameling from comment #2) Thanks, no luck. Tried every possible paravirtualization setting, as well as every other system setting. None had any effect, except disabling I/O APIC, which caused a panic at boot. For now I had to remove xfce-battery-plugin, which was shutting down the system as soon as I log into any GUI, since the plugin registered itself for autostart. Lumina and LXQT were launching it as well.
(In reply to Jason W. Bacon from comment #3) BTW, there is no clock drift. It's just the batter rate that's off.
More info: I have verified that the problem occurs with FreeBSD 13.1-RELEASE and 13.2-BETA2 guests on a FreeBSD 13.1-RELEASE host, Lenovo T430, CPU specs below. A Debian 11 guest on the same laptop works fine. An identical FreeBSD 13.2-BETA2 guest on my Mac works fine under VirtualBox 7. === CPU: Intel(R) Core(TM) i5-3320M CPU @ 2.60GHz (2594.25-MHz K8-class CPU) Origin="GenuineIntel" Id=0x306a9 Family=0x6 Model=0x3a Stepping=9 Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE> Features2=0x7fbae3ff<SSE3,PCLMULQDQ,DTES64,MON,DS_CPL,VMX,SMX,EST,TM2,SSSE3,CX16,xTPR,PDCM,PCID,SSE4.1,SSE4.2,x2APIC,POPCNT,TSCDLT,AESNI,XSAVE,OSXSAVE,AVX,F16C,RDRAND> AMD Features=0x28100800<SYSCALL,NX,RDTSCP,LM> AMD Features2=0x1<LAHF> Structured Extended Features=0x281<FSGSBASE,SMEP,ERMS> Structured Extended Features3=0x9c000400<MD_CLEAR,IBPB,STIBP,L1DFL,SSBD> XSAVE Features=0x1<XSAVEOPT> VT-x: PAT,HLT,MTF,PAUSE,EPT,UG,VPID TSC: P-state invariant, performance statistics real memory = 8589934592 (8192 MB)