I updated from Minecraft 1.16.2 to the latest version of Minecraft at this time which is 1.18.1, opened the Minecraft Launcher client, selected "Latest release 1.18.1" from the drop down, hit the "PLAY" button, and received an error message "jni error has occurred" (and also a generic java error and a crash following that).
Running on Windows 10 Home, 64-bit, Version 21H2, Build 19043.1415, with Intel i7.
Tried a lot of things so far. This is the current state of my setup:
I now have only these folder containing java executables as far as I know:
C:\Program Files\Java\jdk-17.0.1\bin
C:\Program Files\Java\jre1.8.0_311\bin
C:\Program Files (x86)\Common Files\Oracle\Java\javapath
C:\ProgramData\Oracle\Java\javapath
C:\Users\[USER]\AppData\Local\Packages\Microsoft.4297127D64EC6_8wekyb3d8bbwe\LocalCache\Local\runtime\jre-legacy\windows-x64\jre-legacy\bin
As far as env variables that mention java, jdk, or jre, I have only these:
System Properties: Advanced: Environment Variables:
JAVA_HOME
=C:\Program Files\Java\jdk-17.0.1
Path
=C:\Program Files\Java\jdk-17.0.1\bin
Minecraft Launcher has this setting:
Installations tab: Latest release: More options: Java executable:
C:\Program Files\Java\jre1.8.0_311\bin\javaw.exe
From command prompt...
C:\Users\[user]>javac -version
javac 17.0.1
C:\Users\[user]>java -version
java version "17.0.1" 2021-10-19 LTS
Java(TM) SE Runtime Environment (build 17.0.1+12-LTS-39)
Java HotSpot(TM) 64-Bit Server VM (build 17.0.1+12-LTS-39, mixed mode, sharing)
Some highlights of other things I tried so far:
• Tried using ecosia and superuser search to find the error message, but those solutions were basically just "update java".
• Updated java by using the Java Control Panel, like described here which got me a new JRE:
https://java.com/en/download/help/win_controlpanel.html
• Uninstalled everything minecraft in Add/Remove programs dialog, reinstalled everything (and of course restarted the launcher and computer numerous times in between various attempts).
• Thought maybe "update java" is ambiguous, so I went to get a new JDK too:
https://www.oracle.com/java/technologies/downloads/#jdk17-windows
• Downloaded from here:
https://download.oracle.com/java/17/latest/jdk-17_windows-x64_bin.exe
Not sure why the naming convention changed: Used to be jdk-1.8.0_152
but is now jdk-17.0.1
. No big deal, I assume.
• Before this update the Minecraft Launcher had a visible EXE and various files and folders alongside (as well as a related workaround for a jni-related bug that mentioned bundling which I believe affected the launcher itself), but the current version lacks a visible EXE and folders, and therefore I see no way to try such workarounds anymore.
I believe this is the "bundled" version referred to here:
https://www.windowscentral.com/minecraft-pc-bundle-announced
The Minecraft Launcher identifies itself like this:
*Launcher for Windows*
Windows 10.0 2.2.8542
Thursday, December 16, 2021, 7:53:50 PM
02b800b20f858c2d92d48bd57b1ae2bc5773f175
*Bootstrap*
113
Friday, December 17, 2021, 3:52:10 PM
7fbe7a8a2670ec54ab3a005aaa0ee0bf311fd9f7
*UI*
8375
Thursday, December 16, 2021, 7:44:31 PM
02b800b20f858c2d92d48bd57b1ae2bc5773f175
The "Report a Launcher bug" link goes to https://bugs.mojang.com which I can't access due to this issue:
Google Authenticator infinite loop on bugs.mojang.com
None of that seemed to have any effect. Error persists.
I tried to get a crash report like so...
https://minecraft.fandom.com/wiki/Tutorials/How_to_get_a_crash_report
...but there were no crash reports of either kind (.txt or .log) that are from any recent day.
Interesting comparisons:
If I tell the Launcher to use java.exe
instead of javaw.exe
I don't get the jni error message, but Minecraft immediately crashes nonetheless.
If I select Minecraft 1.16.2 in the Minecraft Launcher's dropdown list, that still launches fine.
C:\Program Files\Java\jdk-17.0.1
edit your environmental variables to reflect that. Be sure you uninstall outdated and any unsupported versions of Java.C:\Program Files\Java\jdk-17.0.1
andC:\Program Files\Java\jre1.8.0_311
and for environment variables that mention java, jdk, or jre, I have only these:JAVA_HOME
=C:\Program Files\Java\jdk-17.0.1
andPath
=C:\Program Files\Java\jdk-17.0.1\bin
...C:\ProgramData\Oracle\Java\javapath
. But error persists.\bin
fromC:\Program Files\Java\jdk-17.0.1\bin
inPath
, in case you meant "path to Java" strictly (though previously bin was needed). Also tried removingJAVA_HOME
since that's an env var and value is a different "path to Java", so to speak, since "Java" is one of the foldernames in that path. As expected, neither of those worked, but I thought maybe the mental exercises might spark some insight into your charmingly ambivalent response. I figure it's something straightforward I'm interpreting wrong, because if it were complex or subtle, you'd have said what it is.