From ff20b34895ef70623c60f763519bd525e595383e Mon Sep 17 00:00:00 2001 From: Benoit Plessis Date: Fri, 4 Oct 2019 11:06:15 +0200 Subject: [PATCH] Add a warning when trying to activate bulktransferts on an SNMP v1 host --- src/snmp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/snmp.c b/src/snmp.c index 5002f7f7..6b7b1ae7 100644 --- a/src/snmp.c +++ b/src/snmp.c @@ -821,6 +821,9 @@ static int csnmp_config_add_host(oconfig_item_t *ci) { status = -1; break; } + if (hd->bulk_size > 0 && hd->version < 2) { + WARNING("snmp plugin: Bulk transferts is only available for snmp v2 and later, host '%s' is configured as version '%d'", hd->name, hd->version ); + } if (hd->version == 3) { if (hd->username == NULL) { WARNING("snmp plugin: `Username' not given for host `%s'", hd->name); -- 2.11.0