When I try to run my newly installed Netbeans, I get:
org.netbeans.InvalidException: StandardModule:org.netbeans.modules.db jarFile: /usr/share/netbeans/10.0/ide/modules/org-netbeans-modules-db.jar: java.lang.UnsupportedClassVersionError: org/netbeans/lib/ddl/DBConnection has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
Why is this happening? I believe my JRE is right:
$ java -version
openjdk version "11.0.17" 2022-10-18
OpenJDK Runtime Environment (build 11.0.17+8-post-Ubuntu-1ubuntu220.04)
OpenJDK 64-Bit Server VM (build 11.0.17+8-post-Ubuntu-1ubuntu220.04, mixed mode, sharing)
Just in case it matters, I do have (and need to keep) an older JDK, but I didn't think it would stop Netbeans from even starting:
$ javac -version
javac 1.8.0_352
And if it makes any difference, here are some more terminal snippets:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.5 LTS
Release: 20.04
Codename: focal
$ update-alternatives --config java
There are 4 choices for the alternative java (providing /usr/bin/java).
Selection Path Priority Status
---------------------------------------------
0 /usr/lib/jvm/bellsoft-java8-full-i586/bin/java 20803523 auto mode
1 /usr/lib/jvm/bellsoft-java8-full-i586/bin/java 20803523 manual mode
* 2 /usr/lib/jvm/java-11-openjdk-amd64/bin/java 1111 manual mode
3 /usr/lib/jvm/java-8-openjdk-amd64/jre/bin/java 1081 manual mode
4 /usr/lib/jvm/zulu11/bin/java 2116001 manual mode
Finally, here is a snippet from the desktop. I get that whether I run Netbeans from the xfce menu or from a terminal window, and the latter doesn't provide any logs etc. If I click "Disable Modules and Continue" the splash screen stays on for some 15 seconds, then disappears.
I would love it if my question already has an answer and I just failed to find it.