Scripts value OK but by spine output: 0

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

Moderators: Developers, Moderators

Post Reply
Runan
Posts: 14
Joined: Fri Nov 13, 2009 2:08 am

Scripts value OK but by spine output: 0

Post by Runan »

Hello,

I have built a script to monitor datacore sansymphony-v. I have built a perl script which give values.

When I run it in bash no problem, all is ok :
TotalBytesTransfer:24012621006336 TotalBytesRead:15253248067584 TotalBytesWritten:8759372938752 TotalBytesMigrated:16269067681792 TotalReads:225905441 TotalWrites:391362635 TotalOperations:617268076 BytesAllocated:6782558666752 BytesAvailable:1299764477952 BytesInReclamation:0 BytesTotal:8082323144704 PercentAllocated:83 PercentAvailable:16 TotalReadTime:2410880189 TotalWriteTime:1949363599 MaxReadTime:31 MaxWriteTime:15 MaxReadWriteTime:31 MaxNumberChunks:8289856 BytesReserved:0 CollectionTime:26/04/201215:08:19
When spine execute the same script :
04/26/2012 05:04:05 PM - SPINE: Poller[0] Host[373] TH[1] DS[5104] SCRIPT: perl /var/www/html/cacti-0.8.7h/scripts/DataCoreSanSymphonyv5PerfPoolDisk.pl myserverdatacore mydiskpool, output: 0
It is not my first script but it is the first time it happens, I check user and permissions and I don't see the problem.

Any ideas ? :x
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Re: Scripts value OK but by spine output: 0

Post by gandalf »

Please make sure to NOT rely on $PATH; "cactiuser" does not have $PATH set when executing your script. So we need /full/path/to/every/cmd you use within that script.
See 2nd link of my sig for more debugging hints
R.
Runan
Posts: 14
Joined: Fri Nov 13, 2009 2:08 am

Re: Scripts value OK but by spine output: 0

Post by Runan »

Thanks for your reply.

I have changed the script path in cacti to :
/usr/bin/perl /var/www/html/cacti/scripts/DataCoreSanSymphonyv5PerfPoolDisk.pl myserver diskpool, output: 0

This command works in bash under root session or cacti session.

I have checked in the poller cache and it is the same commande whiched was executed by spine.

:-?

Is there too much information in te output ?
TotalBytesTransfer:26469086426112 TotalBytesRead:16752275978752 TotalBytesWritten:9716810447360 TotalBytesMigrated:17434480214016 TotalReads:250497752 TotalWrites:422966786 TotalOperations:673464538 BytesAllocated:6784706150400 BytesAvailable:1297616994304 BytesInReclamation:0 BytesTotal:8082323144704 PercentAllocated:83 PercentAvailable:16 TotalReadTime:2708808764 TotalWriteTime:2097038420 MaxReadTime:15 MaxWriteTime:46 MaxReadWriteTime:46 MaxNumberChunks:8289856 BytesReserved:0 CollectionTime:27/04/201207:17:59
I don't understand.
Runan
Posts: 14
Joined: Fri Nov 13, 2009 2:08 am

Re: Scripts value OK but by spine output: 0

Post by Runan »

I have found a similar problem on this page but it seems to be resolved ...

Is there anyone have got this problem ? or resolv this problem ? :wink:
Runan
Posts: 14
Joined: Fri Nov 13, 2009 2:08 am

[SOLVED] Scripts value OK but by spine output: 0

Post by Runan »

OK, I have found. In my output, I have at the end : 27/04/201207:17:59
And the cacti poller (spine for me) doesn't like this value and all my output (with the other correct value) is consider like output: 0 :evil:

Thanks.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests