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

Minecraft server unable to start #390

Open
acokeaday opened this issue Feb 8, 2020 · 8 comments
Open

Minecraft server unable to start #390

acokeaday opened this issue Feb 8, 2020 · 8 comments

Comments

@acokeaday
Copy link

acokeaday commented Feb 8, 2020

Installed a new virtual machine, ubuntu 18.04

installed using script on install page and Java default-jre

but i'm not able to run the server, no error is shown.

minecraft@sg-dev3:~/servers/mcsvr$ cat server.properties
msm-version=minecraft/1.7.0
minecraft@sg-dev3:~/servers/mcsvr$ msm mcsvr start

Maintaining world symbolic links... Done.
Synchronising flagged worlds on disk to RAM... Done.
Starting server... Done.
minecraft@sg-dev3:~/servers/mcsvr$ msm mcsvr status
Server "mcsvr" is stopped.
minecraft@sg-dev3:~/servers/mcsvr$

Any one able to assist with this? saw a previous post with regards to memory allocation (RAM) already im sure there is enough RAM

@mikehebert
Copy link

Check your log file. It looks like yours should be here:
less ~/servers/mcsvr/logs/latest.log

@jensfriisnielsen
Copy link

jensfriisnielsen commented Feb 25, 2020

I had this issue with openjdk-11 (ubuntu 18.04 default). It turned out to be deprecated java invocation arguments from https://github.com/msmhq/msm/blob/master/msm.conf#L165

I got it working again by changing invocation from

java -Xms{RAM}M -Xmx{RAM}M -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalPacing -XX:+AggressiveOpts -jar {JAR} nogui"

to

java -Xms{RAM}M -Xmx{RAM}M -jar {JAR} nogui"

in default /etc/msm.conf

@horneraa
Copy link

horneraa commented Aug 3, 2020

The fix described by @jensfriisnielsen was the solution for me as well. What tipped it off for me was is that logs were not being created in {server}/logs for any server I tried to start.

@jeffrade
Copy link

jeffrade commented Aug 3, 2020

What tipped it off for me was is that logs were not being created in {server}/logs for any server I tried to start.

Same here.

@Darkentik
Copy link

Darkentik commented Sep 10, 2020

Could the msm.conf please be update to actual java supported params?
Struggled into this too.
Not everybody is experienced enough to find this out.

Everytime we make a msm update the msm.conf could be overwritten.

@tomscallon
Copy link

Hey all, having this exact same issue.

$ msm Bean start
world-1-17-1
Maintaining world symbolic links... Done.
Synchronising flagged worlds on disk to RAM... Done.
Starting server...Ran as_userRan server_log_dots_for_lines Done.
$ msm Bean status
Server "Bean" is stopped.

Ignore the Ran as_user and Ran server_log_dots_for_lines, I added those while debugging.

Similarly I also get no logs:

$ pwd
/mnt/minecraft/msm/servers/Bean
$ ls
active		 banned-players.json  server.jar	 whitelist.json  worldstorage
banned-ips.json  ops.json	      server.properties  world-1-17-1

My Java invocation line matches the recommended one shown above:

$ vi +165 /etc/msm.conf
# ...
DEFAULT_INVOCATION="java -Xms{RAM}M -Xmx{RAM}M -jar {JAR} nogui"
# ...

Is it likely this is also a Java issue? If so, how can I go about determining the issue?

@tomscallon
Copy link

Update! tl;dr Needed to use a newer version of Java.

More details: I modified the main msm script to print out the invocation it was using, then ran that manually. I got this:

$ java -Xms1024M -Xmx1024M -jar /mnt/minecraft/msm/servers/Bean/server.jar nogui
Error: LinkageError occurred while loading main class net.minecraft.server.Main
	java.lang.UnsupportedClassVersionError: net/minecraft/server/Main has been compiled by a more recent version of the Java Runtime (class file version 60.0), this version of the Java Runtime only recognizes class file versions up to 55.0

Searching the error on the webs, I found this Reddit post. Running the following upgraded my JDK and fixed it for me:

$ sudo apt install openjdk-17-jdk

I'm sure I should have known about the increased Java version requirement (bad system admin), but glad it's all working now!

@B-AiT
Copy link

B-AiT commented Oct 29, 2022

I am able to launch via command line:

/opt/jdk-17/bin/java -Xms2048M -Xmx2048M -jar server.jar nogui

that will drop a log file into the server /log directory.

If I launch with msm start I see the messages:

Maintaining world symbolic links... Done.
Synchronising flagged worlds on disk to RAM... Done.
Starting server... Done.

but a msm server list will show it as stopped and there is no log.

This only happens with the minecraft 1.19.2 server. I have 3 others that are on 1.17.1 and they load just fine.

I changed the /etc/msm.conf to support the OpenJDK 17 needed for MC 1.19.2
DEFAULT_INVOCATION="/opt/jdk-17/bin/java -Xms{RAM}M -Xmx{RAM}M -jar {JAR} nogui"

I run my worlds from ram and thought that might be causing my issue but I turned that to false. What other option in MSM could be causing it to not launch and not log anything?

- turns out yes, I am missing "chmod -R minecraft:minecraft *"on the new world folders. For whatever reason they were not owned by the minecraft account. Once I fixed that then MSM started the server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants