Merge lp://qastaging/~freyes/charms/trusty/nrpe/lp1578815 into lp://qastaging/charms/trusty/nrpe

Proposed by Felipe Reyes
Status: Merged
Merged at revision: 42
Proposed branch: lp://qastaging/~freyes/charms/trusty/nrpe/lp1578815
Merge into: lp://qastaging/charms/trusty/nrpe
Diff against target: 55 lines (+17/-4)
2 files modified
config.yaml (+5/-2)
hooks/nrpe_helpers.py (+12/-2)
To merge this branch: bzr merge lp://qastaging/~freyes/charms/trusty/nrpe/lp1578815
Reviewer Review Type Date Requested Status
Review Queue (community) automated testing Needs Fixing
Jorge Niedbalski (community) Needs Fixing
Review via email: mp+293949@code.qastaging.launchpad.net

Description of the change

Dear Charmers,

This patch adds support to auto calculate an appropriate average load threshold for different kind of machines, when the `load` config option is set to 'auto', the threshold for warning is set to NUM_PROCS*0.7 and for critical is NUM_PROCS.

Best,

To post a comment you must log in.
Revision history for this message
Jorge Niedbalski (niedbalski) wrote :

Thanks Felipe, Please review the comments in the code.

review: Needs Fixing
44. By Felipe Reyes

Remove round() when calculating warning threshold

Revision history for this message
Felipe Reyes (freyes) wrote :

Jorge, thanks for taking the time to review this MP, I just pushed a commit that addresses your feedback.

Thanks

45. By Felipe Reyes

Format warn threshold as float

Revision history for this message
Jorge Niedbalski (niedbalski) wrote :

Hello,

I verified that your latest patch fixes the issue previously reported.

I just deployed nrpe on top of a 2 cores machines, and this gets configured correctly with the
load setting set to auto.

root@juju-niedbalski-sec-machine-16:/home/ubuntu# nproc
2
root@juju-niedbalski-sec-machine-16:/home/ubuntu# cat /etc/nagios/nrpe.d/check_load_sub.cfg
# System Load (sub)
command[check_load_sub]=/usr/lib/nagios/plugins/check_load -w 1.4,1.4,1.4 -c 2,2,2

Revision history for this message
Review Queue (review-queue) wrote :

This item has failed automated testing! Results available here http://juju-ci.vapour.ws:8080/job/charm-bundle-test-lxc/4031/

review: Needs Fixing (automated testing)
Revision history for this message
Review Queue (review-queue) wrote :

This item has failed automated testing! Results available here http://juju-ci.vapour.ws:8080/job/charm-bundle-test-aws/4045/

review: Needs Fixing (automated testing)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to all changes: