First off, I'm running CentOS 7 / Apache 2.4.6 and PHP 5.4.16 + Cacti 0.8.8f
I'm trying to get the NUT UPS (http://www.eric-a-hall.com/software/cacti-nut/) monitor working and have hit a snag. I'm not sure if it is permissions related or a Cacti issue but it is stumping me with my limited Linux knowledge. I've moved the files as required, imported the script - no problems there. When I add the data query to the host, it doesn't work - errors about not being able to establish a TCP connection. Doing a verbose query, I get the following:
Code: Select all
+ Running data query [15].
+ Found type = '6' [Script Query - Script Server].
+ Found data query XML file at '/var/www/html/cacti-0.8.8f/resource/script_server/nut_ups_status.xml'
+ XML file parsed ok.
+ <arg_num_indexes> missing in XML file, 'Index Count Changed' not supported
+ Executing script for list of indexes '"/bin/php" -q /var/www/html/cacti-0.8.8f/scripts/ss_nut_ups_status.php 192.168.2.2:3493:500 index' Index Count: 1
+ Found index: FATAL: Unable to establish TCP session with port 3493 on 192.168.2.2
+ Executing script query '"/bin/php" -q /var/www/html/cacti-0.8.8f/scripts/ss_nut_ups_status.php 192.168.2.2:3493:500 query ups.device'
+ Found item [upsDevice=' Unable to establish TCP session with port 3493 on 192.168.2.2'] index: FATAL
+ Executing script query '"/bin/php" -q /var/www/html/cacti-0.8.8f/scripts/ss_nut_ups_status.php 192.168.2.2:3493:500 query ups.description'
+ Found item [upsDescription=' Unable to establish TCP session with port 3493 on 192.168.2.2'] index: FATAL
Code: Select all
#sudo -H -u apache bash -c "/bin/php -q /var/www/html/cacti-0.8.8f/scripts/ss_nut_ups_status.php 192.168.2.2:3493:500 index"
ups
If anyone could shed some light on where to look next, it would be greatly appreciated.
Cheers.