graph is blank despite SNMP data

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
duffrecords
Posts: 10
Joined: Fri Aug 03, 2012 6:58 pm

graph is blank despite SNMP data

Post by duffrecords »

I started using the Tripp-Lite PowerAlert script but I'm missing data in one of the graphs. I have two UPSs with a Windows box acting as an SNMP proxy. I can successfully snmpwalk both UPSs and the script works when run manually but Load Capacity data is only appearing in one of the UPS graphs. I've tried rebuilding the poller cache but that didn't fix it.

Code: Select all

root@controller:~# php -q /var/www/cacti/scripts/ss_poweralert_ups_status.php hostname.redacted.com:2:tlremote:::::::3664:500 get outputload 1
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0
33
root@controller:~# php -q /var/www/cacti/scripts/ss_poweralert_ups_status.php hostname.redacted.com:2:tlremote:::::::3664:500 get outputload 2
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0
29
I noticed that one of the RRD files is not being updated. That's probably the empty graph:

Code: Select all

root@controller:~# ls -l /var/www/cacti/rra/pdu_inputfrequency_59*
-rw-r--r-- 1 www-data www-data 282112 2012-08-07 11:21 /var/www/cacti/rra/UPS_inputfrequency_590.rrd
-rw-r--r-- 1 www-data www-data 282112 2012-08-07 11:21 /var/www/cacti/rra/UPS_inputfrequency_591.rrd
-rw-r--r-- 1 www-data www-data 282112 2012-08-07 11:21 /var/www/cacti/rra/UPS_inputfrequency_592.rrd
-rw-r--r-- 1 www-data www-data 282112 2012-08-06 17:11 /var/www/cacti/rra/UPS_inputfrequency_593.rrd
-rw-r--r-- 1 www-data www-data 282112 2012-08-07 11:21 /var/www/cacti/rra/UPS_inputfrequency_594.rrd
-rw-r--r-- 1 www-data www-data 282112 2012-08-07 11:21 /var/www/cacti/rra/UPS_inputfrequency_595.rrd
Attachments
Screen shot 2012-08-07 at 11.23.46 AM.png
Screen shot 2012-08-07 at 11.23.46 AM.png (21.45 KiB) Viewed 1872 times
duffrecords
Posts: 10
Joined: Fri Aug 03, 2012 6:58 pm

Re: graph is blank despite SNMP data

Post by duffrecords »

With log debugging:

Code: Select all

08/07/2012 02:41:43 PM - PHPSVR: Poller[0] DEBUG: PID[2247] CTR[4] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 2'
08/07/2012 02:41:43 PM - CMDPHP: Poller[0] Host[39] DS[596] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 2, output: FATAL: U
08/07/2012 02:41:43 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/ups_inputfrequency_592.rrd --template outputLoad:batteryCharge 1344375703:36:100
08/07/2012 02:41:43 PM - CMDPHP: Poller[0] Host[39] DS[592] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 1, output: 36
08/07/2012 02:41:43 PM - PHPSVR: Poller[0] DEBUG: PID[2247] CTR[0] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 1'
08/07/2012 02:40:01 PM - POLLER: Poller[0] WARNING: Poller Output Table not Empty. Issues Found: 2, Data Sources: batteryCharge(DS[596]), outputLoad(DS[596])
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Re: graph is blank despite SNMP data

Post by gandalf »

The "FATAL: U" output seems to break things. Did you test the script under script server, as it is running as such?
R.
duffrecords
Posts: 10
Joined: Fri Aug 03, 2012 6:58 pm

Re: graph is blank despite SNMP data

Post by duffrecords »

If you're referring to running the script as the same user that cacti runs as, yes, I've run it as www-data. After deleting the faulty graph and adding it again, I'm not seeing the fatal error anymore. However, the graph is all green now, indicating 100% battery charge and 0% output load. The logs show "U" for some of the output values.

Code: Select all

09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[11] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get inputVoltage 2'
09/05/2012 04:05:52 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/hostname_inputfrequency_592.rrd --template outputLoad:batteryCharge 1346886351:56:100
09/05/2012 04:05:52 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/hostname_inputfrequency_591.rrd --template batteryTemperature 1346886351:U
09/05/2012 04:05:52 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/hostname_inputfrequency_590.rrd --template batteryTemperature 1346886351:U
09/05/2012 04:05:52 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/hostname_inputfrequency_595.rrd --template inputFrequency:batteryVoltage:inputVoltage 1346886351:54.5:112.0:59.9
09/05/2012 04:05:52 PM - POLLER: Poller[0] CACTI2RRD: /usr/bin/rrdtool update /var/www/cacti/rra/hostname_inputfrequency_594.rrd --template batteryVoltage:inputVoltage:inputFrequency 1346886351:56:59.9:U
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[10] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryVoltage 2'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[595] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get inputVoltage 2, output: 59.9
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[9] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get inputFrequency 2'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[595] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryVoltage 2, output: 112.0
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[8] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get inputVoltage 1'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[595] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get inputFrequency 2, output: 54.5
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[7] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryVoltage 1'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[594] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get inputVoltage 1, output: 59.9
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[6] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get inputFrequency 1'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[594] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryVoltage 1, output: 56
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[5] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 2'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[594] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get inputFrequency 1, output: U
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[638] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 2, output: U
09/05/2012 04:05:52 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[4] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryTemperature 1'
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[590] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryTemperature 1, output: U
09/05/2012 04:05:52 PM - SPINE: Poller[0] Host[39] TH[1] DS[591] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryTemperature 2, output: U
09/05/2012 04:05:51 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[3] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryTemperature 2'
09/05/2012 04:05:51 PM - SPINE: Poller[0] Host[39] TH[1] DS[592] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryCharge 1, output: 100
09/05/2012 04:05:51 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[2] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryCharge 1'
09/05/2012 04:05:51 PM - SPINE: Poller[0] Host[39] TH[1] DS[592] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 1, output: 56
09/05/2012 04:05:51 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[1] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get outputLoad 1'
09/05/2012 04:05:51 PM - SPINE: Poller[0] Host[39] TH[1] DS[638] SS[0] SERVER: /var/www/cacti/scripts/ss_poweralert_ups_status.php ss_poweralert_ups_status hostname.redacted.com:2:tlremote:::::::3664:500 get batteryCharge 2, output: 100
09/05/2012 04:05:51 PM - PHPSVR: Poller[0] DEBUG: PID[12318] CTR[0] INC: 'ss_poweralert_ups_status.php' FUNC: 'ss_poweralert_ups_status' PARMS: 'hostname.redacted.com:2:tlremote:::::::3664:500 get batteryCharge 2'
However, if I run the script manually, it returns a value:

Code: Select all

root@controller:~# su - www-data -c 'php -q /var/www/cacti/scripts/ss_poweralert_ups_status.php hostname.redacted.com:2:tlremote:::::::3664:500 get outputload 2'
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/imap.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/ming.ini on line 1 in Unknown on line 0
57
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Re: graph is blank despite SNMP data

Post by gandalf »

You should solve the php.ini issue ...
R.
Post Reply

Who is online

Users browsing this forum: No registered users and 26 guests