AdGuardHome icon indicating copy to clipboard operation
AdGuardHome copied to clipboard

Periodic high cpu load

Open silvanverschuur opened this issue 4 years ago • 9 comments

I've migrated from using Adguard Home in a VM to using the Docker container (version 0.107.2). Every 10/12 hours I see a spike in CPU usage for about 90 minutes. I have never seen this behaviour when I was running Adguard Home inside a VM.

Thing I have tried without success:

  • Disable memory optimization
  • Use docker host network instead of bridged mode

The average CPU usage of Adguard used to be somewere between 0-3%. The strange thing is that these spikes also occur in the middle of the night, so I don't think it's related to a DNS lookup. My average number of DNS queries / 24h is 40.000. I've added some screenshots of the CPU usage of the Adguard docker container.

Screenshots

image

image

silvanverschuur avatar Jan 08 '22 08:01 silvanverschuur

Wouldn't be linked to the refresh update period (i.e. when refreshing and parsing your blocklists) ?

Harvester57 avatar Jan 09 '22 19:01 Harvester57

My update interval is 24h and I only have 1 blocklist. The CPU spikes occur every 10 / 12 hours. So I'm not convinced this is causing the CPU spikes, but I will keep an eye on it.

silvanverschuur avatar Jan 09 '22 20:01 silvanverschuur

Hello, thank you for the report, and apologies for the late response. Can you enable verbose logging and look, what kind of logs are printed during the CPU spikes? Or send the logs to [email protected] with the corresponding subject line, if you think you could do that. Thanks!

ainar-g avatar Jan 19 '22 14:01 ainar-g

@silvanverschuur Hi! Is this issue still relevant?

Birbber avatar Sep 01 '22 13:09 Birbber

@Birbber I have not seen these CPU spikes anymore using the latest version(s) so I think this issue van be closed.

silvanverschuur avatar Sep 01 '22 16:09 silvanverschuur

@silvanverschuur Are you running docker? If so did you update to adguard/adguardhome:latest?

Looks like i have the same issue: https://github.com/AdguardTeam/AdGuardHome/issues/4531 - but updating doesn't seem to fix it.

Jleagle avatar Feb 13 '25 19:02 Jleagle

@Jleagle Yes I'm running docker. I use the latest version of adguard and did not see any spike since my previous comment.

silvanverschuur avatar Feb 14 '25 06:02 silvanverschuur

Hi all. Just want to chip in - been having this identical issue on openwrt running both adguardhome natively (via opkg) or docker, after baffling there's massive system load during unmanned hours without anything scheduled in cron, finally I've figured out the reason of causing the periodic CPU spike is due to homeassistant's adguardhome addon/plugin, which periodly makes http request to all HA properties of adguardhome (can be seen via verbose logging), and the process is very expensive to for embedded systems. Disarmed the HA plugin and it's been peaceful since then.

6r33z3 avatar Apr 04 '25 13:04 6r33z3

Hi all. Just want to chip in - been having this identical issue on openwrt running both adguardhome natively (via opkg) or docker, after baffling there's massive system load during unmanned hours without anythign scheduled in cron, finally I've figured out the reason of causing the periodic CPU spike is due to homeassistant's adguardhome addon/plugin, which periodly makes http request to all HA properties of adguardhome (can be seen via verbose logging), and the process is very expensive to for embedded systems. Disarmed the HA plugin and it's been peaceful since then.

That seems to be it, nice one!!

Jleagle avatar Apr 07 '25 09:04 Jleagle