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

High CPU usage for Uptime-Kuma process #2751

Closed
2 tasks done
AndreKotze opened this issue Feb 9, 2023 · 13 comments
Closed
2 tasks done

High CPU usage for Uptime-Kuma process #2751

AndreKotze opened this issue Feb 9, 2023 · 13 comments
Labels

Comments

@AndreKotze
Copy link

⚠️ Please verify that this bug has NOT been raised before.

  • I checked and didn't find similar issue

🛡️ Security Policy

Description

Recently my Uptime-Kuma started getting really sluggish to the point where the dashboard and status pages would not load or only load partially. When running TOP on my server I noticed that the uptime-kuma process was constantly running at 100%.

image

👟 Reproduction steps

.

👀 Expected behavior

.

😓 Actual Behavior

.

🐻 Uptime-Kuma Version

1.19.6

💻 Operating System and Arch

Ubuntu 22.04.1 LTS

🌐 Browser

Google Chrome 109.0.5414.120

🐋 Docker Version

No response

🟩 NodeJS Version

14.21.2

📝 Relevant log output

No response

@AndreKotze AndreKotze added the bug Something isn't working label Feb 9, 2023
@rezzorix
Copy link
Contributor

Before labelling this as a bug; can you give more information:

  • how many monitors are you running
  • what type of monitors
  • what are the system specs

@AndreKotze
Copy link
Author

I'm running roughly 100 monitors which are a mix of HTTP and PING. My server is a 4 core VM with 8GB of RAM.

On the same server I'm also running an instance of Observium which is monitoring 100+ devices through SNMP and it has no issues with performance.

@AndreKotze
Copy link
Author

Here is another screenshot from htop:

image

@rezzorix
Copy link
Contributor

System shouldnt be a problem for 100 monitors.
Whats the frequency of your monitors?

@AndreKotze
Copy link
Author

20 seconds.

@AndreKotze
Copy link
Author

I'm not sure if this could be a contributing factor but I'm getting some weird graphs for my HTTP monitors.

image

image

image

image

@rezzorix
Copy link
Contributor

You running it on a VM...? Then thats probably the issue?

@louislam
Copy link
Owner

20 seconds.

It maybe too low for 100 monitors, try to increase it to 60 or higher.

@louislam louislam added help and removed bug Something isn't working labels Feb 10, 2023
@AndreKotze
Copy link
Author

I've just finished changing them all to 60 seconds but it made no difference. I'm now going to clear the heartbeats and events as well.

@AndreKotze
Copy link
Author

After clearing all the historical data the CPU usage has come right down and will occasional peak above 10%.

image

@AndreKotze
Copy link
Author

My system seems to be stable again so I'm going to close this issue now...

@remotoservicos
Copy link

My system seems to be stable again so I'm going to close this issue now...

I understand it became stable after cleaning the historical data, but that seems pretty weird. How did it behave after a few months? I'm having the same issue all of a sudden, but I didn't try cleaning anything yet.

@CommanderStorm
Copy link
Collaborator

In v1, reducing either retention/ping-rate/.. or moving to a faster storage solution is the only option to get around this problem.
In v2, we have likely resolved this problem. See #4500 for further details of what needs to happen before we can release this version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants