Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When generating reports, function looping can occur resulting in 100% cpu usage #3517

Closed
ddb4github opened this issue Apr 28, 2020 · 4 comments
Labels
bug Undesired behaviour resolved A fixed issue
Milestone

Comments

@ddb4github
Copy link
Contributor

Describe the bug

Sometimes, poller_reports.php fall in function reports_interval_start with CPU UT 100%, and never return.

To Reproduce

Not sure now because mysql also crashed due to no disk space because poller_reports.php generated huge log(1TB)
I'll try to reproduce at later.

Additional context

Add any other context about the problem here.
part of cacti.log:

  • 2020/04/28 10:35:41 - CMDPHP PHP ERROR NOTICE Backtrace: (/poller_reports.php[143]:generate_report(), /lib/reports.php[497]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:reports_interval_start(), /lib/reports.php[240]:
@ddb4github ddb4github added bug Undesired behaviour unverified Some days we don't have a clue labels Apr 28, 2020
@TheWitness
Copy link
Member

Ouch, keep us posted. There is interlocking in 1.2.12 to minimize race conditions, but disk full can be problematic.

@TheWitness
Copy link
Member

That looks like it's generated from a GUI client as the main IF block is checking for the presence of the $_REQUEST variable which should not be present in the CLI.

@TheWitness TheWitness removed the unverified Some days we don't have a clue label May 5, 2020
@TheWitness
Copy link
Member

Wow, just saw the recursion loop from an interval that is invalid.

@TheWitness TheWitness added this to the 1.2.13 milestone May 5, 2020
TheWitness added a commit that referenced this issue May 5, 2020
Sometimes, poller_reports.php fall in function reports_interval_start with CPU UT 100%, and never return
@TheWitness TheWitness added the resolved A fixed issue label May 5, 2020
@TheWitness
Copy link
Member

Fixed.

@netniV netniV changed the title Sometimes, poller_reports.php fall in function reports_interval_start with CPU UT 100%, and never return. When generate reports, function looping can occur resulting in 100% cpu usage Jul 12, 2020
@netniV netniV changed the title When generate reports, function looping can occur resulting in 100% cpu usage When generating reports, function looping can occur resulting in 100% cpu usage Jul 12, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Oct 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Undesired behaviour resolved A fixed issue
Projects
None yet
Development

No branches or pull requests

2 participants