rrd files only get updated when i run poller.php manually

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

Moderators: Developers, Moderators

Post Reply
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

rrd files only get updated when i run poller.php manually

Post by jiml5000 »

Hi friends,

The graphs stay blank unless I run poller.php manually. Then all of the days get populated.

For example, i leave for the weekend, and I come back. All I would see for those 2 days would be blank graphs. After running poller.php, all the period in those two days get populated.

The permission for the directory are set to the user and not root. Cron log shows both poller.php and cmd.php being run at 5-min intervals:

Mar 12 17:45:00 cacti /usr/sbin/cron[3504]: (cacti) CMD (php /usr/local/share/cacti/poller.php > /dev/null 2>&1)
Mar 12 17:45:00 cacti /usr/sbin/cron[3505]: (root) CMD (/usr/libexec/atrun)
Mar 12 17:45:00 cacti /usr/sbin/cron[3506]: (cacti) CMD (/usr/local/bin/php /usr/local/share/cacti/cmd.php > /dev/null 2>&1)
Mar 12 17:50:00 cacti /usr/sbin/cron[3590]: (cacti) CMD (php /usr/local/share/cacti/poller.php > /dev/null 2>&1)
Mar 12 17:50:00 cacti /usr/sbin/cron[3591]: (root) CMD (/usr/libexec/atrun)
Mar 12 17:50:00 cacti /usr/sbin/cron[3592]: (cacti) CMD (/usr/local/bin/php /usr/local/share/cacti/cmd.php > /dev/null 2>&1)


What am i doing wrong?

/etc/passwd:
cacti:*:107:107:Cacti Sandbox:/nonexistent:/sbin/nologin

/etc/crontab:
*/5 * * * * cacti php /usr/local/share/cacti/poller.php > /dev/null 2>&1

crontab for cacti:
cacti# crontab -l -u cacti
*/5 * * * * /usr/local/bin/php /usr/local/share/cacti/cmd.php > /dev/null 2>&1

Permissions:
drwxr-xr-x 2 cacti cacti 512 Mar 12 14:45 log
drwxr-xr-x 2 cacti cacti 2048 Mar 12 16:37 rra

It's a new install on FreeBSD 6.2-STABLE

Thanks for any insight into this.
NSX
Posts: 1
Joined: Mon Mar 12, 2007 10:10 pm

Post by NSX »

chown -R cacti.cacti rra
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Post by jiml5000 »

NSX: yeah, I've done that for both log/ and rra/. Thx.
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Post by jiml5000 »

Only error i'm seeing is from httpd-errors:

cacti# tail /var/log/httpd-error.log
[Tue Mar 13 08:53:29 2007] [error] PHP Notice: Undefined index: cacti_version in /usr/local/share/cacti/include/auth.php on line 30
[Tue Mar 13 08:53:30 2007] [error] PHP Notice: Undefined index: cacti_version in /usr/local/share/cacti/include/auth.php on line 30
[Tue Mar 13 08:53:30 2007] [error] PHP Notice: Undefined index: cacti_version in /usr/local/share/cacti/include/auth.php on line 30


i am not getting any errors when I am running poller.php and cmd.php. Cacti.log looks clean. Where else should I look?
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Post by jiml5000 »

cacti.log:

03/13/2007 08:57:39 AM - CMDPHP: Poller[0] WARNING: sockets support not enabled in PHP, falling back to SNMP ping
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] Host[1] DS[3] WARNING: Result from CMD not valid. Partial Result:
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] Host[1] DS[4] WARNING: Result from CMD not valid. Partial Result:
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] WARNING: sockets support not enabled in PHP, falling back to SNMP ping
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] WARNING: sockets support not enabled in PHP, falling back to SNMP ping
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] WARNING: sockets support not enabled in PHP, falling back to SNMP ping
03/13/2007 08:57:39 AM - CMDPHP: Poller[0] WARNING: sockets support not enabled in PHP, falling back to SNMP ping
03/13/2007 08:57:40 AM - SYSTEM STATS: Time:1.2659 Method:cmd.php Processes:1 Threads:N/A Hosts:6 HostsPerProcess:6 DataSources:71 RRDsProcessed:11
4
artman67
Posts: 1
Joined: Thu Mar 15, 2007 5:56 pm

rrd files only get updated when i run poller.php manually

Post by artman67 »

change /dev/null to /tmp/anything
see if that tells you anything
m4ster
Posts: 11
Joined: Wed Jan 04, 2006 2:04 pm

Have the same error

Post by m4ster »

I, have debian Etch, apache2, php5, cacti the last version.

When run php poller.php make fine the graphics, the permission are this.

chown -R cactiuser:cacti rra log

Apache sendme this errors

ERROR: opening/var/www/apache2-default/graficas/rra/localhost_hdd_free_8.rrd': No such file or directory
ERROR: var/www/apache2-default/graficas/rra/localhost_load_1min_5.rrd': No such file or directory
ERROR: openngvar/www/apache2-default/graficas/rra/localhost_users_6.rrd': No such file or directory


My cron is this

cronttab -e

*/5 * * * * cactiuser php /var/www/apache2-default/graficas/poller.php > /tmp/cactilogs 2>&1

Make the folder cactilogs in tmp and put chown -R nobody.nogroup cactilogs.

Any ideas why not work??

Thanx
pheldens
Posts: 8
Joined: Thu Mar 15, 2007 1:19 pm

Post by pheldens »

reconfigure cacti include/config.php, you must run the poller thats in the used tree, not some system wide copy or so.
m4ster
Posts: 11
Joined: Wed Jan 04, 2006 2:04 pm

config

Post by m4ster »

Hi, in this file i have not modify nothing, just the database user etc, in Cacti setting, poller, see poller.php and cmd.php, by default is cmd.php, when change to poller.php, and execute php poller.php manually, appear error.

Ideas?
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Re: rrd files only get updated when i run poller.php manuall

Post by jiml5000 »

no difference. Logs look the same. Anything else i can try to at least isolate this issue further? Thanks.

artman67 wrote:change /dev/null to /tmp/anything
see if that tells you anything
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Post by jiml5000 »

Man, I am sure it's something quite simple. I mean everything is working. It's gathering the appropriate data and storing them. It's just that the rrd files aren't being updated. What?!!?

Some please help.
jiml5000
Posts: 9
Joined: Mon Mar 12, 2007 4:49 pm

Post by jiml5000 »

Actually, my mistake artman67. When I made the changes suggested, I couldn't get any updated graphs even if i ran the poller manually.

What does that mean? Thanks.
doserror
Posts: 1
Joined: Sat May 05, 2007 7:58 am

Post by doserror »

Hi,
I have the same problem, everything seem to be in order but the graph is not updateing. I've tried useing poller.php and cactid. In both cases the graph stays blank. I'm useing Freebsd 6.2 on AMD64, php5-5.2.1_3, mysql-server-5.0.37, apache-2.2.4_2.
If anyone have an idea, I will be very gratefull.

Thanks in advance.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Better open a new thread.
Find some help at the second link of my signature
Reinhard
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest