Overclock.net banner

1 - 13 of 13 Posts

·
Eh, Wha?
Joined
·
9,943 Posts
Discussion Starter #1
I've been running a server on a win 7 64bit machine with 4GB of ram, launching with a .bat file with the following parameters:

@echo off
"%ProgramFiles(x86)%\Java\jre6\bin\java.exe" -Xms1024M -Xmx1536M -jar minecraft_server.jar gui
pause

So far so good, however I recently grabbed another 8GB of ram for a total of 12. I want to allocate more memory to minecraft by increasing the parameters of the .bat file. I initially attempted xms2048 xmx3072 which failed. I then attempted xms1536 xmx3072 followed by xms1536 xmx2048. These both also failed.

Each time, I get the error "Error occurred during initialization of VM Could not reserve enough space for object heap Could not create the Java Virtual Machine"

Task manager shows less than 2GB being used by the system and other programs (such as [email protected]). Quite obviously, I have more than enough available memory, so why is it unable to be allocated?

Thanks.

PS - The system is "***urou" in my sig.
 

·
Banned
Joined
·
3,061 Posts
Watching this thread now. In the process of upgrading my personal MC server to a quad with 8gb of ram and will need to know this info.
 

·
Eh, Wha?
Joined
·
9,943 Posts
Discussion Starter #4
Quote:
Originally Posted by beers;13829613
32 bit Java?
Does it go away with xmx 2036?
Oh dear... I didnt notice it was running 32 bit. Let me fix that...
doh.gif
 

·
Premium Member
Joined
·
2,767 Posts
Quote:
Originally Posted by Zero4549;13829854
Oh dear... I didnt notice it was running 32 bit. Let me fix that...
doh.gif
Just a side note, they only provide the 64-bit download link if you're using a 64-bit browser.
 

·
Eh, Wha?
Joined
·
9,943 Posts
Discussion Starter #6
Quote:
Originally Posted by C-bro;13829902
Just a side note, they only provide the 64-bit download link if you're using a 64-bit browser.
There's a 64 bit version that is not tied to any browser (i think its called the "offline" windows 64bit java 6 26" or some such under their "all java downloads" page. I downloaded that a while ago. It seems o be working as I just adjusted the line in the .bat file and the server booted right up with 4gb of memory
 

·
Banned
Joined
·
3,061 Posts
Quote:
Originally Posted by Zero4549;13829978
There's a 64 bit version that is not tied to any browser (i think its called the "offline" windows 64bit java 6 26" or some such under their "all java downloads" page. I downloaded that a while ago. It seems o be working as I just adjusted the line in the .bat file and the server booted right up with 4gb of memory
So, question for you. Since the server I'm using will pretty much ONLY be an MC server, what line will I need to use to enable 4-5gb of ram?
 

·
Eh, Wha?
Joined
·
9,943 Posts
Discussion Starter #8
Quote:
Originally Posted by Marafice Eye;13830097
So, question for you. Since the server I'm using will pretty much ONLY be an MC server, what line will I need to use to enable 4-5gb of ram?
If you are running nothing other than MC, I'd suggest using a lightweight Linux distro, you would get better performance and stability (you might even be able to do a bit of very light folding and STILL get better performance).

That said, If you are going to be running this on windows 7 64 bit, AND you have ensured you have downloaded Java 6 64bit, you want to create a .bat file to launch the server with and put this line in it in order to use the amount of memory you requested:

@echo off
"%ProgramFiles%\Java\jre6\bin\java.exe" -Xms4096M -Xmx5120M -jar minecraft_server.jar gui
pause

Make sure you are using the .jar version of the minecraft server if you want this to work. To the best of my knowledge, the .exe version automatically allocates memory and cannot be changed.

Also if you wish to run with no GUI (just the command line) you will need to also input the nogui line which would look like this:

@echo off
"%ProgramFiles%\Java\jre6\bin\java.exe" -Xms4096M -Xmx5120M -jar minecraft_server.jar nogui
pause

If everything is in order, either of these lines will launch your server with 4GB of memory allocated at all times, with the option of expanding upward to 5GB. Just FYI you would need maybe 40 people in the server (and enough bandwidth to supply them... 15up or so) for you to ever need to expand upward past 4. A more conservative value might be -Xms2048M -Xmx4096M which will launch with 2GB and allow it to grow up to 4GB.

Remember, Java does not perform full GC until the entire allocation is full. This means your server could be sitting on 5GB of RAM but only be actively using 2GB for hours or even days at a time. Starving your system of memory can slow the whole thing down so it is a better idea to allow your system to have some breathing room than to allocate way more than you need for minecraft at the cost of leaving very little for the OS. (If you are running 8+ GB and absolutely nothing else is running on the computer, 5GB is not really a problem)
 

·
Banned
Joined
·
3,061 Posts
Thanks man. +Rep for the explanation. Yes currently its a personal server for me and a few friends and it's running on an old Dell Poweredge SC420 server.

Win 7 x86
P4 dual core @2.8ghz
3gb ram
no video card, just intel's minor video capabilities for a server.

It can't even run the game, but it runs a server ok.

I'm building a new server for a shade under $400 with

RaidMax Iceberg case $50
Biostar A770E3 mobo $50
Phenom II X4 955 Black Edition $115
Antec BP550 Plus PSU $65
8gb G Skill DDR3 1066 Ripjaw Series $75

With tax (damn living in Cali) and shipping it's $392 bucks.

Pretty decent imo for a $400 budget

I'll also be putting in an old Geforce 7900GT 256mb just on the off chance I need to run the game on the server, but that will be very rare since I primarily play on my laptop (sig rig lol)

Oh and yes it will be running Win 7 x64, so I'll snag the 64bit ver of Java (which I have on my laptop)

