Adam Litke has uploaded a new change for review. Change subject: Fix ever increasing CPU usage ......................................................................
Fix ever increasing CPU usage In the HostKSM collector we are calculating the number of jiffies that have been used since the last collection period. Unfortunately we never reset self.last_jiff so our count accumulates indefinitely. Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=999615 Signed-off-by: Adam Litke <[email protected]> Change-Id: I434dfc454776c8eeb1e2a074132d7b94ca68883f --- M mom/Collectors/HostKSM.py 1 file changed, 1 insertion(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/mom refs/changes/20/18420/1 diff --git a/mom/Collectors/HostKSM.py b/mom/Collectors/HostKSM.py index 5f6f8eb..20ad613 100644 --- a/mom/Collectors/HostKSM.py +++ b/mom/Collectors/HostKSM.py @@ -72,6 +72,7 @@ interval_jiffs = (cur_jiff - self.last_jiff) % 2**32 total_jiffs = os.sysconf('SC_CLK_TCK') * self.interval # Calculate percentage of total jiffies during this interval. + self.last_jiff = cur_jiff return 100 * interval_jiffs / total_jiffs def get_shareable_mem(self): -- To view, visit http://gerrit.ovirt.org/18420 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I434dfc454776c8eeb1e2a074132d7b94ca68883f Gerrit-PatchSet: 1 Gerrit-Project: mom Gerrit-Branch: master Gerrit-Owner: Adam Litke <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
