Hi All,
I tried to upgrade the SSH-Slave plugin to latest version to connect the master node with the worker node. When I clicked on restart Jenkins after the installation, the Jenkins stopped but did not start from the web. I went into terminal to start jenkins by ‘sudo systemctl start jenkins’ and Access Denied error came.
After that I took a backup of the Jenkins and tried to install the new Jenkins version for my redhat server. I followed the guide (Linux & Redhat Jenkins Packages) to install Jenkins. I tried installing multiple java versions, but journalctl -xe throwed error jenkins: invalid Java version:openjdk version “11” .
Some how the above invalid java error is now gone as I installed the java version from the organization provider and tried to install the Jenkins again.
Currently below error are coming -
[root@bnzcicd01 lib]# sudo systemctl status jenkins
● jenkins.service - Jenkins Continuous Integration Server
Loaded: loaded (/usr/lib/systemd/system/jenkins.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Wed 2023-06-28 18:15:01 CST; 10s ago
Process: 2149530 ExecStart=/usr/bin/jenkins (code=exited, status=1/FAILURE)
Main PID: 2149530 (code=exited, status=1/FAILURE)
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Main process exited, code=exited, status=1/FAILURE
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Failed with result ‘exit-code’.
Jun 28 18:15:01 testserver systemd[1]: Failed to start Jenkins Continuous Integration Server.
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Service RestartSec=100ms expired, scheduling restart.
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Scheduled restart job, restart counter is at 5.
Jun 28 18:15:01 testserver systemd[1]: Stopped Jenkins Continuous Integration Server.
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Start request repeated too quickly.
Jun 28 18:15:01 testserver systemd[1]: jenkins.service: Failed with result ‘exit-code’.
Jun 28 18:15:01 testserver systemd[1]: Failed to start Jenkins Continuous Integration Server.
journalctl -xe
– Subject: Unit failed
– Defined-By: systemd
– The unit jenkins.service has entered the ‘failed’ state with result ‘exit-code’.
Jun 28 18:15:01 testserver systemd[1]: Failed to start Jenkins Continuous Integration Server.
– Subject: Unit jenkins.service has failed
– Defined-By: systemd
– Unit jenkins.service has failed.
– The result is failed.
Jun 28 18:15:11 testserver sudo[2149557]: root : TTY=pts/2 ; PWD=/var/lib ; USER=root ; COMMAND=/bin/systemctl status jenkins
Jun 28 18:15:11 testserver sudo[2149557]: pam_systemd(sudo:session): Cannot create session: Already running in a session or user slice
Jun 28 18:15:11 testserver sudo[2149557]: pam_unix(sudo:session): session opened for user root by root(uid=0)
Jun 28 18:15:11 testserver sudo[2149557]: pam_unix(sudo:session): session closed for user root
Jun 28 18:15:21 testserver sshd[2149569]: Accepted password for root from 9.125.75.30 port 57558 ssh2
Jun 28 18:15:21 testserver systemd[1]: Started Session 186 of user root.
– Subject: Unit session-186.scope has finished start-up
– Defined-By: systemd
– Unit session-186.scope has finished starting up.
– The start-up result is done.
Jun 28 18:15:21 testserver systemd-logind[1169]: New session 186 of user root.
– Subject: A new session 186 has been created for user root
– Defined-By: systemd
– A new session with the ID 186 has been created for the user root.
– The leading process of the session is 2149569.
Jun 28 18:15:21 testserver sshd[2149569]: pam_unix(sshd:session): session opened for user root by (uid=0)
Jun 28 18:15:22 testserver sshd[2149574]: Received disconnect from 9.125.75.30 port 57558:11: disconnected by user
Jun 28 18:15:22 testserver sshd[2149574]: Disconnected from user root 9.125.75.30 port 57558
Jun 28 18:15:22 testserver sshd[2149569]: pam_unix(sshd:session): session closed for user root
Jun 28 18:15:22 testserver systemd[1]: session-186.scope: Succeeded.
– Subject: Unit succeeded
– Defined-By: systemd
– The unit session-186.scope has successfully entered the ‘dead’ state.
Jun 28 18:15:22 testserver systemd-logind[1169]: Session 186 logged out. Waiting for processes to exit.
Jun 28 18:15:22 testserver systemd-logind[1169]: Removed session 186.
– Subject: Session 186 has been terminated
– Defined-By: systemd
– A session with the ID 186 has been terminated.
[root@bnzcicd01 lib]# systemctl restart jenkins
Job for jenkins.service failed because the control process exited with error code.
See “systemctl status jenkins.service” and “journalctl -xe” for details.
[root@bnzcicd01 lib]# java -version
java version “11.0.19” 2023-04-18
IBM Semeru Runtime Certified Edition 11.0.19.0 (build 11.0.19+7)
Eclipse OpenJ9 VM 11.0.19.0 (build openj9-0.38.0, JRE 11 Linux amd64-64-Bit Compressed References 20230519_626 (JIT enabled, AOT enabled)
OpenJ9 - d57d05932
OMR - 855813495
JCL - 61e8703a10 based on jdk-11.0.19+7)
Please look into the logs and let me know if anyone have the solution