We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The swapfree and memfree codes is diffrent,but their the logic of the judgement is the same,and the result should be same I modify follows:
if ($plugin->opts->item eq 'memfree') {
# -- add 100 - make the free become avaliable $data_val = 100 - getPercentage('memtotal',$data_val);
}
if($plugin->opts->item eq 'memfree') { $plugin->set_thresholds(warning => (100 - $plugin->opts->warning), critical => (100 - $plugin->opts->critical));
# -- add 2 lines make the display value and actual match $output_val = 100-$data_val; $output_text = $plugin->opts->item . " = " . $output_val;
} else { $plugin->set_thresholds(warning => $plugin->opts->warning, critical => $plugin->opts->critical); }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The swapfree and memfree codes is diffrent,but their the logic of the judgement is the same,and the result should be same
I modify follows:
if ($plugin->opts->item eq 'memfree') {
}
if($plugin->opts->item eq 'memfree') {
$plugin->set_thresholds(warning => (100 - $plugin->opts->warning), critical => (100 - $plugin->opts->critical));
} else {
$plugin->set_thresholds(warning => $plugin->opts->warning, critical => $plugin->opts->critical);
}
The text was updated successfully, but these errors were encountered: