"Cleaning up physics because repository is full." Crashes.

    Joined
    Jul 30, 2013
    Messages
    91
    Reaction score
    0
    I've had my server running for quite a while now, and it sees a good amount of traffic (around 20-25 at peak hours), with quite a few epic builders. The more players are online, the more I see this message in the console:


    Cleaned up Physics, because repository is full

    As this issue persists, players begin to experience connection issues. This message eventually begins to spam in huge amounts, once in a while also showing the message:


    Java HotSpot(TM) 64-Bit Server VM warning: Attempt to deallocate stack guard pages failed.

    Right about the time this shows up, the server becomes completely unresponsive, everyone loses connection, and I lose the ability to connect to the server in any way to issue /shutdown command.

    I have no idea how to prevent this issue, and it seems much more prevelent since the last update (0.093932). Watching the ram, it never appears to reach the ceiling. I'm at my wits end and I hate seeing my players suffer.

    If anyone else is having this issue or has any idea what is causing it/how to fix it, please reply!
     
    Joined
    Jul 8, 2013
    Messages
    122
    Reaction score
    13
    • Legacy Citizen 5
    • Purchased!
    You\'re server might not be running enough memory. Whatever you using to start the server either the .bat file for windows or the .sh file for linux open it. Then look for this line here \"java -Xms128m -Xmx1024m -jar StarMade.jar -server\"

    The -Xms128m is the minimum value of ram java will allocate to java. the -Xmx value is the largest value of ram java will allocate. So to change your max value of ram java will allocate we would just change the -Xmx value. Example if we wanted 2GB of ram to allocate to java. We would change -Xmx1024 to -Xmx2048. The -Xms value you can just leave alone unless you want to force it to start with more ram instead of allocating more as it needs it.
     

    schema

    Cat God
    Joined
    Feb 17, 2012
    Messages
    1,552
    Reaction score
    2,604
    • Schine
    To explain what that means. To keep the game\'s performance consistent, I\'m using a pool of physics contexts. Each sector needs its own context, and those come with a certain price: to ensure physics perfromance, there has to be some data allocated. When a sector unloads it tried to give back its context to the pool, so another sector can take it without having to load a new one.

    However to not induce a leak, the repository(pool) is not infinite, so if the size of the pool exceeds a certain number (size as in available physics contexts that may be taken), the system will clean it up instead and leave it to be garbage collected.

    However there might still be a small leak somewhere where the data is maybe not completely cleaned.

    As crazy6117 said, the way to work around that is to increase the memory limit java may allocate in total.
     
    Joined
    Jul 31, 2013
    Messages
    12
    Reaction score
    0
    • Legacy Citizen 2
    • Legacy Citizen
    Thanks for the prompt response Crazy5227 and schema. I hope it is as simple as encouraging Java to use more memory, the server apparently has ~32gb of it.