[pve-devel] Fwd: Bug#986371: Indeed this should work (also adding trivial test-case)
Chris Hofstaedtler
zeha at debian.org
Tue Apr 6 20:48:28 CEST 2021
Hi,
I believe you'll find Debian bug #986371 of interest. In Kernels
5.10+ the "guest time" accounting appears to be broken, in both
Debian and Ubuntu. See https://bugs.debian.org/986371 for further
details.
Best,
Chris
From: Christian Ehrhardt <christian.ehrhardt at canonical.com>
Subject: Bug#986371: Indeed this should work (also adding trivial test-case)
Hi,
we had Delta in Ubuntu a long long time ago, but afaik there isn't any
delta-need for years.
To be clear, guest time as well as the guest visibility into steal
time is very useful, but there shouldn't be any lack of it in Debian.
I had a try in (an old) debian 10.1 with 5.7.0-2-amd64
And there I can see the accounting moving just fine
ubuntu at debian:~$ cat /proc/stat
cpu 196 0 259 9243 60 0 1 23 0 0
cpu0 82 0 172 4579 39 0 1 10 0 0
qemu-system-x86_64 -nodefaults -nographic -accel kvm
# wait a few seconds, and then abort it
ubuntu at debian:~$ cat /proc/stat
cpu 213 0 283 10926 73 0 4 32 7 0
cpu0 98 0 193 5397 52 0 3 15 7 0
cpu1 115 0 90 5528 20 0 0 16 0 0
The 7 seconds of boring some rom startup code is the accounting that
you are looking for.
Also as you can see in [1] there isn't any architecture note on this
anymore (and I think there only was for steal time). So it really
should work and does so in my experiment above.
The original change is even in the history git pre 2.6.12 and the
latter modifications are not new wither [2][3]
I was updating and rebooting into 5.10.0-5-amd64 and I can confirm
that it no longer works.
(The same experiment as above)
I've looked at the Ubuntu kernels for groovy [4] and hirsute [5], but
found no related Delta on a quick check. IIRC the last upstream change
[6] in that area was around v5.5 - so there should be no change.
IMHO a kernel bug would be appropriate, @mjt I think you could even
just re-target this one, there is no need to make it a different bug.
@Thomas if instead you want to file a new bug, then look at [7]
[1]: https://www.kernel.org/doc/html/latest/filesystems/proc.html#miscellaneous-kernel-statistics-in-proc-stat
[2]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=ce0e7b28
[3]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c574358e
[4]: https://kernel.ubuntu.com/git/ubuntu/ubuntu-groovy.git/
[5]: https://kernel.ubuntu.com/git/ubuntu/ubuntu-hirsute.git/
[6]: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=5720821b
[7]: https://wiki.debian.org/DebianKernelReportingBugs
More information about the pve-devel
mailing list