rki-covid-api icon indicating copy to clipboard operation
rki-covid-api copied to clipboard

Performance problems, Memory Leaks

Open marlon360 opened this issue 2 years ago • 5 comments

Bildschirmfoto 2021-11-01 um 11 59 34

This chart shows the CPU usage and the memory consumption on the server. The dotted line marks a server restart.

The memory consumption increases over time, which indicated a memory leak and missing garbage collection. Furthermore the CPU spikes to 100% from time to time.

Help is really appreciated to eliminate these problems.

marlon360 avatar Nov 01 '21 11:11 marlon360

Hi Marlon, maybe thats the rediscache.When the rediscache is starting up, there is a Report that a configuration is missing. I dont know the exact report, and i m on vaccation in the moment.....Maybe you should check this.....Am 01.11.2021 12:05 schrieb Marlon Lückert @.***>:

This chart shows the CPU usage and the memory consumption on the server. The dotted line marks a server restart. The memory consumption increases over time, which indicated a memory leak and missing garbage collection. Furthermore the CPU spikes to 100% from time to time. Help is really appreciated to eliminate these problems.

—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or unsubscribe.Triage notifications on the go with GitHub Mobile for iOS or Android.

Rubber1Duck avatar Nov 01 '21 15:11 Rubber1Duck

The Message what i meen is this

WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.

Rubber1Duck avatar Nov 05 '21 17:11 Rubber1Duck

The memory usage of Redis is fine: Bildschirmfoto 2021-11-12 um 11 00 54

There are some large objects that are held in memory. But it is really hard to debug that problem.

marlon360 avatar Nov 12 '21 10:11 marlon360

Did you have this Issue as bevor you switched to railway, too?

Rubber1Duck avatar Nov 12 '21 13:11 Rubber1Duck

Yes I think so. But the old server was a fixed price with 32GB RAM included and with Railway it is pay-per-usage, which means I am paying for every single MB of RAM that is currently used. So we can reduce costs with every MB we save.

In front of the railway server is a cloudflare cdn, where I cache the requests. So most of the traffic is actually not hitting the server: 1F5B7EBE-0A3E-40BE-A3EA-E1519EC50A4D

marlon360 avatar Nov 12 '21 13:11 marlon360