Martin Sivák has posted comments on this change. Change subject: Fix the way we compute cpu_load average and add tests for it ......................................................................
Patch Set 2: (3 comments) http://gerrit.ovirt.org/#/c/24783/2/ovirt_hosted_engine_ha/agent/constants.py.in File ovirt_hosted_engine_ha/agent/constants.py.in: Line 85: # Maximum request error count Line 86: MAX_ERROR_COUNT = 3 Line 87: Line 88: # The length of history Line 89: STATS_HISTORY_SECS = 150 > Seems like a short sampling period on which a migration decision might be m Fixed with 15*60 http://gerrit.ovirt.org/#/c/24783/2/ovirt_hosted_engine_ha/agent/states.py File ovirt_hosted_engine_ha/agent/states.py: Line 123: extra=log_filter.lf_args('score-mgmtbridge', Line 124: self.LF_PENALTY_INT)) Line 125: score -= score_cfg['mgmt-bridge-score-penalty'] Line 126: Line 127: # Compute cpu load average (not counting load caused by > I previously avoided the term "load average" because the cpu-load submonito Lets document that in the collector. I do not think it belongs to this patch. Line 128: # the engine vm. The default load penalty is: Line 129: # load 0-40% : 0 Line 130: # load 40-90%: 0 to 1000 (rising linearly with increasing load) Line 131: # load 90%+ : 1000 Line 129: # load 0-40% : 0 Line 130: # load 40-90%: 0 to 1000 (rising linearly with increasing load) Line 131: # load 90%+ : 1000 Line 132: # Thus, a load of 80% causes an 800 point penalty Line 133: load_average = load_factor(self.data) * 100.0 > Why *100? Leftover from testing. Removed. Line 134: Line 135: if score_cfg['cpu-load-penalty-max'] \ Line 136: == score_cfg['cpu-load-penalty-min']: Line 137: # Avoid divide by 0 in penalty calculation below -- To view, visit http://gerrit.ovirt.org/24783 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: Id9e05c753f41dcd94d5a4734ac39f90581ddc0c0 Gerrit-PatchSet: 2 Gerrit-Project: ovirt-hosted-engine-ha Gerrit-Branch: master Gerrit-Owner: Martin Sivák <[email protected]> Gerrit-Reviewer: Doron Fediuck <[email protected]> Gerrit-Reviewer: Greg Padgett <[email protected]> Gerrit-Reviewer: Jiří Moskovčák <[email protected]> Gerrit-Reviewer: Martin Sivák <[email protected]> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
