Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- capsd-configuration.xml:
- <protocol-plugin protocol="ALLNET-SENSORS" class-name="org.opennms.netmgt.capsd.plugins.HttpPlugin" scan="on" user-defined="true">
- <property key="port" value="80" />
- <property key="timeout" value="5000" />
- <property key="retry" value="2" />
- <property key="url" value="/xml"/>
- </protocol-plugin>
- collectd-configuration.xml:
- <package name="example1">
- <filter>IPADDR != '0.0.0.0'</filter>
- <include-range begin="1.1.1.1" end="254.254.254.254"/>
- .....
- <service name="ALLNET-SENSORS" interval="300000" user-defined="false" status="on" >
- <parameter key="collection" value="ALLNET" />
- <parameter key="timeout" value="5000" />
- <parameter key="retry" value="2" />
- </service>
- </package>
- <collector service="ALLNET-SENSORS" class-name="org.opennms.netmgt.collectd.HttpCollector" />
- http-datacollection-config.xml:
- <http-collection name="ALLNET">
- <rrd step="300">
- <rra>RRA:AVERAGE:0.5:1:2016</rra>
- <rra>RRA:AVERAGE:0.5:12:1488</rra>
- <rra>RRA:AVERAGE:0.5:288:366</rra>
- <rra>RRA:MAX:0.5:288:366</rra>
- <rra>RRA:MIN:0.5:288:366</rra>
- </rrd>
- <uris>
- <uri name="XML">
- <url path="/xml"
- matches=".*<devicename>(.*)<\/devicename>.*<n0>(.*)<\/n0>.*<t0>(.*)<\/t0>.*<min0>(.*)<\/min0>.*<max0>(.*)<\/max0>.*<n1>(.*)<\/n1>.*<t1>(.*)<\/t1>.*<min1>(.*)<\/min1>.*<max1>(.*)<\/max1>.*<n2>(.*)<\/n2>.*<t2>(.*)<\/t2>.*<min2>(.*)<\/min2>.*<max2>(.*)<\/max2>.*<n3>(.*)<\/n3>.*<t3>(.*)<\/t3>.*<min3>(.*)<\/min3>.*<max3>(.*)<\/max3>.*<n4>(.*)<\/n4>.*<t4>(.*)<\/t4>.*<min4>(.*)<\/min4>.*<max4>(.*)<\/max4>.*<n5>(.*)<\/n5>.*<t5>(.*)<\/t5>.*<min5>(.*)<\/min5>.*<max5>(.*)<\/max5>.*<n6>(.*)<\/n6>.*<t6>(.*)<\/t6>.*<min6>(.*)<\/min6>.*<max6>(.*)<\/max6>.*<n7>(.*)<\/n7>.*<t7>(.*)<\/t7>.*<min7>(.*)<\/min7>.*<max7>(.*)<\/max7>.*<n8>(.*)<\/n8>.*<t8>(.*)<\/t8>.*<min8>(.*)<\/min8>.*<max8>(.*)<\/max8>.*<n9>(.*)<\/n9>.*<t9>(.*)<\/t9>.*<min9>(.*)<\/min9>.*<max9>(.*)<\/max9>.*"
- response-range="100-399" >
- </url>
- <attributes>
- <attrib alias="wsSensor0Value" match-group="3" type="gauge32"/>
- <attrib alias="wsSensor0Min" match-group="4" type="gauge32"/>
- <attrib alias="wsSensor0Max" match-group="5" type="gauge32"/>
- <attrib alias="wsSensor1Value" match-group="7" type="gauge32"/>
- <attrib alias="wsSensor1Min" match-group="8" type="gauge32"/>
- <attrib alias="wsSensor1Max" match-group="9" type="gauge32"/>
- <attrib alias="wsSensor2Value" match-group="11" type="gauge32"/>
- <attrib alias="wsSensor2Min" match-group="12" type="gauge32"/>
- <attrib alias="wsSensor2Max" match-group="13" type="gauge32"/>
- <attrib alias="wsSensor3Value" match-group="15" type="gauge32"/>
- <attrib alias="wsSensor3Min" match-group="16" type="gauge32"/>
- <attrib alias="wsSensor3Max" match-group="17" type="gauge32"/>
- <attrib alias="wsSensor4Value" match-group="19" type="gauge32"/>
- <attrib alias="wsSensor4Min" match-group="20" type="gauge32"/>
- <attrib alias="wsSensor4Max" match-group="21" type="gauge32"/>
- <attrib alias="wsSensor5Value" match-group="23" type="gauge32"/>
- <attrib alias="wsSensor5Min" match-group="24" type="gauge32"/>
- <attrib alias="wsSensor5Max" match-group="25" type="gauge32"/>
- <attrib alias="wsSensor6Value" match-group="27" type="gauge32"/>
- <attrib alias="wsSensor6Min" match-group="28" type="gauge32"/>
- <attrib alias="wsSensor6Max" match-group="29" type="gauge32"/>
- <attrib alias="wsSensor7Value" match-group="31" type="gauge32"/>
- <attrib alias="wsSensor7Min" match-group="32" type="gauge32"/>
- <attrib alias="wsSensor7Max" match-group="33" type="gauge32"/>
- <attrib alias="wsSensor8Value" match-group="35" type="gauge32"/>
- <attrib alias="wsSensor8Min" match-group="36" type="gauge32"/>
- <attrib alias="wsSensor8Max" match-group="37" type="gauge32"/>
- <attrib alias="wsSensor9Value" match-group="39" type="gauge32"/>
- <attrib alias="wsSensor9Min" match-group="40" type="gauge32"/>
- <attrib alias="wsSensor9Max" match-group="41" type="gauge32"/>
- </attributes>
- </uri>
- </uris>
- </http-collection>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement