Re: Failing to graph bash script output

Gandalf <[email protected]>
Newsgroups gmane.network.cacti.user
Message-ID <[email protected]>
Please see http://docs.cacti.net/manual:087:4_help.2_debugging#debugging for help
Reinhard

On 26.04.2012 11:37, James Bensley wrote:
> I am trying to graph a non-SNMP device (24 port PDU) via a bash
> script, the script takes a single argument of the device IP and
> outputs as follows (giving each socket usage in amps);
> 
> james.bensley@dill:/usr/share/cacti/site/scripts$ ./em40-pdu.sh 10.224.142.102
> Socket1:0.37 Socket2:0.28 Socket3:0.22 Socket4:0.34 Socket5:0.23
> Socket6:0.45 Socket7:0.02 Socket8:0.02 Socket9:0.02 Socket10:0.02
> Socket11:0.02 Socket12:0.02 Socket13:0.02 Socket14:0.02 Socket15:0.02
> Socket16:0.02 Socket17:0.02 Socket18:0.02 Socket19:0.02 Socket20:0.02
> Socket21:0.02 Socket22:0.02 Socket23:0.92 Socket24:0.15
> 
> The rrd file is looking like this though;
> 
> rrdtool fetch /var/lib/cacti/rra/rs-pdu2_socket1_10718.rrd AVERAGE -s 1335429600
>                         Socket1             Socket2
> Socket3             Socket4             Socket5             Socket6
>          Socket7             Socket8             Socket9
> Socket10            Socket11            Socket13            Socket12
>          Socket14            Socket15            Socket17
> Socket16            Socket18            Socket19            Socket20
>          Socket21            Socket22            Socket23
> Socket24
> 
> 1335429900: 1.2709030100e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335430200: 1.2344604236e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335430500: 1.2333333333e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335430800: 1.2333333333e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335431100: 1.2333333333e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335431400: 1.2333333333e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 1335431700: 1.2656666667e-03 nan nan nan nan nan nan nan nan nan nan
> nan nan nan nan nan nan nan nan nan nan nan nan nan
> 
> So only "Socket1" is storing a value that as you can see from the
> script output above, is not the current value (0.37 amps). Clearly the
> data somewhere isn't being passed correctly but I have tripled checked
> and can't find where. I can't help but think I'm either missing
> something really obvious or its a problem some somewhere in Cacti. Has
> anyone seen anything like this before or done anything like this
> before and has some input into my problem?
> 
> Many thanks,
> James.
> 
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and 
> threat landscape has changed and how IT managers can respond. Discussions 
> will include endpoint security, mobile security and the latest in malware 
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> cacti-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/cacti-user
> 

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.