Jenkins Version Upgrade

Hi alI.
I have upgraded Jenkins to version 2.426.3 in amazon linux2 and tested out with Open-jdk 11. However after the upgrade, Jenkins service is entering an active (exited) state. Even after upgrading the Java version to open-jdk 17 and open-jdk 21, the issue still persists. Kindly let me if there is any solution for this issue.

probably there is a solution but we don’t know what the problem is as you didn’t provide any details

Amazon Linux 2 is no longer supported by the Jenkins project. It is a Red Hat Enterprise Linux 7 derivative and the systemd implementation on RHEL 7 is problematic and was not supported by the Jenkins systemd implementation even when we supported RHEL 7.

I believe that there are some users that have made things work with the outdated version of systemd on Amazon Linux 2, but you’re battling against an unsupported operating system and an untested version of systemd.

The best solution is to upgrade to a supported operating system like Amazon Linux 2023 (a Fedora derivative), or Red Hat Enterprise Linux 8, or Red Hat Enterprise Linux 9, or one of the Red Hat Enterprise Linux derivatives, like AlmaLinux, Rocky Linux, or Oracle Linux. Other alternatives include Debian and Ubuntu Linux.

Please find the details below:

Initially the version was in 2.31x. I have stopped the Jenkins service. I have replaced the war file in /usr/share/lib with Jenkins version 2.426.3. While starting the Jenkins service, it’s getting into active but exited state. I have upgraded the Java version from 11.0.X to 17.0.X and then again to 21.0.X. But the issue still persists.
Please let me know if any info is required.

I’m sure that when you look at the log of your service it will tell you more.

That’s not the way to perform a Jenkins upgrade if you originally installed with the package manager. If you installed with the yum package manager then you must upgrade with the yum package manager.

Please read the upgrade guide for each version between the version that you had before and the destination version. One of those upgrade guides will tell you about the transition from System V init to systemd.

@mawinter69 is right that more information will be in the log of your service, though I think you’ll have a much better experience if you rollback that machine to the working condition, install a new machine with a supported operating system, and restore the backup of the data files on the new machine.