Following https://www.hanselman.com/blog/how-to-use-a-raspberry-pi-4-as-a-minecraft-java-server to make a Minecraft server. The only thing I changed is the server jar itself, BUT Minecraft 1.18.2 requires Java 18. Installed it from snap when I tried to run it said bash: java command not found
TL;DR: Trying to run Java 18 from snap in terminal (Sorry for the bad English. It's not my main language)
-
1What's the question? What part doesn't work? How does it fail?Dougie– Dougie2022年05月02日 15:32:32 +00:00Commented May 2, 2022 at 15:32
-
Did you install default-jdk?Thorbjørn Ravn Andersen– Thorbjørn Ravn Andersen2024年10月19日 18:14:36 +00:00Commented Oct 19, 2024 at 18:14
2 Answers 2
Follow the instructions on this website: https://computingforgeeks.com/install-oracle-java-18-on-ubuntu-debian/. Try following part 1 first, and if that fails, try following part 2.
To run 1.18.x - 1.19.x Minecraft server you need JDK 17, JDK 18 will likely be unstable.
On PI you can install TemurinJDK (ex Adoptopenjdk) distribution by following their instructions.
Do note that you will likely need to put sudo
before tee
.
I'm currently able to install TemurinJDK 8, 11, 17 and 18.
If you can't find the version you are looking for, you can look into older Adoptopenjdk distributions (8, 11-16)