Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autopause freeing memory #2641

Closed
Player505 opened this issue Feb 7, 2024 · 1 comment
Closed

Autopause freeing memory #2641

Player505 opened this issue Feb 7, 2024 · 1 comment

Comments

@Player505
Copy link

Enhancement Type

Improve an existing feature

Describe the enhancement

I'm not sure if this is even possible as it might be a limitation with java but is there a way to have the auto-pause functionality free up memory when paused?

This would be useful when running multiple server instances on one box where the sum of the allocated memory for each instance exceeds the amount of memory avalible but only one or two instances aren't paused at a time.

@itzg
Copy link
Owner

itzg commented Feb 7, 2024

That's a reasonable request, but is impossible. It's simply a Linux-process thing -- a paused process still holds on to the memory that it was allocated. If you have swap enabled then the kernel will page out the inactive memory.

Instead take a look at https://docker-minecraft-server.readthedocs.io/en/latest/misc/autopause-autostop/autostop/ or https://docker-minecraft-server.readthedocs.io/en/latest/misc/examples/#lazytainer-stop-minecraft-container-based-on-traffic

@itzg itzg closed this as not planned Won't fix, can't repro, duplicate, stale Feb 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants