I’m currently running Jenkins version 2.356 (Java 1.8) on RHEL 7. I did an yum update, it accidently updated Jenkins to 2.375. I wanted to downgrade it, so I copied the v2.356 war file under the folder where it supposed to be. I was not able to start the Jenkins service. It throws jenkins.service failed because the control process exited with error code.
I ran journalctl -xe command. It shows invalid Java version.
Because Jenkins requires Java 11 or above since Jenkins 2.357. I don’t want to upgrade Jenkins/Java versions.
How do I properly downgrade back to v2.356?
Am I missing something? Why would you manually install a war file instead of downgrading the yum package?
Thats what I would recommend doing.
I would also recommend taking the time to upgrade jenkins so you can continue to get security fixes. The version of java you are running jenkins with doesn’t have to be the same version doing your builds.
If I downgrade yum package (download the rpm & yum downgrade jenkins2356), will it change/replace any config files? I don’t want to upgrade Jenkins for many reasons. Thanks.
I don’t think so, but I don’t use the packages at all. I recommend using yum to see what files it replaces, and if it replaces anything you care about - https://www.cyberciti.biz/faq/rhel-centos-fedora-list-contents-of-package-using-yum-command/
can you clarify if possible please provide some commands.
See instructions at
Thanks for your response. I download version 2.356 rpm and ran the following command.
sudo yum downgrade jenkins-2.356-1.1.noarch.rpm
It throws publick key for jenkins-2.356-1.1.noarch.rpm is not installed.
Should I run command first?
sudo rpm --import https://pkg.jenkins.io/redhat-stable/jenkins.io.key
I believe that you are only allowed to downgrade to a version that was previously installed. I suspect that you had not previously installed Jenkins 2.356. You’ll need to downgrade to a version that was previously installed, then upgrade to 2.356 if that is the final destination.
No, I’m sure that was the version 2.356. I was using the latest release that works on JDK 1.8
Because, the next version 2.357 needs JDK 11 or above. The config.xml currently shows 2.356
https://get.jenkins.io/redhat/jenkins-2.356-1.1.noarch.rpm
Finally, I added --nogpgcheck and was able to downgrade.