I use cacti-0.8.6h on fadora with cactid as poller.
Net-Snmp work fine, traps too.
Rancid scrpits.
I use cacti since 2 years, very fine ! Good job !!
I have created a new snmp query. But I have problem wit VALUE/REGEXP
I have created a datasource with 2 gauges (DrvCondition & PerCentRebuilded).
The snmp_query file is : hpDrvArray-LogDrvRaid.xml
Code: Select all
<hpIDALogicalDrvInstance>^
<name>Drive number</name>^
<method>walk</method>^
<source>value</source>^
<direction>input</direction>^
<oid>.1.3.6.1.4.1.232.3.2.3.1.1.2</oid>^
</hpIDALogicalDrvInstance>^
<hpIDALogicalDrvFTType>^
<name>FaulTolerant Type</name>^
<method>walk</method>^
<source>value</source>^
<direction>input</direction>^
<oid>.1.3.6.1.4.1.232.3.2.3.1.1.3</oid>^
</hpIDALogicalDrvFTType>^
<hpIDALogicalDrvSize>^
<name>Logical Drive Size in MB</name>^
<method>walk</method>^
<source>value</source>^
<direction>input</direction>^
<oid>.1.3.6.1.4.1.232.3.2.3.1.1.9</oid>^
</hpIDALogicalDrvSize>^
<hpIDALogicalDrvCondition>
<name>DrvRaidCondition></name>
<method>walk</method>
<source>VALUE/REGEXP:[a-zA-Z]{1,}\(([1-]{1})+\)$</source>
<direction>output</direction>
<oid>.1.3.6.1.4.1.232.3.2.3.1.1.11</oid>
</hpIDALogicalDrvCondition>
<hpIDALogicalDrvPerCentRebuild>^
<name>PerCentRebuild</name>^
<method>walk</method>^
<source>value</source>^
<direction>output</direction>^
<oid>.1.3.6.1.4.1.232.3.2.3.1.1.12</oid>^
</hpIDALogicalDrvPerCentRebuild>^
</fields>^
</interface>
snmpwalk -v2c -O QfntUe -c mysecret myhost .1.3.6.1.4.1.232.3.2.3.1.1.11
return this :
.1.3.6.1.4.1.232.3.2.3.1.1.11.0.1 = 2
but with -O fntUe return this :
.1.3.6.1.4.1.232.3.2.3.1.1.11.0.1 = INTEGER: ok(2)
When I run : cactid --verbosity=5 27 27
CACTID: Host[27] DS[509] SNMP: v2: myIP, dsname: DrvCondition, oid: .1.3.6.1.4.1.232.3.2.3.1.1.11.0.1, value: U
I have tested with php cmd.php 27 27
09/04/2007 08:31:01 PM - CMDPHP: Poller[0] Host[27] DS[509] WARNING: Result from SNMP not valid. Partial Result: ok(2 Note the missed ')' !
I have read a lot in this forum, modify the regexp, but no solutions.
My question : does the VALUE/REGEXP in output direction item work ?
Where I have done a mistake ?
What the best way to find a solution ?
Thank a lot for help.