Page 1 of 2

Unmanaged memory grows up - memory leak on Linux

Posted: Wed Jun 02, 2021 7:11 am
by Ruslan Kadyrbaev
Hi all,

After updating from 2020.3.2 to 2021.3.2 we noticed that unmanaged memory grows up - about 100mb on every pdf-generation.
Unmanaged memory grows up permanently on every request and doesn't return. We made a memory dump via dotMemory.

Environment: Kubernets, Linux (debian), .Net Core 3.1, 2021.3.2, PDF

P.S. We are very sad. We can't to upgrade SDK for a year (since september last year). On every new engine's release we attempt to upgrade it but the new release contains too many troubles and bugs related to Linux hosting.
Do you perform the engine's testing on Linux? cos it is a big pain for us.

Sample of code
sample.cs
(2.89 KiB) Downloaded 195 times
Memory
analyze1.png
analyze1.png (66.12 KiB) Viewed 3256 times
analyze2.png
analyze2.png (75.07 KiB) Viewed 3256 times

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Wed Jun 02, 2021 2:55 pm
by Ruslan Kadyrbaev
Also I get an error when I start two or more parallel requests and pod shuts down with 139 error

worker_1 | free(): invalid pointer
worker_1 | free(): invalid pointer
exited with code 139

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Fri Jun 04, 2021 7:25 am
by Lech Kulikowski
Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Fri Jun 04, 2021 11:39 am
by Lech Kulikowski
Hello,

To test the memory consumption - we need a specific report with data on which to reproduce it all. And for a complete analysis, we need a sample project.
As for the code, we can already see that different static options are set here. Maybe somewhere else is set that we do not know about, but it affects it.

Thank you.

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Tue Jun 08, 2021 2:24 pm
by RuslanR
You can use this project with 2 routes. Multiple call /report or /report/parallel to reproduce memory leak in linux

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Mon Jun 14, 2021 6:54 am
by Lech Kulikowski
Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Wed Aug 25, 2021 1:50 pm
by Ruslan Kadyrbaev
Up
Lech Kulikowski wrote: Mon Jun 14, 2021 6:54 am Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Mon Aug 30, 2021 1:06 pm
by Lech Kulikowski
Hello,

We are still working on that issue, we will let you know about the result.

Thank you.
#4797

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Fri Oct 08, 2021 1:11 pm
by Ruslan Kadyrbaev
Up((
Lech Kulikowski wrote: Mon Aug 30, 2021 1:06 pm Hello,

We are still working on that issue, we will let you know about the result.

Thank you.
#4797

Re: Unmanaged memory grows up - memory leak on Linux

Posted: Fri Oct 08, 2021 7:30 pm
by Lech Kulikowski
Hello,

We are still working on that issue, we will let you know about the result.

Thank you.