First you need to find where your jenkins.war file is installed:
locate jenkins.war
On my Centos machine, this is here: /usr/share/jenkins/jenkins.war
Stop the Jenkins service:
service jenkins stop
Then you can back up the existing jenkins.war file:
cd /usr/share/jenkins
mv jenkins.war jenkins-1.586.war
And to finish, copy the new jenkins.war file in the same place:
cp jenkins.war /usr/share/jenkins/jenkins.war
Restart the Jenkins service:
service jenkins start
It should work, and you should get the Jenkins configuration (which is stored in the Jenkins home folder).
source
share