The only other thing I do with it is store my media on it. so I can access it from my laptop over the network. I won't be doing video/photo editing, or 3D rendering, or any gaming other than maybe MC from time to time.

Does this setup sound like a decent build for a personal server? running maybe, and I mean maybe, half a dozen people?

If not, what changes should I make? And keep in mind it's a $400 budget, and I'm not re-using the old dell case, too much of a hassle and shiesty cooling.
 

·
Eh, Wha?
Joined
·
9,943 Posts
Discussion Starter #10
Quote:
Originally Posted by Marafice Eye;13831718
Thanks man. +Rep for the explanation. Yes currently its a personal server for me and a few friends and it's running on an old Dell Poweredge SC420 server.

Win 7 x86
P4 dual core @2.8ghz
3gb ram
no video card, just intel's minor video capabilities for a server.

It can't even run the game, but it runs a server ok.

I'm building a new server for a shade under $400 with

RaidMax Iceberg case $50
Biostar A770E3 mobo $50
Phenom II X4 955 Black Edition $115
Antec BP550 Plus PSU $65
8gb G Skill DDR3 1066 Ripjaw Series $75

With tax (damn living in Cali) and shipping it's $392 bucks.

Pretty decent imo for a $400 budget

I'll also be putting in an old Geforce 7900GT 256mb just on the off chance I need to run the game on the server, but that will be very rare since I primarily play on my laptop (sig rig lol)

Oh and yes it will be running Win 7 x64, so I'll snag the 64bit ver of Java (which I have on my laptop)

The only other thing I do with it is store my media on it. so I can access it from my laptop over the network. I won't be doing video/photo editing, or 3D rendering, or any gaming other than maybe MC from time to time.

Does this setup sound like a decent build for a personal server? running maybe, and I mean maybe, half a dozen people?

If not, what changes should I make? And keep in mind it's a $400 budget, and I'm not re-using the old dell case, too much of a hassle and shiesty cooling.
It ought to works quite well for a small server. You should run at 2-4gb memory allocation at max btw for such a small server. No need to let MC eat up all the ram and slow the whole system in the process. Id say 1.5-3g (min-max) ought to be just a bit more than your server will be able to make use of in most conditions. This can give you some extra room for running some other things on the machine if wanted. Of course, if you don't want to do anything else on the machine, use 4gb by all means.

Oh, are you using any mods on the server? Flying and teleporting can be more demanding than just walking, for example.

At any rate, you should be set with that rig. Good luck buddy!
 

·
Premium Member
Joined
·
5,111 Posts
Quote:
Originally Posted by Zero4549;13830405
If you are running nothing other than MC, I'd suggest using a lightweight Linux distro, you would get better performance and stability (you might even be able to do a bit of very light folding and STILL get better performance).

That said, If you are going to be running this on windows 7 64 bit, AND you have ensured you have downloaded Java 6 64bit, you want to create a .bat file to launch the server with and put this line in it in order to use the amount of memory you requested:

@echo off
"%ProgramFiles%\Java\jre6\bin\java.exe" -Xms4096M -Xmx5120M -jar minecraft_server.jar gui
pause

Make sure you are using the .jar version of the minecraft server if you want this to work. To the best of my knowledge, the .exe version automatically allocates memory and cannot be changed.

Also if you wish to run with no GUI (just the command line) you will need to also input the nogui line which would look like this:

@echo off
"%ProgramFiles%\Java\jre6\bin\java.exe" -Xms4096M -Xmx5120M -jar minecraft_server.jar nogui
pause

If everything is in order, either of these lines will launch your server with 4GB of memory allocated at all times, with the option of expanding upward to 5GB. Just FYI you would need maybe 40 people in the server (and enough bandwidth to supply them... 15up or so) for you to ever need to expand upward past 4. A more conservative value might be -Xms2048M -Xmx4096M which will launch with 2GB and allow it to grow up to 4GB.

Remember, Java does not perform full GC until the entire allocation is full. This means your server could be sitting on 5GB of RAM but only be actively using 2GB for hours or even days at a time. Starving your system of memory can slow the whole thing down so it is a better idea to allow your system to have some breathing room than to allocate way more than you need for minecraft at the cost of leaving very little for the OS. (If you are running 8+ GB and absolutely nothing else is running on the computer, 5GB is not really a problem)
Great post man + rep, you beat me to it an explained it a heel of a lot better than my tired ass would have.

I host on win7 and it works just fine! More ram is never a bad thing with minecraft and bukkit. the more plugins you run the more ram you will use. plus minecraft and bukkit plugins tend ot get memory leaks so more ram will compensate for this between restarts
 

·
Banned
Joined
·
3,061 Posts
Quote:


Originally Posted by Zero4549
View Post

It ought to works quite well for a small server. You should run at 2-4gb memory allocation at max btw for such a small server. No need to let MC eat up all the ram and slow the whole system in the process. Id say 1.5-3g (min-max) ought to be just a bit more than your server will be able to make use of in most conditions. This can give you some extra room for running some other things on the machine if wanted. Of course, if you don't want to do anything else on the machine, use 4gb by all means.

Oh, are you using any mods on the server? Flying and teleporting can be more demanding than just walking, for example.

At any rate, you should be set with that rig. Good luck buddy!

I knew I was going to forget to mention something. Yes we run Bukkit with a few mods.

WorldEdit (not used a whole lot but very hand to have when clearing space. We prefer to hand build)
RocketBoots
RemoteDet
ChopTree
HookShot
OpenInv
PressurePorts
PrivateWarp
VoxelDoop


 

·
Bass Enabler
Joined
·
944 Posts
Oh btw, Marafice, it's a Geforce 7600GT that I gave you. Not a 7900GT.


We look forward to our new server gear!
 
1 - 13 of 13 Posts
Top