I have a number of systems that do not respond to SNMP queries from a default Cacti build (which is a great tool by the way). Testing shows that these systems only respond to SNMP v2c queries. Is there a way to get Cacti to generate these, and even better, is there a way to include this as an option for SNMP data gets in the GUI?
Thanks,
Ken
SNMPv2c queries with Cacti
Moderators: Developers, Moderators
This is not conplete solution just some hints. First of all you need to turn off buil-it PHP snmp support because it does not handle v2c queries (in include/config.php replace line 59 with "$config["php_snmp_support"] = false").
The rest of work need to be done in include/snmp_functions.php. There are two snmp related functions here: "cacti_snmp_get" and "cacti_snmp_walk". The first one is actually ready to take version string as a parameter ($force_version variable). The second one should be changed in similar way. Then you need to find all places where these functions are called and add "-v2c" as a last parameter.
- bulek
The rest of work need to be done in include/snmp_functions.php. There are two snmp related functions here: "cacti_snmp_get" and "cacti_snmp_walk". The first one is actually ready to take version string as a parameter ($force_version variable). The second one should be changed in similar way. Then you need to find all places where these functions are called and add "-v2c" as a last parameter.
- bulek
I did almost the same ads this suggestion
if you want to still use the faster built in support for non v2c hosts then change that same line to . It almost looks like thats what Rax was trying to do below. its more like line 165 in cacti-0.81
$config["php_snmp_support"] = true && $version != "2").
this way built in support still works for all the other hosts.
if you use v3 then prolly the same answer like:
$config["php_snmp_support"] = true && $version != "2" && $version != "3").
$config["php_snmp_support"] = true && $version != "2").
this way built in support still works for all the other hosts.
if you use v3 then prolly the same answer like:
$config["php_snmp_support"] = true && $version != "2" && $version != "3").
Who is online
Users browsing this forum: No registered users and 3 guests