Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug report.
Summary: Bad cpuTime retrieved from Sys::Virt::Domain->get_info
Product: Fedora Extras
Description of problem:
I tried the API on a AMD Athlon(tm) XP 3000+, I got bad values with some
negative one for the cpuTime of a domain.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Run a server with some xen domains
2. Try the example included in the package:
3. Observe the "cpuTime" values
I search the sources and I found this value is in fact unsigned long long value
in libvirt library to represent nanoseconds (cf
). I didn't try on a
64 bits arch but I think the it could work on it.
I managed to obtain the expected results by patching the sources: I edit Virt.xs
from the source and changed the line 359 from:
hv_store (RETVAL, "cpuTime", 7, newSViv(info.cpuTime), 0);
hv_store (RETVAL, "cpuTime", 7, newSVnv(info.cpuTime), 0);
So the unsigned long long is read as a float scalar and not an integer scalar.
Configure bugmail: https://bugzilla.redhat.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.