0

I am attempting to start my minecraft SMP server with 1 GB of ram, In my command prompt I have the following code:

@echo off

Title SMP Server

color a

java -Xmx1024M -Xms256M -jar server.jar nogui

When I launch the server I get the following:

Picked up _JAVA_OPTIONS: -Xmx256M
[22:09:59] [Server thread/INFO]: Starting minecraft server version 1.11.2
[22:09:59] [Server thread/WARN]: To start the server with more ram, launch it
 "java -Xmx1024M -Xms1024M -jar minecraft_server.jar"
CONTINUES TO LAUNCH PROPERLY W/ 256MB OF RAM...

I have no clue what is messing up. I've been on various websites and tried many different command lines that work for other people.

PMCJohn
  • 136
  • 1
  • 2
  • 9
  • Based off the `CONTINUES TO LAUNCH PROPERLY W/ 256MB OF RAM...` output it seems like the server launched fine. What do you mean it isn't working? You may try switching Xms and Xmx order as well I have no idea if that would affect it but it could. Also setting both to 1024M. Also if your machine only has 1GB of ram total it won't let you allocate it all for minecraft – kalenpw Mar 15 '17 at 02:24
  • @kalenpw I'm launching with the command "-Xmx1024M" and more but it's only picking up a non-present "-Xmx256M" – PMCJohn Mar 15 '17 at 02:26
  • May I ask what server software you are using? Vanilla, spigot, or sponge? Also, try it with -Xmx1G -Xms1G... – Socratic Phoenix Mar 15 '17 at 06:39
  • You want to see http://stackoverflow.com/a/29554510/3991344 if that environment variable keeps getting regenerated. – Pokechu22 Mar 15 '17 at 14:38
  • @Pokechu22 Thanks for letting me know, hasn't re-generated so far. – PMCJohn Mar 16 '17 at 15:45

1 Answers1

0

The JVM is picking up the user or system environment variable _JAVA_OPTIONS and overriding your settings. Unless you have a specific reason for limiting maximum memory, I suggest that you remove the environment variable (see System Properties → Advanced → Environment Variables... )

Frelling
  • 3,287
  • 24
  • 27