AdguardForWindows
AdguardForWindows copied to clipboard
Memory leakage and CPU overkill
Please answer the following questions for yourself before submitting an issue
- [X] Filters were updated before reproducing an issue
- [X] I checked the knowledge base and found no answer
- [X] I checked to make sure that this issue has not already been filed
AdGuard version
7.17.4709.0
Browser version
Edge 126.0.2592.87
OS version
Windows 11 23H2 Build 22631.3737
Traffic filtering
- [X] yes, I do
Ad Blocking
No response
Privacy
No response
Social
No response
Annoyances
No response
Security
No response
Other
No response
Language-specific
No response
Which DNS server do you use?
DNS protection disabled
DNS protocol
Regular
Custom DNS
No response
What Stealth Mode options do you have enabled?
No response
Support ticket ID
No response
Issue Details
Steps to reproduce:
- use the following filter rules and set exceptions where needed: |http$subdocument |http$third-party,script,object,media,websocket,xmlhttprequest
- close and re-open filtering log every day
- keep the machine running
Expected Behavior
no memory leak or CPU overkill
Actual Behavior
memory leakage and CPU overkill
Screenshots
Screenshot 1
Additional Information
Machine is currently running 12 days. CPU overkill stopped, when I closed the filtering log. The CPU overkill happened today for the first time.
I reported already in here as well (AdguardSvc.exe is using 4.5GB of RAM #5016 ) Version 7.18 is not released as msi installer yet.
@GerhardSauer hello, could you try a new build.
Ok, I installed the new version and will come back with results after some days.
@GerhardSauer how is it going?
@GerhardSauer how is it going? I had to restart the machine several times, thats why I'm writing now. Currently 5 days uptime.
Definitively better, but still growing. The CPU extreme usage did not happen so far.
Could you please grab the Debugs logs for us:
- Collect the debug log as it's explained here.
- Remember the exact time when the issue was reproduced. We will need it to find the corresponding records in the log file.
- Send the archive to
[email protected]and mention this issue number(5173) in the subject.
email with logs is sent. (containing CPU issues, it occurs with the provided version as well) after 10 days, service is again at 7.5 GB commit size memory. In case, I have a memory dump as well.
relevant log time is 29.07.2024 between 21:24:20 ~ 21:24:45 CEST.
Hello, I close it every day, but during the day, I have it open, as I need to add new rules several times a day.
With kind regards, Gerhard Sauer
From: vankos @.> Sent: Friday, August 9, 2024 11:52 AM To: AdguardTeam/AdguardForWindows @.> Cc: Gerhard M.T.H. Sauer @.>; Mention @.> Subject: Re: [AdguardTeam/AdguardForWindows] Memory leakage and CPU overkill (Issue #5173)
@GerhardSauerhttps://github.com/GerhardSauer, hello! Do I understand correctly that you keep the filtering log open all day?
Reply to this email directly, view it on GitHubhttps://github.com/AdguardTeam/AdguardForWindows/issues/5173#issuecomment-2277579058, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ADTVF3JORQOC3RI2ID4OURTZQSGLPAVCNFSM6AAAAABKZWIWNGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENZXGU3TSMBVHA. You are receiving this because you were mentioned.Message ID: @.***>
Hi! We found a few potential places that could be causing the leakage. Could you please try this test build and let us know if the problem persists? https://uploads.adguard.org/AdGuard-v7.19.4799.4.exe
Hi! We found a few potential places that could be causing the leakage. Could you please try this test build and let us know if the problem persists? https://uploads.adguard.org/AdGuard-v7.19.4799.4.exe
yes, i will test, thank you.
4 days runtime, 3,7 gb commit size CPU overkill did not happen so far.
what ever you did, made it worse. @vankos
7 days 17 hours runtime
commit size over 74 GB
Hello, @GerhardSauer,
We need more information to resolve the issue. I have sent instructions to the email you used to send us the dump files, guiding you on how to collect additional data.
Profiling is running. I will get back to you as soon as the commit size is bigger.
@GerhardSauer, we received the snapshots, thanks. I see that the leak is non-linear. Could you tell me, if you recall, if you started doing something differently around 8:00 - 10:00 UTC? Maybe you began adding rules, watching videos, or working with the filtering log etc?
Can you observe if memory consumption still grows if you don’t open the filtering log? (It’s the main suspect for now.)
Also, could you please send the logs for the period when you recorded snapshots to the same email? (You can just send the entire folder: C:\ProgramData\Adguard\Logs\)
@vankos , I have uploaded the logs to the same share I sent you in the last email. I will monitor the memory size the next days without opening the filtering log (currently 2,6GB).
regarding the timing, I can not exactly remember what I did during that time frame. But I did not add much rules the last days.
@vankos 3 days later, the commit size is still 2,69 GB. So main increases are related to the filtering log. As I did not write down the exact number the last time, the maximum possible increase is 90 MB or less.
@GerhardSauer, hello! Sorry for the delayed response. We made some changes in the native libraries that could potentially fix the issue. Could you please update to the latest nightly build and check if the problem still persists? https://agrd.io/windows_nightly
I'm testing now.
@vankos memory leak is still there, but the growth rate is much less and sometimes the commited value reduced a bit.
Thank you for the test! What is the current growth rate? How much is this occasional reduction?
Could you please collect dump files for us again? Since we cannot reproduce the problem on our side, we rely on your help to resolve it. Unfortunately, we cannot use the old dump files, as the codebase has changed significantly since they were collected. I’ve prepared the necessary batch files for you: https://uploads.adguard.org/Procdump.rar
Please follow these steps:
- Extract the archive and run run.bat when the AdGuard commit size is normal.
- The script will: * Immediately create the first .dmp file. * After that script will wait until the AdguardSvc.exe commit size reaches 1.5 GB, then create the second .dmp file.
- Just leave run.bat running until the second dump is created.
Once both files are generated, please upload them to the file share you used previously or any other convenient method, and let us know.
@GerhardSauer, we hope that the issue went away with the latest build. Feel free to reopen the issue (or create the new one) if the issue persist