gpt4 book ai didi

jenkins - 无法通过jenkins连接到AWS从站

转载 作者:行者123 更新时间:2023-12-04 12:20:24 25 4
gpt4 key购买 nike

我正在尝试使用jenkins中的EC2插件配置主从配置。配置完EC2插件后,jenkins成功启动了从站,我什至可以通过SSH进入该从站。但是,当我查看jenkins中的Node日志时,我发现jenkins无法连接到slave。这是我所看到的:

This node is offline because Jenkins failed to launch the slave agent   on it. See log for more details
INFO: Authenticating as ubuntu
Jan 31, 2017 6:29:00 PM null
INFO: Connecting to ip-10-226-254-52.ec2.internal on port 22, with timeout 10000.
Jan 31, 2017 6:29:10 PM null
INFO: Failed to connect via ssh: The kexTimeout (10000 ms) expired.
Jan 31, 2017 6:29:10 PM null
INFO: Waiting for SSH to come up. Sleeping 5.
Jan 31, 2017 6:29:15 PM null
INFO: Connecting to ip-10-226-254-52.ec2.internal on port 22, with timeout 10000.
Jan 31, 2017 6:29:25 PM null
INFO: Failed to connect via ssh: The kexTimeout (10000 ms) expired.
Jan 31, 2017 6:29:25 PM null
INFO: Waiting for SSH to come up. Sleeping 5.
ERROR: Unexpected error in launching a slave. This is probably a bug in Jenkins
java.lang.NullPointerException
at hudson.plugins.ec2.ssh.EC2UnixLauncher.bootstrap(EC2UnixLauncher.java:309)
at hudson.plugins.ec2.ssh.EC2UnixLauncher.launch(EC2UnixLauncher.java:131)
at hudson.plugins.ec2.EC2ComputerLauncher.launch(EC2ComputerLauncher.java:122)
at hudson.slaves.SlaveComputer$1.call(SlaveComputer.java:253)
at jenkins.util.ContextResettingExecutorService$2.call(ContextResettingExecutorService.java:46)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)


我在网上检查了一下,但无济于事。如果您熟悉这种错误,请帮助我。提前致谢。

最佳答案

我想我已经弄清楚了。我指定供从属使用的安全组没有SSH端口(22),但没有在主控的安全组上打开。打开SSH端口后,我可以连接到从节点
注意:我对主服务器和从服务器使用相同的安全组

INFO: Connected via SSH.
Feb 02, 2017 4:29:59 PM null
INFO: connect fresh as root

关于jenkins - 无法通过jenkins连接到AWS从站,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41965115/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com