Issues installing cacti 0.8.6b

Post support questions that relate to the Windows 2003/2000/XP operating systems.

Moderators: Developers, Moderators

Post Reply
Alberto

Issues installing cacti 0.8.6b

Post by Alberto »

php 4.3.9 installed in c:\php
mysql 4.0.21 installed in c:\mysql
net-snmp 5.1.2-1.win32 installed in c:\net-snmp
rrdtool 1.0.48 installed in c:\rrdtool
cacti 0.8.6b installed in e:\inetpub\wwwroot\cacti
IIS 6


I followed all the instructions and I still have couple of issues so hope someone could help me ...


I am installing a new version so it is no an upgrade.

Everything seem to be fine up to this point ..
1.- I create 1 device (which is a Cisco Switch) and make 6 graphics (cpu stuff and some interface traffic collection)
2.- I run manually poller.php and it seam to be running fine see the output below:
E:\INETPUB\WWWROOT\cacti>php poller.php
C:/net-snmp/etc/snmp/snmp.conf: line 2: Warning: Unknown token: persistentDir.
C:/net-snmp/etc/snmp/snmp.conf: line 3: Warning: Unknown token: tempFilePattern.

Content-type: text/html
X-Powered-By: PHP/4.3.9

11/02/2004 08:42:54 AM - POLLER: Poller[0] DEBUG: About to Spawn a Remote Proces
s [CMD: c:\php\php.exe, ARGS: -q e:\inetpub\wwwroot\cacti/cmd.php 0 2]
Waiting on 1/1 pollers.
C:/net-snmp/etc/snmp/snmp.conf: line 2: Warning: Unknown token: persistentDir.
C:/net-snmp/etc/snmp/snmp.conf: line 3: Warning: Unknown token: tempFilePattern.

Waiting on 1/1 pollers.
11/02/2004 08:42:55 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_5min_cpu_8.rrd --template 5min
_cpu 1099402974:20
11/02/2004 08:42:55 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_9.rrd --template tr
affic_out:traffic_in 1099402974:1653104984:2440879881
11/02/2004 08:42:55 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_10.rrd --template t
raffic_out:traffic_in 1099402974:876498479:2716061713
OK
OK
OK
11/02/2004 08:42:56 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_13.rrd --template t
raffic_out:traffic_in 1099402974:151777011:1283045743
11/02/2004 08:42:56 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_12.rrd --template t
raffic_in:traffic_out 1099402974:535500534:3606316988
11/02/2004 08:42:56 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_11.rrd --template t
raffic_in:traffic_out 1099402974:1137634127:1346099578
OK
OK
OK
11/02/2004 08:42:56 AM - POLLER: Poller[0] CACTI2RRD: c:\rrdtool\rrdtool.exe upd
ate E:\INETPUB\WWWROOT\cacti\rra\harmnicrecr_b651_traffic_in_14.rrd --template t
raffic_out:traffic_in 1099402974:1767318096:3747634748
OK
11/02/2004 08:42:56 AM - SYSTEM STATS: Time: 2.0516 s, Method: cmd.php, Processe
s: 1, Threads: N/A, Hosts: 2, Hosts/Process: 2

E:\INETPUB\WWWROOT\cacti>

3.- I go to graph management and turned on the debug (because is not showing the graph) and then I have the following error from it:
Warning: feof(): supplied argument is not a valid stream resource in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 101

Warning: fgets(): supplied argument is not a valid stream resource in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 102

I checked the ...\cacti\rra directory and the files are there .. for cpu, and the interfaces.


The second problem is that 'cactid' is not working properly. If I switch to cactid, it will hang waiting for another process and it will not finish. If there is a script trying to collect information using perl (which is not installed in my server), the process just hangs (something to be checked out).

Can anyone help me ??

Thanks,

Alberto
Alberto

Issues installing cacti 0.8.6b

Post by Alberto »

Before those errors I have another one ...

Warning: popen(c:\rrdtool\rrdtool.exe fetch E:\INETPUB\WWWROOT\cacti/rra/harmnicrecr_b651_traffic_in_12.rrd AVERAGE -s -86400 -e -300,rb): No error in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 88

it may be related to the other errors ...

it takes a long time as the process timesout and can not finish the debug ... that's why I did not see it the first time ...
Alberto

