2024-10-10 08:11 AM
After upgrading to version 12.5 jetty was in dead status and fail to start,
As upgrade/maintenance guide mentioned to configure jetty as below
To add custom jetty configuration
1. From SSH prompt, create a copy of jetty configuration as jetty.user using the below command.
$ cp /etc/default/jetty /etc/default/jetty.user
2. Edit the /etc/default/jetty.user and remove all lines EXCEPT one of the JAVA_OPTIONS
additional settings lines.
For example, JAVA_OPTIONS="${JAVA_OPTIONS} -Drsa.primary.host=true "
3. Edit the line with the option (in this example increasing the max memory option from 8G to 24G):
JAVA_OPTIONS="${JAVA_OPTIONS} -Xmx24G "
4. Make sure to use the JAVA_OPTIONS="${JAVA_OPTIONS} " format to EXTEND the JAVA
OPTIONS.
System Maintenance Guide
5. REMOVE the [ -f /etc/default/jetty.user ] && source /etc/default/jetty.user
file.
6. Save the file.
7. Restart the jetty service.
systemctl restart jetty
Already did it but it fail to start
2024-10-10 11:30 AM
Forget the instruction for the /etc/default/jetty.user file, it can only cause issues if anything is not right
clear the jetty.user and add JUST this line to it:
JAVA_OPTIONS=`echo "${JAVA_OPTIONS}" | sed -E 's/Xms[0-9]+G/Xms16G/' | sed -E 's/Xmx[0-9]+G/Xmx24G/'`
That will change the min to 16G and max to 24G without causing any issues with the other options in the jetty file.
2024-10-14 04:41 AM
Still Fail to start jetty
Job for jetty.service failed because the control process exited with error code.
See "systemctl status jetty.service" and "journalctl -xe" for details.
Journalctl -xe results
Oct 14 11:14:20 NW-ADM nw-jetty-wrapper.sh[478330]: Usage: java -jar $JETTY_HOME/start.jar [options] [properties] [configs]
Oct 14 11:14:20 NW-ADM nw-jetty-wrapper.sh[478330]: java -jar $JETTY_HOME/start.jar --help # for more information
Oct 14 11:14:22 NW-ADM nw-jetty-wrapper.sh[478303]: FAILED Mon Oct 14 11:14:22 UTC 2024
Oct 14 11:14:22 NW-ADM systemd[1]: jetty.service: Control process exited, code=exited status=1
Oct 14 11:14:22 NW-ADM systemd[1]: jetty.service: Failed with result 'exit-code'.
-- Subject: Unit failed
-- Defined-By: systemd
-- Support: https://access.redhat.com/support
--
-- The unit jetty.service has entered the 'failed' state with result 'exit-code'.
Oct 14 11:14:22 NW-ADM systemd[1]: Failed to start Jetty Web Server.
-- Subject: Unit jetty.service has failed
-- Defined-By: systemd
-- Support: https://access.redhat.com/support
--
-- Unit jetty.service has failed.
--
-- The result is failed.