美文网首页
Jenkins报错

Jenkins报错

作者: 熊本猫 | 来源:发表于2018-08-20 11:53 被阅读0次

Jenkins配置linux节点报错

[08/20/18 11:29:29] [SSH] Starting sftp client.
[08/20/18 11:29:29] [SSH] 正在拷贝最新版本的 slave.jar...
[08/20/18 11:29:30] [SSH] Copied 771,004 bytes.
Expanded the channel window size to 4MB
[08/20/18 11:29:30] [SSH] Starting slave process: cd " /home/system1/jenkins21" && /usr/lib/jvm/java-7-openjdk-amd64/ -jar slave.jar
bash: /usr/lib/jvm/java-7-openjdk-amd64/: Is a directory
Slave JVM has terminated. Exit code=126
[08/20/18 11:29:30] Launch failed - cleaning up connection
[08/20/18 11:29:30] [SSH] 连接关闭。

修改节点配置中的JAVA配置为1.8版本就可以了


image.png

Jenkins任务编译报错1

FATAL: Remote call on Ubu_10.250.115.100 failed
Also: hudson.remoting.ChannelCallSiteStackTrace: Remote call to Ubu_10.250.115.100 at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1741) at hudson.remoting.UserRequestExceptionResponse.retrieve(UserRequest.java:357)
at hudson.remoting.Channel.call(Channel.java:955)
at hudson.LauncherRemoteLauncher.kill(Launcher.java:1078) at hudson.model.AbstractBuildAbstractBuildExecution.run(AbstractBuild.java:510)
at hudson.model.Run.execute(Run.java:1798)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:429)
java.lang.NoClassDefFoundError: Could not initialize class hudson.slaves.SlaveComputer
at hudson.util.ProcessTree.get(ProcessTree.java:399)
at hudson.LauncherRemoteLauncherKillTask.call(Launcher.java:1090)
at hudson.LauncherRemoteLauncherKillTask.call(Launcher.java:1081)
at hudson.remoting.UserRequest.perform(UserRequest.java:212)
at hudson.remoting.UserRequest.perform(UserRequest.java:54)
at hudson.remoting.Request2.run(Request.java:369) at hudson.remoting.InterceptingExecutorService1.call(InterceptingExecutorService.java:72)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutorWorker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused: java.io.IOException: Remote call on Ubu_10.250.115.100 failed at hudson.remoting.Channel.call(Channel.java:961) at hudson.LauncherRemoteLauncher.kill(Launcher.java:1078)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:510)
at hudson.model.Run.execute(Run.java:1798)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:97)
at hudson.model.Executor.run(Executor.java:429)

原因和解决办法

原本在系统设置-全局环境变量-JDK中填写了windows的jdk路径,这样导致了jenkins找不到java环境,去掉这个jdk配置后,重启jenkins就好了

相关文章

网友评论

      本文标题:Jenkins报错

      本文链接:https://www.haomeiwen.com/subject/gubkiftx.html