I've installed GeoServer by:
1 Installing Java JDK 18 with the x64 Installer
C:\>java -version
java version "18.0.1.1" 2022-04-22
Java(TM) SE Runtime Environment (build 18.0.1.1+2-6)
Java HotSpot(TM) 64-Bit Server VM (build 18.0.1.1+2-6, mixed mode, sharing)
2 Downloading and extracting Platform Independent Binary to D:\Program\GeoServer
3 Creating the environmental system variables
JAVA_HOME : D:\Program\Java
GEOSERVER_HOME : D:\Program\GeoServer
GEOSERVER_DATA_DIR : D:\Program\GeoServer\data_dir
The server starts and I can access the admin interface (http://localhost:8080/geoserver/web/) but I cant access the wms services at http://localhost:8080/geoserver/wms (Failed to parse capabilities), I cant preview the layers, and when I click "Server status" in the admin interface I get
HTTP ERROR 500 javax.servlet.ServletException: org.springframework.web.util.NestedServletException: Handler dispatch failed; nested exception is java.lang.NoClassDefFoundError: Could not initialize class java.awt.GraphicsEnvironment$LocalGE ...
Is there a problem with Java, or what is the problem?