Timekeeping in stable/9
Martin Sugioarto
martin at sugioarto.com
Sat Jan 21 13:20:55 UTC 2012
Am Sat, 21 Jan 2012 14:30:53 +0200
schrieb Alexander Motin <mav at FreeBSD.org>:
Hi Alexander,
> I am not using VirtualBox right now, so I'll need to setup it to test
> this. Meanwhile you could try to experiment with switching to
> different timecounters and eventtimers. May be some change in 9.0
> changed default timecounter for you, causing the problem.
I think we have a misunderstanding here. The host (FreeBSD 9.0R) works
fine. The time is being updated under heavy load without problems.
I already said that this seems to be an application problem and this
email(s) should be rather seen by the VBox maintainer. The problem is
that VBox seems to stop working properly when you put heavy CPU load on
the host. It even does not keep the clock up-to-date.
I can desync the guest clock to -1 minute in a few seconds, just by
running "openssl speed -multi 20".
> timecounter wrap should be the main cause of time drift (if
> timecounter hardware is emulated correctly at all). Different
> timecounters have different wrap periods that can be calculated by
> dividing kern.timecounter.tc.X.mask on
> kern.timecounter.tc.X.frequency. In my case there are: 300s for HPET,
> 5s for ACPI-fast, 2s for TSC and 55ms for i8254. If system won't get
> timer interrupts within half of that time -- time will drift. Start
> from looking what you are using and how good it is in your case.
This is my current timecounter setting:
kern.timecounter.choice: TSC-low(1000) HPET(950) i8254(0)
ACPI-fast(900) dummy(-1000000)
kern.timecounter.hardware: TSC-low
kern.timecounter.tc.ACPI-fast.mask: 16777215
kern.timecounter.tc.ACPI-fast.counter: 10400371
kern.timecounter.tc.ACPI-fast.frequency: 3579545
kern.timecounter.tc.ACPI-fast.quality: 900
kern.timecounter.tc.i8254.mask: 65535
kern.timecounter.tc.i8254.counter: 41849
kern.timecounter.tc.i8254.frequency: 1193182
kern.timecounter.tc.i8254.quality: 0
kern.timecounter.tc.HPET.mask: 4294967295
kern.timecounter.tc.HPET.counter: 3255982446
kern.timecounter.tc.HPET.frequency: 14318180
kern.timecounter.tc.HPET.quality: 950
kern.timecounter.tc.TSC-low.mask: 4294967295
kern.timecounter.tc.TSC-low.counter: 1587561917
kern.timecounter.tc.TSC-low.frequency: 8593928
kern.timecounter.tc.TSC-low.quality: 1000
kern.timecounter.smp_tsc: 1
kern.timecounter.invariant_tsc: 1
I can try other timer counter settings, if you think it will improve
responsivity inside VBox guest.
--
Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20120121/ddfdd09b/signature.pgp
More information about the freebsd-stable
mailing list