Hello Adam Litke,
I'd like you to do a code review. Please visit
https://gerrit.ovirt.org/42968
to review the following change.
Change subject: Balloon should not work when guest agent is not present ......................................................................
Balloon should not work when guest agent is not present
StatAvg returns 0 when there is no data available. We need to use Stat here so we get None and properly fail the condition.
Change-Id: Ic164043259a2936243e572c14705afa064f92171 Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1232669 Signed-off-by: Martin Sivak msivak@redhat.com Reviewed-on: https://gerrit.ovirt.org/42207 Continuous-Integration: Jenkins CI Reviewed-by: Adam Litke alitke@redhat.com --- M vdsm/mom.d/02-balloon.policy 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/68/42968/1
diff --git a/vdsm/mom.d/02-balloon.policy b/vdsm/mom.d/02-balloon.policy index 570c751..b1af0d5 100644 --- a/vdsm/mom.d/02-balloon.policy +++ b/vdsm/mom.d/02-balloon.policy @@ -116,7 +116,7 @@ })
(with Guests guest - (if (valid guest.balloon_cur (guest.StatAvg "mem_unused")) + (if (valid guest.balloon_cur (guest.Stat "mem_unused")) (balloon_logic guest) (debug "Memory information is missing, ballooning for" guest "disabled")))