Linux教程

记录Jenkins升级到最新版遇到的问题

本文主要是介绍记录Jenkins升级到最新版遇到的问题,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

首先吐槽一下Jenkins:

1、安装插件的时候无法根据Jenkins的版本号安装对应的插件!

2、安装插件安装版本不一致的时候无法降低插件版本!

3、为啥要我们升级到最新版!

 

一、升级原因

我的Jenkins提示一堆插件不符合版本要求,无法使用,去插件网站下载低版本的插件发现也是无法解决,最后迫不得已只能升级Jenkins。垃圾Jenkins!

 

二、说明

因为我是通过yum安装的Jenkins,没升级之前 使用systemctl start jenkins 都没问题。

Jenkins 从2.300 升级到最新版2.340,使用systemctl start jenkins 一直卡住,但是在另外的终端查看是有Jenkins进程启动的,只是和原来的进程不一样。

正常的情况下之后下面红框的进程,明显是多了两个进程:

systemctl start jenkins 卡了很久之后,然后下面报错:

Mar 25 15:50:54 gogslfs.leniu.com polkitd[599]: Registered Authentication Agent for unix-process:17645:1020038543 (system bus name :1.
Mar 25 15:50:54 gogslfs.leniu.com systemd[1]: Stopping LSB: Jenkins Automation Server...
-- Subject: Unit jenkins.service has begun shutting down
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit jenkins.service has begun shutting down.
Mar 25 15:50:55 gogslfs.leniu.com jenkins[17651]: Shutting down Jenkins [  OK  ]
Mar 25 15:50:55 gogslfs.leniu.com systemd[1]: Stopped LSB: Jenkins Automation Server.
-- Subject: Unit jenkins.service has finished shutting down
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit jenkins.service has finished shutting down.
Mar 25 15:50:55 gogslfs.leniu.com polkitd[599]: Unregistered Authentication Agent for unix-process:17645:1020038543 (system bus name :
Mar 25 15:51:19 gogslfs.leniu.com polkitd[599]: Registered Authentication Agent for unix-process:17671:1020041100 (system bus name :1.
Mar 25 15:51:19 gogslfs.leniu.com systemd[1]: Starting LSB: Jenkins Automation Server...
-- Subject: Unit jenkins.service has begun start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit jenkins.service has begun starting up.
Mar 25 15:51:19 gogslfs.leniu.com runuser[17678]: pam_unix(runuser:session): session opened for user root by (uid=0)
Mar 25 15:51:24 gogslfs.leniu.com jenkins[17677]: Starting Jenkins WARNING: An illegal reflective access operation has occurred
Mar 25 15:51:24 gogslfs.leniu.com jenkins[17677]: WARNING: Illegal reflective access by org.codehaus.groovy.vmplugin.v7.Java7$1 (file:
Mar 25 15:51:24 gogslfs.leniu.com jenkins[17677]: WARNING: Please consider reporting this to the maintainers of org.codehaus.groovy.vm
Mar 25 15:51:24 gogslfs.leniu.com jenkins[17677]: WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective 
Mar 25 15:51:24 gogslfs.leniu.com jenkins[17677]: WARNING: All illegal access operations will be denied in a future release
Mar 25 15:56:19 gogslfs.leniu.com systemd[1]: jenkins.service start operation timed out. Terminating.
Mar 25 15:56:19 gogslfs.leniu.com systemd[1]: Failed to start LSB: Jenkins Automation Server.
-- Subject: Unit jenkins.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
-- 
-- Unit jenkins.service has failed.
-- 
-- The result is failed.
Mar 25 15:56:19 gogslfs.leniu.com systemd[1]: Unit jenkins.service entered failed state.
Mar 25 15:56:19 gogslfs.leniu.com systemd[1]: jenkins.service failed.
Mar 25 15:56:19 gogslfs.leniu.com polkitd[599]: Unregistered Authentication Agent for unix-process:17671:1020041100 (system bus na

 

 

但是是不影响Jenkins使用,也没有相关的日志报错。

而且kill掉上面三个进程之后,如果使用systemctl start jenkins 启动发现,发现没有卡住,也没有日志输出。而且是一下子就执行完了,但是实际上Jenkins没有启动。

解决方法:使用restart来启动(很狗)具体原因未知!!!!但是Jenkins能正常使用。

systemctl restart jenkins

这篇关于记录Jenkins升级到最新版遇到的问题的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!