OS: Windows Server 2012
Version: 0.1.3 dev
Commit/Build: d0ad94b
When I start to host an online server the instance uses 12MB of ram. After three days this usage goes up to 500MB+. Eventually openrct2.exe will use all system memory. See attached screenshots.
Steps to reproduce:
Dump file
Screenshots / Video:


Save game:
We'll take a look, can you provide any more hints what's needed for reproducing this? Is running the server enough or does it need clients connect and perform actions? Maybe just clients connecting (without doing anything) is enough?
Janisozaur, I'm not sure. I will run another instance but block connections to it on the firewall to test if it only happens when users connect.
How exactly do you launch your servers?
I was able to determine the increase in memory usage is not effected by users connecting to the server.
The servers are being launched in headless mode via a little script. Here are the arguments I use.

Does it also happen with the headless binary? Or is the full client required?
I always use the full client. not sure about headless binary.
@janisozaur We do not distribute a headless binary for Windows as it isn't necessary.
We're having trouble reproducing the issue. Does this happen with a particular park, or after particular game actions?
It would also be a big help if we could narrow the issue down to a particular change or series of changes. Do you remember when this started happening, @mozar99?
I believe this started to happen after a network update but i cant say what update. I have added the map I use for hosting. Maybe its due to the ride selection / themes used in this map.
mozarTemplate.zip
I tried to tackle this but I'm unable to actually reproduce it. I loaded your park and left it running for over 3 days and it never went above 200mb~ in total.
So I have two theories:
To provide further assistance would you be so kind to create a full process dump of openrct2.exe after a day when it starts to increase in memory use?
You can do this by launching the Task Manager, select openrct2.exe process, right click and select "Create dump file", specify your location and save it. Once thats done please put it into an zip/rar and upload it here.
This will allow me to inspect the allocated memory regions and your loaded binaries.
Hi ZahMatt,
Thank you for all your assistance on this. I have created a dump file. uncompressed its 1.4GB, the zip is 612MB. If its too big I can get a smaller dump.
http://67.41.198.94/mnt/openrct/mozarOpenRCTexe.zip
thanks,
Well its typical if you dump the whole process including all its memory, thanks. I will have a look this weekend.
Based on discussion around https://gitter.im/OpenRCT2/OpenRCT2?at=5b2d3248d2abe46688809a42 https://gitter.im/OpenRCT2/OpenRCT2?at=5b325df90168e70c08f05057 and https://gitter.im/OpenRCT2/OpenRCT2?at=5b3389936ceffe4eba378690 it seems the prerequisites for this are:
running .exe (.com doesn't seem to exhibit the problem) with --headless option. There is no need for any clients to be connected.
Can you recheck with b278dce or later please?
I upgraded the servers yesterday. Running 0.2.0-169 ( 79f1cf5 ) and I'm still seeing the same memory issue. Happy to upload another memory dump if you want.

@mozar99 Could you try with one of the AppVeyor artifacts for #7836?
I believe the memory issue has been fixed. only 22mb of ram is being used. thank you!
Wow, that's great to hear! Thanks for testing.
Most helpful comment
I tried to tackle this but I'm unable to actually reproduce it. I loaded your park and left it running for over 3 days and it never went above 200mb~ in total.
So I have two theories:
To provide further assistance would you be so kind to create a full process dump of openrct2.exe after a day when it starts to increase in memory use?
You can do this by launching the Task Manager, select openrct2.exe process, right click and select "Create dump file", specify your location and save it. Once thats done please put it into an zip/rar and upload it here.
This will allow me to inspect the allocated memory regions and your loaded binaries.