Jump to content

Java (MC server) issue. JNI error

I am trying to update my Minecraft server to the most current 1.17 version. But I keep getting an error that I can not seem to fix. I have tried Jarfix, updating Java, trying to make a new server (got the same error), and updating windows.

Capture.PNG

Link to comment
Share on other sites

Link to post
Share on other sites

You probably only have the latest version of Java 8, Minecraft 1.17 requires Java 16 or newer. I'd suggest going for OpenJDK since there's some extra legal non sense if you get it straight from oracle. Then you'll probably have to specify within the config files to use Java 16 instead of whatever it's currently using. This isn't an issue with the normal minecraft launcher because it comes prepackaged with it. I copied this insert from minecraft.fandom.com which explains this better than I do

Quote

Why update?

The latest versions of Java contain important enhancements to help improve performance, stability and security of the Java applications that run on your machine. Installing the latest Java update ensures that Minecraft continues to run safely and efficiently.

  • Different Minecraft versions have different requirements of minimum Java version.
  • Minecraft may sometimes crash without being run by a relatively modern version of Java.
  • Java updates fix lots of problems and bugs and typically cause increases in performance.
    • For example, the newer garbage collectors can help with lag spikes during high memory usage.[4]
  • Running a server requires your computer to have Java installed instead of the pre-installed Java. See Tutorials/Setting up a server for more information.

Where to download

You can get Java either from Oracle or from someone who builds OpenJDK. For the purpose of Minecraft they are essentially the same, but Oracle's "OTN" version requires a PAID license for commercial and production purposes. If you make money from streaming Minecraft or running a Minecraft server (even non-profit), you MUST use OpenJDK unless you want to figure out how to pay.

You will see that Java is divided into LTS (long-term support) like 11 and STS (short-term support) version numbers like 16. An LTS version will be given updates for longer, so people tend to use them as a stable standard of "modern, but not too new" Java.

I downloaded AdoptOpenJDK which worked fine for me.

Link to comment
Share on other sites

Link to post
Share on other sites

Search Java 16 on the web and install it.Minecraft 1.17 needs the Java 16 SDK to work.When you have Java 16 installed.Open your Minecraft Launcher,go to settings and find Java path.The current version selected should be Java 8.Click browse and Navigate to C:\Program Files\Java\jdk-16.0.1\bin and select the javaw.exe file in it.Now try launching your server again.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×