Perl and poller.php and cactid

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
levy
Posts: 6
Joined: Tue Mar 08, 2005 3:41 pm

Perl and poller.php and cactid

Post by levy »

Hi.

I'm use:

OpenBSD 3.6
rrdtool-1.0.48
mysql-server-4.0.20
net-snmp-5.1.2
php4-core-4.3.10
php4-mysql-4.3.10

Cacti will work - great :))) but ... I running poller.php or cactid (+cactid.conf):


# php poller.php
Can't open perl script "/htdocs/cacti/scripts/linux_memory.pl": No such file or directory.
Use -S to search $PATH for it.
Can't open perl script "/htdocs/cacti/scripts/linux_memory.pl": No such file or directory.
Use -S to search $PATH for it.
Can't open perl script "/htdocs/cacti/scripts/loadavg_multi.pl": No such file or directory.
Use -S to search $PATH for it.
Can't open perl script "/htdocs/cacti/scripts/unix_users.pl": No such file or directory.
Use -S to search $PATH for it.
Can't open perl script "/htdocs/cacti/scripts/unix_processes.pl": No such file or directory.
Use -S to search $PATH for it.
ERROR: opening '/htdocs/cacti/rra/localhost_mem_buffers_3.rrd': No such file or directory
OK u:0.00 s:0.00 r:2.09
ERROR: opening '/htdocs/cacti/rra/localhost_mem_swap_4.rrd': No such file or directory
------------------------------

Apache is chroot'ed in /var/www/

Perl doesn't acces in /var/www ???

any ideas ?


regards (sorry my english is poor)

--
levy
User avatar
TheWitness
Developer
Posts: 17053
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

I think it has something to do with a chrooted environment and what paths are available to the web server. If I remember correctly "/" is the web root in a chrooted web environment. This essentially breaks Cacti (I think). There are others out there who should be able to help.

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?
levy
Posts: 6
Joined: Tue Mar 08, 2005 3:41 pm

Post by levy »

You're right :) ehhhhhh chroot ;)

regards
rstarr
Posts: 16
Joined: Thu Feb 03, 2005 11:10 am

Post by rstarr »

I got it to work in chroot. You need to copy the binaries, libraries, and files that cacti uses into the /var/www directory. I ended up turning off chroot in apache because I am running other things on this web server. It was turning into a pain tracking down all the files I needed to copy for my scripts. Chroot is much easier to work with when using more static web content.

It's your choice to turn off chroot. I don't necessarily need it in my environment since it's an internal server that is fairly protected in other ways. In this situation I picked ease of use over security. If you want to do the same, edit /etc/rc.conf to look like this:

Code: Select all

--snip--
httpd_flags="-u"
--snip--
apachectl restart to apply changes.

-Russ
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests