You are not logged in.
Hi there,
I am running airsonic (Musik Jukebox Server) for some years now.
When I set up my system, I used
java-8-openjdk/jreas default Java. Airsonic runs just nice with it.
Now, years later, my son wants his own Minecraft Server, and I installed the mincraft-server. package. As minecraft needs a more up-to-date Java version, I installed java-20-openjdk. I did a
archlinux-java set java-20-openjdkand Minecraft runs just fine.
My problem is, that Airsonic stopped working, and complains about the wrong java version.
I tried to edit/override the airsonic.service file with
[Service]
Environment="JAVA_HOME=/usr/lib/jvm/java-8-openjdk/jre"followed by
systemctl daemon-reload...but Airsonic won't come up again.
If I switch back to java-8 with
archlinux-java set java-8-openjdk/jreAirsonic will start up again, but Minecraft wont... ![]()
So, what else could I do in order to bind that java-8 version to airsonic?
greetings
Joe
Offline
According to the wiki, there should be no trailing /jre in JAVA_HOME (for the systemd ENVIRONMENT setting)
Environment=JAVA_HOME=/usr/lib/jvm/java-8-openjdk
# not
#Environment="JAVA_HOME=/usr/lib/jvm/java-8-openjdk/jre"Last edited by Trilby (2023-05-03 18:21:20)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
thx,
the folder /usr/lib/jvm/java-8-openjdk/jre exists, having bin/java as a subfolder...
I removed "/jre" but still the same error/problem
edit:
as the airsonic.service looks like this:
[Service]
Type=simple
Environment="JAVA_JAR=/var/lib/airsonic/airsonic.war"
Environment="JAVA_OPTS=-Xmx700m"
Environment="AIRSONIC_HOME=/var/lib/airsonic"I added
[Service]
Environment="JAVA_HOME=/usr/lib/jvm/java-8-openjdk"
## but it won't work either if I switch it to
Environment=JAVA_HOME=/usr/lib/jvm/java-8-openjdkLast edited by produnis (2023-05-03 18:26:27)
Offline
Never mind,
I got the problem:
in the airsonic.service-file, there is a hardcoded "/bin/java/"
I changed that to "/usr/lib/jvm/java-8-openjdk/jre/bin/java", and now it works....
Offline
FWIW since airsonic appears abandoned, have you considered airsonic-advanced for a more up to date - and likely also newer JRE compliant - alternative.
Offline