Cacti (home)ForumsRepositoryDocumentation
Cacti: offical forums and support  

 FAQFAQ   SearchSearch   MemberlistMemberlist    RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in    


spine.exe doesn't "read" values from script; cmd.p

 
Post new topic   Reply to topic    Cacti Forum Index -> Help: Windows Specific
Author Message
dlockwood



Joined: 07 May 2006
Posts: 22
Location: Redding, CA

PostPosted: Sun Aug 17, 2008 9:53 pm    Post subject: spine.exe doesn't "read" values from script; cmd.p Reply with quote

A while back I had downloaded a script from the forum to graph the number of AP radios currently online on a Cisco WLC. Forum post here: http://forums.cacti.net/viewtopic.php?t=12863&postdays=0&postorder=asc&start=45

It worked wonderfully for a number of months until i upgraded to 0.8.7b. The script started throwing errors which you can read about in the other forum posts. Fast forward; I had one of my friends make some changes to the script so that it was putting out correct data again after the upgrade, but for all the hours we spent looking at the problem we could not get spine.exe to read the data that was output by the script. E.g. the script output will look something like this:

Code:
C:\>php C:/Inetpub/wwwroot/cacti/scripts/query_4400_APifType.php 10.1.253.4 sEsw58ra5ewAn3mU
APdot11a:4 APdot11b:4


Where in this case '4' is the integer value representing the number of APs online with the controller. When I use cmd.php as the poller, it picks up the values and graphs them just fine; no errors. When I switchover to spine.exe and try to use that as the poller, I get the following error in the cacti log file:

Code:

ERROR: Empty result [12.189.216.197]: 'php C:/Inetpub/wwwroot/cacti/scripts/query_4400_APifType.php 12.189.216.197 tie1pOe5R6achiuT'


And no data is graphed obviously. I wonder if there is anyone else out there with more knowledge of the 'under the hood' aspects of spine that can give me a clue on what needs to be changed in the script to make it compatible with spine. cmd.php is getting my by, but it takes almost four minutes to run a polling cylcle and I sure could benefit from the performance. Any suggestions are appreciated. Thanks!
Back to top
BSOD2600
Cacti Moderator


Joined: 08 May 2004
Posts: 6795
Location: WA, USA

PostPosted: Mon Aug 18, 2008 1:11 am    Post subject: Reply with quote

Make sure the data input method, specifies the FULL PATH to php.exe; spine is picky that way.
Back to top
dlockwood



Joined: 07 May 2006
Posts: 22
Location: Redding, CA

PostPosted: Wed Aug 20, 2008 11:29 pm    Post subject: follow-up Reply with quote

Thanks for the suggestion. I went to have a look at the data input method for the script and sure enough found that the full path to php was not listed. So I changed:
Code:
php <path_cacti>/scripts/query_4400_APifType.php <hostname> <snmp_community>


to:
Code:
c:/progra~1/php/php.exe <path_cacti>/scripts/query_4400_APifType.php <hostname> <snmp_community>


Then switched the poller back over to spine and found this interesting log error during the next polling cycle:

Code:
ERROR: Empty result [10.1.253.4]: 'php C:/Inetpub/wwwroot/cacti/scripts/query_4400_APifType.php 10.1.253.4 sEsw58ra5ewAn3mU'


Since I dont see the full path I went back to verify that the changes I had made were still there; sure enough they are. It seems like the command string is being built from data in a place other than the data input method?
Back to top
BSOD2600
Cacti Moderator


Joined: 08 May 2004
Posts: 6795
Location: WA, USA

PostPosted: Thu Aug 21, 2008 2:55 am    Post subject: Reply with quote

make sure there are no trailing spaces in the parameters which get passed into Spine. I recall there was a bug with spine and that issue, forget if it was fixed in 0.8.7b or the SVN...
Back to top
dlockwood



Joined: 07 May 2006
Posts: 22
Location: Redding, CA

PostPosted: Sun Aug 24, 2008 11:09 am    Post subject: update Reply with quote

Thanks for the suggestions. I went back and very carefully looked for whitespace but unfortunately wasn't able to find any. Should I just sit tight for the next release of spine? Any estimates when that might be? Thanks!
Back to top
BSOD2600
Cacti Moderator


Joined: 08 May 2004
Posts: 6795
Location: WA, USA

PostPosted: Sun Aug 24, 2008 10:28 pm    Post subject: Reply with quote

Bah, I overlooked the obvious. Manually clear your snmp / poller cache. Also, I see the Spine SVN was just updated today fixing that OID space issue.
Back to top
Display posts from previous:   
Post new topic   Reply to topic    Cacti Forum Index -> Help: Windows Specific All times are GMT - 5 Hours
Page 1 of 1

 



Powered by phpBB © 2001, 2005 phpBB Group