Poller running twice
Moderators: Developers, Moderators
Poller running twice
After adding a script to login to a rouer I noticed the logins happening twice, at the same time. I turned on the logging level to high and notice that everything gets polled twice within 5 seconds of the first poll. I've tried changing the Poller Failure count to 1 which doesn't seem to help. The first pass of polls always returns valid values, and the second poll right on top of the first returns the same values. Latency and network performance on both ends is not a problem.
Is there anyway to stop this behavior? Is it normal?
System Specs:
Clean install of Cacti 0.8.6c (cmd.php) with the 3 official patches
Fedora Core 3, PHP 4.3.9, MySQL 3.23.58-13
Any insight would be greatly appreciated.
Edit: I have verified that there is only one entry in the crontab
Is there anyway to stop this behavior? Is it normal?
System Specs:
Clean install of Cacti 0.8.6c (cmd.php) with the 3 official patches
Fedora Core 3, PHP 4.3.9, MySQL 3.23.58-13
Any insight would be greatly appreciated.
Edit: I have verified that there is only one entry in the crontab
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Review your poller cache or your poller_items table for dups.
TheWitness
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?
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?
Thanks for the reply. I checked both and no duplicates. I deleted the only host I had and let cacti run for 15 minutes then recreated the same host, but all of my graph items (8 under 1 host) are showing duplicates in the log and scripts still run twice. While checking the poller cache, I noticed that clearing the poller cache and log file have no effect...Everything else seems to work fine with Cacti as far as I can tell.
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Please post your log file.
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?
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?
Here is a chunk of my log file from this morning. I've created one host, and added to it the SNMP Interfaces included from a host template that has other templates. The only other host is the default localhost which is also running (and showing duplicates). I turned on the log to Debug mode at 9:50. Thanks for your help.
- Attachments
-
- cacti.log.txt
- cacti log snippet
- (41.98 KiB) Downloaded 237 times
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Very unusual. Do you have an issue sending my a mysqldump of the database? Send to my published e-mail address. I will review this evening.
TheWitness
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?
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?
While testing, I've discovered something interesting. First of all, I uninstalled the current version (rpm -e cacti..., dropped the db, removed the crontab entry) and reinstalled from scratch 0.8.6c without the patches applied. Same problem. Then did it again with 0.8.6b. Same thing. I've still go an old directory from 0.8.6b (my first cacti install - ran for about 2 months) and the log file for it...that log file doesn't show this problem.
Anyway, I've just discovered the 2 proccesses:
This seems very odd...shouldn't there only be one running under sh? Does this help at all? I'm not sure where to check now. My crontab entry looks like this:
*/5 * * * * cacti php /var/www/html/cacti/poller.php > /dev/null 2>&1
I've got the db file if you still want it but I think there are other issues...
[/code]
Anyway, I've just discovered the 2 proccesses:
Code: Select all
[root@wiggum etc]# ps ax | grep cacti
19486 ? Ss 0:00 /bin/sh -c php /var/www/html/cacti/poller.php > /dev/null 2>&1
19487 ? S 0:01 php /var/www/html/cacti/poller.php
19485 ? Ss 0:00 /bin/bash -c php /var/www/html/cacti/poller.php > /dev/null 2>&1
19488 ? S 0:01 php /var/www/html/cacti/poller.php
19552 pts/2 S+ 0:00 grep cacti
*/5 * * * * cacti php /var/www/html/cacti/poller.php > /dev/null 2>&1
I've got the db file if you still want it but I think there are other issues...
[/code]
- TheWitness
- Developer
- Posts: 17047
- Joined: Tue May 14, 2002 5:08 pm
- Location: MI, USA
- Contact:
Send it along. You may also want to review your crontab for multiple entries, which I am sure you have already done.
TheWitness
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?
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?
- rony
- Developer/Forum Admin
- Posts: 6022
- Joined: Mon Nov 17, 2003 6:35 pm
- Location: Michigan, USA
- Contact:
Have you checked the users cron?
You might have 2 entries and not even know it.
Code: Select all
crontab -l -u cacti
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Okay, I think this is fixed now. I've again verified that there is only 1 entry in crontab, but I've discoverd a file named cacti in /etc/cron.d with the same crontab line that is in /etc/crontab. I'm not sure how this got there, but I moved it and now all seems well - no more duplicates and ps ax | grep cacti comes up empty. I'll keep an eye on this tho for now. Thanks for all of the help folks
As I haven't dealt much with cron jobs in Linux, this may not be correct...but, when installing the rpm for 0.8.6c-fc3 it places a file called cacti in /etc/cron.d that contains the same cron line as listed in the install manual. So, I'm assuming that this step (adding the cron line to /etc/crontab) is no longer needed or that in /etc/cron.d shouldn't be there? Am I missing something here?
Who is online
Users browsing this forum: No registered users and 1 guest