Installed java-11-openjdk-11.0.19.0.7-1.el7_9.x86_64 with “sudo yum install fontconfig java-11-openjdk”;
Installed jenkins 2.387.3-1.1, set up JAVA_HOME,3. failed to start,
no log found.
error mesage as:
:/usr/lib/jenkins>sudo systemctl enable jenkins
Created symlink from /etc/systemd/system/multi-user.target.wants/jenkins.service to /usr/lib/systemd/system/jenkins.service.
/home/oraamp>sudo service jenkins start
Starting jenkins (via systemctl): Job for jenkins.service failed because the control process exited with error code. See “systemctl status jenkins.service” and “journalctl -xe” for details.
Thank you for the reply.
when check error message:
:/var/log>systemctl status jenkins.service
● jenkins.service - Jenkins Continuous Integration Server
Loaded: loaded (/usr/lib/systemd/system/jenkins.service; enabled; vendor preset: disabled)
Active: failed (Result: start-limit) since Fri 2023-05-12 14:26:07 PDT; 1h 21min ago
Process: 19077 ExecStart=/usr/bin/jenkins (code=exited, status=1/FAILURE)
Main PID: 19077 (code=exited, status=1/FAILURE)
May 12 14:26:06 mcdasatest07 systemd[1]: jenkins.service: main process exited, code=exited, status=1/FAILURE
May 12 14:26:06 mcdasatest07 systemd[1]: Failed to start Jenkins Continuous Integration Server.
May 12 14:26:06 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 12 14:26:06 mcdasatest07 systemd[1]: jenkins.service failed.
May 12 14:26:07 mcdasatest07 systemd[1]: jenkins.service holdoff time over, scheduling restart.
May 12 14:26:07 mcdasatest07 systemd[1]: Stopped Jenkins Continuous Integration Server.
May 12 14:26:07 mcdasatest07 systemd[1]: start request repeated too quickly for jenkins.service
May 12 14:26:07 mcdasatest07 systemd[1]: Failed to start Jenkins Continuous Integration Server.
May 12 14:26:07 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 12 14:26:07 mcdasatest07 systemd[1]: jenkins.service failed.
when run: journalctl -xe
Unit redcloak.service has begun starting up.
May 12 15:41:17 mcdasatest07 systemd[1]: redcloak.service: control process exited, code=exited status=127
May 12 15:41:17 mcdasatest07 sh[16705]: /bin/sh: /opt/secureworks/redcloak/bin/redcloak_start.sh: No such file or directory
May 12 15:41:17 mcdasatest07 systemd[1]: Failed to start Redcloak Security monitoring service.
– Subject: Unit redcloak.service has failed
Hmmm, that didn’t help much at all. Do you have another Java installed on the machine already that might be set as the default? Can you look at the overrides file using the commands detailed here (Managing systemd services) to see if the path to Java is being overridden to a Java 8 install?
Thanks slide_o_mix and halkeye.
Went through the document, didn’t see override.conf file is stored at /etc/systemd/system/jenkins.service.d/override.conf, but found /etc/systemd/system/jenkins.service.
Can I edit and add changes to jenkins.service?
[Unit]
Description=My Company Jenkins Controller
[Service]
# Add JVM configuration options
Environment="JAVA_OPTS=-Djava.awt.headless=true -XX:+UseStringDeduplication"
# Arbitrary additional arguments to pass to Jenkins.
# Full option list: java -jar jenkins.war --help
Environment="JENKINS_OPTS=--prefix=/jenkins --JAVA_HOME=/usr/lib/jvm/java-11-openjdk-11.0.19.0.7-1.el7_9.x86_64"
# Configuration as code directory
Environment="CASC_JENKINS_CONFIG=/var/lib/jenkins/configuration-as-code/"
In my case, JAVA_HOME=/usr/lib/jvm/java-11-openjdk-11.0.19.0.7-1.el7_9.x86_64
mcdasatest07:/home/oraamp>java -version
openjdk version "11.0.19" 2023-04-18 LTS
OpenJDK Runtime Environment (Red_Hat-11.0.19.0.7-1.el7_9) (build 11.0.19+7-LTS)
OpenJDK 64-Bit Server VM (Red_Hat-11.0.19.0.7-1.el7_9) (build 11.0.19+7-LTS, mixed mode, sharing)
Made change in jenkins.service, same fail:
:/usr/lib/systemd/system>sudo service jenkins start
Starting jenkins (via systemctl): Job for jenkins.service failed because the control process exited with error code. See “systemctl status jenkins.service” and “journalctl -xe” for details.
[FAILED]
:/usr/lib/systemd/system>systemctl status jenkins.service
● jenkins.service - My Company Jenkins Controller
Loaded: loaded (/usr/lib/systemd/system/jenkins.service; enabled; vendor preset: disabled)
Active: failed (Result: start-limit) since Tue 2023-05-16 13:12:06 PDT; 16s ago
Process: 27540 ExecStart=/usr/bin/jenkins (code=exited, status=1/FAILURE)
Main PID: 27540 (code=exited, status=1/FAILURE)
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service failed.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service holdoff time over, scheduling restart.
May 16 13:12:06 mcdasatest07 systemd[1]: Stopped My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: start request repeated too quickly for jenkins.service
May 16 13:12:06 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service failed.
:/usr/lib/systemd/system>journalctl -xe
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service: main process exited, code=exited, status=1/FAILURE
May 16 13:12:05 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
– Subject: Unit jenkins.service has failed
– Defined-By: systemd
– Support: systemd-devel Info Page
– Unit jenkins.service has failed.
– The result is failed.
May 16 13:12:05 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service failed.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service holdoff time over, scheduling restart.
May 16 13:12:06 mcdasatest07 systemd[1]: Stopped My Company Jenkins Controller.
– Subject: Unit jenkins.service has finished shutting down
– Defined-By: systemd
– Support: systemd-devel Info Page
– Unit jenkins.service has finished shutting down.
May 16 13:12:06 mcdasatest07 systemd[1]: start request repeated too quickly for jenkins.service
May 16 13:12:06 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
– Subject: Unit jenkins.service has failed
– Defined-By: systemd
– Support: systemd-devel Info Page
– Unit jenkins.service has failed.
– The result is failed.
May 16 13:12:06 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service failed.
May 16 13:12:50 mcdasatest07 goferd[1479]: [INFO][worker-0] gofer.messaging.adapter.connect:28 - connecting: proton+amqps://subs
May 16 13:12:50 mcdasatest07 goferd[1479]: [INFO][worker-0] gofer.messaging.adapter.proton.connection:87 - open: URL: amqps://su
May 16 13:12:50 mcdasatest07 goferd[1479]: [ERROR][worker-0] gofer.messaging.adapter.connect:33 - connect: proton+amqps://subscr
May 16 13:12:50 mcdasatest07 goferd[1479]: [INFO][worker-0] gofer.messaging.adapter.connect:35 - retry in 106 seconds
May 16 13:12:56 mcdasatest07 systemd[1]: redcloak.service holdoff time over, scheduling restart.
May 16 13:12:56 mcdasatest07 systemd[1]: Stopped Redcloak Security monitoring service.
– Subject: Unit redcloak.service has finished shutting down
– Defined-By: systemd
– Support: systemd-devel Info Page
– Unit redcloak.service has finished shutting down.
I would recommend doing journalctl -u jenkins.service -e -n 100 to get the last 100 lines (-e) and goto the end of the log (e) of the jenkins service (-u) since you have lots of other noise in what you posted.
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.Net.bind(Net.java:448)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:227)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:339)
May 16 13:12:05 mcdasatest07 jenkins[27540]: … 21 more
May 16 13:12:05 mcdasatest07 jenkins[27540]: 2023-05-16 20:12:05.881+0000 [id=1] SEVERE winstone.Logger#logInternal: Container startup fa
May 16 13:12:05 mcdasatest07 jenkins[27540]: java.net.BindException: Address already in use
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.Net.bind0(Native Method)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.Net.bind(Net.java:459)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.Net.bind(Net.java:448)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:227)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:339)
May 16 13:12:05 mcdasatest07 jenkins[27540]: Caused: java.io.IOException: Failed to bind to 0.0.0.0/0.0.0.0:8080
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.ServerConnector.openAcceptChannel(ServerConnector.java:344)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.ServerConnector.open(ServerConnector.java:304)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.Server.lambda$doStart$0(Server.java:402)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:497)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.server.Server.doStart(Server.java:398)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:93)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at winstone.Launcher.(Launcher.java:168)
May 16 13:12:05 mcdasatest07 jenkins[27540]: Caused: java.io.IOException: Failed to start Jetty
May 16 13:12:05 mcdasatest07 jenkins[27540]: at winstone.Launcher.(Launcher.java:172)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at winstone.Launcher.main(Launcher.java:390)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43
May 16 13:12:05 mcdasatest07 jenkins[27540]: at java.base/java.lang.reflect.Method.invoke(Method.java:566)
May 16 13:12:05 mcdasatest07 jenkins[27540]: at executable.Main.main(Main.java:347)
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service: main process exited, code=exited, status=1/FAILURE
May 16 13:12:05 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
May 16 13:12:05 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service failed.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service holdoff time over, scheduling restart.
May 16 13:12:06 mcdasatest07 systemd[1]: Stopped My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: start request repeated too quickly for jenkins.service
May 16 13:12:06 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service failed.
:/usr/lib/systemd/system>systemctl status jenkins.service
● jenkins.service - My Company Jenkins Controller
Loaded: loaded (/usr/lib/systemd/system/jenkins.service; enabled; vendor preset: disabled)
Active: failed (Result: start-limit) since Tue 2023-05-16 13:12:06 PDT; 16s ago
Process: 27540 ExecStart=/usr/bin/jenkins (code=exited, status=1/FAILURE)
Main PID: 27540 (code=exited, status=1/FAILURE)
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service failed.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service holdoff time over, scheduling restart.
May 16 13:12:06 mcdasatest07 systemd[1]: Stopped My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: start request repeated too quickly for jenkins.service
May 16 13:12:06 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
May 16 13:12:06 mcdasatest07 systemd[1]: Unit jenkins.service entered failed state.
May 16 13:12:06 mcdasatest07 systemd[1]: jenkins.service failed.
:/usr/lib/systemd/system>journalctl -xe
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service: main process exited, code=exited, status=1/FAILURE
May 16 13:12:05 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
:/usr/lib/systemd/system>journalctl -xe
May 16 13:12:05 mcdasatest07 systemd[1]: jenkins.service: main process exited, code=exited, status=1/FAILURE
May 16 13:12:05 mcdasatest07 systemd[1]: Failed to start My Company Jenkins Controller.
– Subject: Unit jenkins.service has failed
– Defined-By: systemd
– Support:
– Unit jenkins.service has failed.
May 16 13:12:57 mcdasatest07 systemd[1]: Unit redcloak.service entered failed state.
May 16 13:12:57 mcdasatest07 systemd[1]: redcloak.service failed.
lines 1215-1272/1272 (END)
:/usr/lib/systemd/system>cd /opt/secureworks/redcloak/bin/
bash: cd: /opt/secureworks/redcloak/bin/: No such file or directory