Profiling Server Memory Leaks

Hi everyone!

I have a simple Linux test server running on Unity's Game Server Hosting, but I've noticed the Memory usage continues to increase ever so slightly every minute, even when Online/Allocated with no clients connected. It grows by an average of 0.125 MiB (~130 kb) a minute, so I'm worried there may be a memory leak somewhere. CPU usage, on the other hand, remains stable. This happens both on Multiplay-allocated servers and manually-started ones.

Has anyone else experienced DGSs behaving in this way? I'm wondering if there might be some overhead in Multiplay Services that could be causing this, although it's also likely that the issue lies on my end and on my implementation. I am updating SQP via UpdateServerCheck on every fixed frame, after all.

I was hoping I could use Unity's Profiler to remotely connect to the server and monitor it, but I'm not sure which IP and Port are needed for this. Do I use the port of the specific server instance (i.e 9000), or the 55000 that is normally used for this?

Alternatively I could build a Windows-based server to run locally and profile that one instead, assuming the issues persists there.

Just to give you some context, I'm currently using Unity 2022 LTS with Mirror for networking.

Thanks in advance!

P.S Not sure if this is the correct forum category to post this under, let me know If I should move it.

1 Like

Hi Marco,
My colleague Alexey answered the part about how to deal with the Multiplay server ports for profiling over in this thread .
[quote=“alexeyzakharov”, post:2, topic: 911580]
f you use development player, then you should be able to connect to the server by IP with the Memory Profiler.

There should be no port blocking by default on the Multiplay side.
Unity players listen on the
55000
port by default and you can also specify is in the cmdline or BootConfig parameter as
player-connection-listen-address
[/quote]

But yes, your alternative with a local build might also work if it persists.

1 Like