현재 jenkins
버전을 사용하다가 테스트 삼아서
2.346.2 버전으로 올렸다!
하지만 버그가 있거나 지금 사용하는 환경에 안맞아서 다운그레이드를 해야 하는 상황이다!
하는 방법은
jenkins.war 파일을 변경하자.
jenkins.war 파일 위치를 찾으려면 ps -ef | grep jenkins 해보면 된다.
# ps -ef | grep jenkins
jenkins 3314333 1 5 19:15 ? 00:08:26 /usr/bin/java -Djava.awt.headless=true -Xmx16384m -Xms8192m -XX:MaxPermSize=512m -Dhudson.model.ParametersAction.keepUndefinedParameters=true -Dhudson.security.HudsonPrivateSecurityRealm.ID_REGEX=^[a-zA-Z0-9_.-]+$ -jar /usr/share/java/jenkins.war --webroot=/var/cache/jenkins/war --httpPort=8080
위 경로에 파일이있다.
# cd /usr/share/java/
# mv jenkins.war jenkins.old
위와 같이 파일을 변경하자.
그리고 2.263.4 war 파일을 다운 받자.
# wget https://get.jenkins.io/war-stable/2.263.4/jenkins.war
그리고 jenkins.war 파일을 원래 있던 자리에 복사하자
# service jenkins start
Starting jenkins (via systemctl): Job for jenkins.service failed because a timeout was exceeded.
See "systemctl status jenkins.service" and "journalctl -xe" for details.
[FAILED]
SEVERE hudson.triggers.SafeTimerTask#run: Timer task hudson.model.Queue$MaintainTask@5fba7ed0 failed
하면 정상 작동 되야 하는데 난 실패가 됐다.
다른 방법을 찾아봤다.
https://get.jenkins.io/redhat-stable/
필요한 rpm 버전을 다운 받았다.
기존에 설치 되어 있던 jenkins 를 삭제
# yum remove jenkins
Dependencies resolved.
==============================================================================================================================================================================================================================================================================================
Package Architecture Version Repository Size
==============================================================================================================================================================================================================================================================================================
Removing:
jenkins noarch 2.346.2-1.1 @jenkins 87 M
Transaction Summary
==============================================================================================================================================================================================================================================================================================
Remove 1 Package
Freed space: 87 M
Is this ok [y/N]: y
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Running scriptlet: jenkins-2.346.2-1.1.noarch 1/1
Erasing : jenkins-2.346.2-1.1.noarch 1/1
warning: /etc/sysconfig/jenkins saved as /etc/sysconfig/jenkins.rpmsave
Running scriptlet: jenkins-2.346.2-1.1.noarch 1/1
Verifying : jenkins-2.346.2-1.1.noarch 1/1
Removed:
jenkins-2.346.2-1.1.noarch
Complete!
삭제 완료 하고
rpm 파일 다운 받은 파일을 설치
# yum install jenkins-2.263.4-1.1.noarch.rpm
Last metadata expiration check: 1:01:20 ago on Thu 10 Nov 2022 02:18:15 PM KST.
Dependencies resolved.
==============================================================================================================================================================================================================================================================================================
Package Architecture Version Repository Size
==============================================================================================================================================================================================================================================================================================
Installing:
jenkins noarch 2.263.4-1.1 @commandline 64 M
Transaction Summary
==============================================================================================================================================================================================================================================================================================
Install 1 Package
Total size: 64 M
Installed size: 64 M
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Running scriptlet: jenkins-2.263.4-1.1.noarch 1/1
Installing : jenkins-2.263.4-1.1.noarch 1/1
Running scriptlet: jenkins-2.263.4-1.1.noarch 1/1
Verifying : jenkins-2.263.4-1.1.noarch 1/1
Installed:
jenkins-2.263.4-1.1.noarch
Complete!
그리고 서비스 재시작
# service jenkins restart
Restarting jenkins (via systemctl): [ OK ]
이상 없이 서비스 재시작 된다.
정상적으로 다운그레이드 작업이 완료가 되었다.
혹시 재설치 하면서 jenkins_home 경로가 변경이 될 수 있으니
/etc/sysconfig/jenkins 파일을 수정 해주면 된다.
'Linux' 카테고리의 다른 글
# ./unifdef-bash: ./unifdef: No such file or directory (0) | 2022.11.23 |
---|---|
testdisk 사용법 (1) | 2022.11.21 |
All matches were filtered out by modular filtering for argument: mysql-community-serverError: Unable to find a match: mysql-community-server (0) | 2022.11.13 |
linux root home 파티션 합치기 (0) | 2022.11.07 |
GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-mysql (0) | 2022.11.06 |