Ok so I have searched a bunch but can't seem to find the solution to my problem. Out of all the memory that I give to my server, it uses reserves 500 or so for the server.jar, so my in game allocated memory is maxMem-x, x being the 500 or so reserved for the jar. Anyway, issue is that after 2 hours or so, the reserved memory slowly starts being allocated into the in game memory until eventually in game memory = maxMem. When this happens, there is none left for the server jar, which causes my server to crash.
Let me make it clear that this does not happen because my server needs more memory. I usually have 5gb allocated, but allocated 10gb recently to see if it would help but it didn't. My server always uses between 800-3000mb even when the server jar starts losing it's reserved memory, so it isn't like the server is taking the reserved memory because it needs it.
Now I would assume it eventually loses its memory because there is nothing that says to reserved x memory for the jar file. I believe reserving memory for the jar file is done by using either the .bat or .sh files but I have 0 experience with those, and have seen start files ranging from 1 simple line, all the way to tons of code.
I have my own dedicated server box. It's a linux Debian 6 server. I believe this is relevant because I read that .bat is for windows and .sh is for Linux? My current .sh file is empty, and my .bat file contains "java -Xms512M -Xmx1G -jar ftbserver.jar". This is also useless anyway I would assume since I named my jar to mcpclegacy15. I just never changed the .bat because I read that was only for windows.
Any help would be greatly appreciated.
Let me make it clear that this does not happen because my server needs more memory. I usually have 5gb allocated, but allocated 10gb recently to see if it would help but it didn't. My server always uses between 800-3000mb even when the server jar starts losing it's reserved memory, so it isn't like the server is taking the reserved memory because it needs it.
Now I would assume it eventually loses its memory because there is nothing that says to reserved x memory for the jar file. I believe reserving memory for the jar file is done by using either the .bat or .sh files but I have 0 experience with those, and have seen start files ranging from 1 simple line, all the way to tons of code.
I have my own dedicated server box. It's a linux Debian 6 server. I believe this is relevant because I read that .bat is for windows and .sh is for Linux? My current .sh file is empty, and my .bat file contains "java -Xms512M -Xmx1G -jar ftbserver.jar". This is also useless anyway I would assume since I named my jar to mcpclegacy15. I just never changed the .bat because I read that was only for windows.
Any help would be greatly appreciated.