DarkPacks / SevTech-Ages

SevTech: Ages is a massive Minecraft modpack packed with content and progression.
https://minecraft.curseforge.com/projects/sevtech-ages
GNU General Public License v3.0
229 stars 79 forks source link

Server crash after running install.bat #4854

Closed Lollerix closed 8 months ago

Lollerix commented 8 months ago

Bug Description

After a fresh install using the provided scripts the server will not start and give this error A problem occurred running the Server launcher.java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:110) at java.base/java.lang.reflect.Method.invoke(Method.java:578) at net.minecraftforge.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:70) at net.minecraftforge.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:34) Caused by: java.lang.ClassCastException: class jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to class java.net.URLClassLoader (jdk.internal.loader.ClassLoaders$AppClassLoader and java.net.URLClassLoader are in module java.base of loader 'bootstrap') at net.minecraft.launchwrapper.Launch.(Launch.java:34) at net.minecraft.launchwrapper.Launch.main(Launch.java:28) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) ... 3 more

Client Information

Server Information

github-actions[bot] commented 8 months ago

@Lollerix: hello! :wave:

This issue is being automatically closed because it does not follow the issue template.

sam-kirby commented 8 months ago

You aren't using the version of Java you think you are; Java 8 has no concept of modules, but the stack trace mentions them.

Either remove the later version of Java or edit the start script so that it uses Java 8 by absolute path, e.g.

@echo off

call settings.bat

:start_server
echo Starting Sky Factory 4 Server...
"C:\Program Files\Java\jre-1.8\bin\java.exe" -server -Xms%MIN_RAM% -Xmx%MAX_RAM% %JAVA_PARAMETERS% -jar %SERVER_JAR% nogui
pause
exit /B

goto start_server

Note that the quotes around the path are required.