You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This seems like the simplest possible installation of Jetty and it should "just work". I also tried it with JDK 17.0.1 and same result. The strange thing is when I run it as my own user, not as root, it works fine. Note that adding the setuid module doesn't help. Here it is, running as non-root:
I also tried running it as non-root first and then running it as root, and same result.
To fix it, edit jetty-home-10.0.7/bin/jetty.sh, go to line 468 and remove the quote marks around the $RUN_ARGS[@].
Then it works as root or not, although I don't think this is really the correct bash-way to fix it.
This was really a painful thing to debug, why it was all working when I ran it with jetty.sh supervise but not with jetty.sh start, and therefore why my systemd unit was failing.
I'm not really sure why the start-stop-daemon handling of spaces in parameters is different between root user and non-root user but somehow it seems that it is. I've tried this on two different ubuntu 20.04 machines so far.
The text was updated successfully, but these errors were encountered:
Thanks Joakime. I simply replaced my jetty.sh file with https://raw.githubusercontent.com/eclipse/jetty.project/jetty-10.0.x/jetty-home/src/main/resources/bin/jetty.sh and it all worked. This was really a confusing situation but it seems to work now.
@chiralsoftware we are starting the process of the next Jetty 9/10/11 releases. Expect a new Jetty 10 release with this fix in it before the end of the month.
Jetty version(s)
Java 17
Java version/vendor
(use: java -version)
openjdk version "17" 2021-09-14
OpenJDK Runtime Environment (build 17+35-2724)
OpenJDK 64-Bit Server VM (build 17+35-2724, mixed mode, sharing)
OS type/version
Ubuntu 20.04.3 LTS
Description
Jetty does not run when started using
jetty.sh
when that is run as root.How to reproduce?
This seems like the simplest possible installation of Jetty and it should "just work". I also tried it with JDK 17.0.1 and same result. The strange thing is when I run it as my own user, not as root, it works fine. Note that adding the setuid module doesn't help. Here it is, running as non-root:
I also tried running it as non-root first and then running it as root, and same result.
To fix it, edit
jetty-home-10.0.7/bin/jetty.sh
, go to line 468 and remove the quote marks around the$RUN_ARGS[@]
.Then it works as root or not, although I don't think this is really the correct bash-way to fix it.
This was really a painful thing to debug, why it was all working when I ran it with
jetty.sh supervise
but not withjetty.sh start
, and therefore why my systemd unit was failing.I'm not really sure why the
start-stop-daemon
handling of spaces in parameters is different between root user and non-root user but somehow it seems that it is. I've tried this on two different ubuntu 20.04 machines so far.The text was updated successfully, but these errors were encountered: