diff options
author | Karl DeBisschop <kdebisschop@users.sourceforge.net> | 2003-05-09 03:00:34 +0000 |
---|---|---|
committer | Karl DeBisschop <kdebisschop@users.sourceforge.net> | 2003-05-09 03:00:34 +0000 |
commit | cea584f3f2038bb97c9210e6d9a6c85023b9f001 (patch) | |
tree | 6d0d26c86a2bb4c9dac2acb6ae1c1ad40cf50361 /plugins | |
parent | 035f1eb259e414cf9133ae7d8286437f11f86766 (diff) | |
download | monitoring-plugins-cea584f3f2038bb97c9210e6d9a6c85023b9f001.tar.gz |
cause snmpget try try for 1 second less than the timeout (allowing plugin to force close if needed)
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/branches/release-1.3.0@501 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/check_snmp.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/plugins/check_snmp.c b/plugins/check_snmp.c index e744e041..2db4ecfa 100644 --- a/plugins/check_snmp.c +++ b/plugins/check_snmp.c | |||
@@ -233,8 +233,9 @@ main (int argc, char **argv) | |||
233 | usage ("Incorrect arguments supplied\n"); | 233 | usage ("Incorrect arguments supplied\n"); |
234 | 234 | ||
235 | /* create the command line to execute */ | 235 | /* create the command line to execute */ |
236 | asprintf (&command_line, "%s -m %s -v %s %s %s:%s %s", | 236 | asprintf (&command_line, "%s -t 1 -r %d -m %s -v %s %s %s:%s %s", |
237 | PATH_TO_SNMPGET, miblist, proto, authpriv, server_address, port, oid); | 237 | PATH_TO_SNMPGET, timeout_interval - 1, miblist, proto, |
238 | authpriv, server_address, port, oid); | ||
238 | if (verbose) | 239 | if (verbose) |
239 | printf ("%s\n", command_line); | 240 | printf ("%s\n", command_line); |
240 | 241 | ||