more information

Post by Alberto »

Turning on the debug for the graphs and selecting the cpu utilization I get the following message:

RRDTool Says:


Warning: popen(c:\rrdtool\rrdtool.exe graph - --imgformat=PNG --start=-86400 --end=-300 --title="HARMNI-CRE-CR B651 - CPU Usage" --rigid --base=1000 --height=120 --width=500 --alt-autoscale-max --lower-limit=0 --vertical-label="percent" DEF:a="E\:\INETPUB\WWWROOT\cacti/rra/harmnicrecr_b651_5min_cpu_8.rrd":5min_cpu:AVERAGE AREA:a#FF0000:"CPU Usage" GPRINT:a:LAST:"Current\:%8.0lf" GPRINT:a:AVERAGE:"Average\:%8.0lf" GPRINT:a:MAX:"Maximum\:%8.0lf" 2>&1,rb): No error in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 88

Warning: fgets(): supplied argument is not a valid stream resource in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 111


If I do the same with the interface statistics, it goes with the warning on both line 111 and 112 until it times out (I get about a thounsand errors).
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Hi,

Relative to your installation:
E:\INETPUB\WWWROOT\cacti>php poller.php
C:/net-snmp/etc/snmp/snmp.conf: line 2: Warning: Unknown token: persistentDir.
C:/net-snmp/etc/snmp/snmp.conf: line 3: Warning: Unknown token: tempFilePattern.
There is a file installed with Net-SNMP called snmpd.conf. You need to edit and remove the two lines in question.
The second problem is that 'cactid' is not working properly. If I switch to cactid, it will hang waiting for another process and it will not finish. If there is a script trying to collect information using perl (which is not installed in my server), the process just hangs (something to be checked out).
Cactid had a few bugs that have been corrected in CVS. If you search the Win32 forum, you will find Zip copies of it's current state. Probably better to download from CVS though and remake.
3.- I go to graph management and turned on the debug (because is not showing the graph) and then I have the following error from it:
Warning: feof(): supplied argument is not a valid stream resource in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 101

Warning: fgets(): supplied argument is not a valid stream resource in E:\INETPUB\WWWROOT\cacti\lib\rrd.php on line 102

I checked the ...\cacti\rra directory and the files are there .. for cpu, and the interfaces.
I need to investigate this one. But in the mean time, read the following post and apply the patches and then provide feedback.

http://forums.cacti.net/viewtopic.php?t=5373

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Willie

Cacti Install

Post by Willie »

Alberto,

With IIS6, you must put in a web extension that contains the php dlls. your cactid.exe, your rrdtool.exe, your perl.exe, etc. Make it active.

I have also found that you have to be running at an aministrative state in order to get rid of the popen errors. This is a huge change from IIS 5.1.

I created a new acct, gave it admin rights (administrators group for the local machine), and then set the cacti site to use it. that fixed all of my issues viewing graphs.

Regards,

Willie
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

Thanks Willie!!!

Larry
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Alberto

Post by Alberto »

Ok, I tried by adding the dlls, etc but still having the popen errors. I tried first by adding some of the DLL's but then after not being successful I lowed all of the unkown ISAPI modules and CGI modules and still having the popen errors.

I believe PHP is trying to open a file somewhere and it is not allowed by the users ... (I have to use integrated microsoft authentication) .. so I will try to research a bit on where it is trying to open a file to provide access to the users ?? not sure how to fix this though.

Not sure if I understand correctly about running it as an administrator state ?? I mean the service (php isapi module runs under IIS) ... not sure how to do it ..

Could you explain a bit better what to do for the accounts and cacti ??
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

PHP.Net has a Windows 2003 IIS 6 Installation guide with very good usage notes. Please go to their web site.

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Alberto

Post by Alberto »

Hi guys,

I finally nailed the problem down and fixed it.

It is necessary to add execute priviledges to "cmd.exe" for the IUSR_<SERVER> as IIS 6 runs inpersonating this user. The new IIS6 service does not run with administrator priviledges but with the IUSR_<SERVER> priviledges.

This change is specific for cacti as it uses popen (which requires the cmd.exe to open the pipe against rrdtool).

So additionally to follow the instructions on PHP.NET, you need to add this specific procedure for cacti to work properly.

Thanks for your help on this one,

Alberto
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest