#Stop running Jenkins service using the following command:
sudo su -
systemctl stop jenkins
Linux installations should be upgraded using the same method as was used for the original installation This section will guide you through updating your Jenkins instance to the most recent version.
Ensure you have created a backup.
Verify all running builds are complete.
Ensure that a supported Java version is installed on the controller and all agents. For more information, refer to the upgrade guide.
Stop your Jenkins Instance
#Stop running Jenkins service using the following command:
sudo su -
systemctl stop jenkins
Take Jenkins instance backup as a recovery option
#Take backup of Jenkins home directory. In my case my Jenkins home directory is /var/lib/jenkins.
See the backup instructions for alternatives.
Start The Jenkins Service
#Start the Jenkins service using the following command:
systemctl start jenkins
Update Controller with yum upgrade jenkins
Update Controller with apt-get update && apt-get upgrade jenkins
Update Controller with zypper update jenkins
There are a few post upgrade steps to perform.
The Jenkins server is up and running. Let’s now verify the version from the Jenkins dashboard:
The upgraded Jenkins version can be seen in the bottom right corner of the Jenkins UI.
Jenkins updates its minimum Java requirement every two years. The Java support policy provides more details. Java 17 is also supported as of the 2.361.1 Long Term Support release. Therefore, a best practice is to verify your Java version if you are upgrading from an older version. To upgrade Jenkins from Java 8 to Java 11, refer to the Upgrade Java Guideline and Java requirements.
Plugins are one of the most crucial parts of the Jenkins pipeline. In fact, each job uses a plugin for its execution. Check the available updates for installed plugins:
Go to the Jenkins dashboard.
Select Manage Jenkins in the navigation pane on the left side of the Jenkins dashboard.
Select Manage Plugins.
The above image shows that there is no need to update any plugins.
Sometimes a Jenkins plugin changes the data that it is storing. In other cases, a plugin that has been uninstalled may have left data in the system that Jenkins no longer needs. The "Manage old data" page allows administrators to remove those unused items.
Go to the Jenkins dashboard
Select Manage Jenkins in the navigation pane, on the left side of the Jenkins dashboard.
The above image shows that our new version isn’t compatible with the old version. However, we can fix the problem by selecting the Manage option.
Please submit your feedback about this page through this quick form.
Alternatively, if you don't wish to complete the quick form, you can simply indicate if you found this page helpful?
See existing feedback here.