linux - Jenkins 奴隶代理 - Ubuntu : port out range:-1

标签 linux ubuntu jenkins

我正在尝试让 Jenkins 从代理在 VM 中运行。我有 Windows 和 Ubuntu 虚拟机,Windows 一个运行良好。但是,当从代理在 Ubuntu 上启动时出现错误:

启动命令:

java -jar slave.jar -jnlpUrl
https://SERVER/ci/computer/MACHINE/slave-agent.jnlp -secret XXX

错误:
Skipping HTTPS certificate checks altogether. Note that this is not secure at all.
Sep 22, 2017 12:57:58 PM hudson.remoting.jnlp.Main createEngine
INFO: Setting up slave: MACHINE
Sep 22, 2017 12:57:58 PM hudson.remoting.jnlp.Main$CuiListener <init>
INFO: Jenkins agent is running in headless mode.
Sep 22, 2017 12:57:58 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Locating SERVER among [https://SERVER/ci/]
Sep 22, 2017 12:57:59 PM org.jenkinsci.remoting.engine.JnlpAgentEndpointResolver resolve
INFO: Remoting SERVER accepts the following protocols: [JNLP4-connect, JNLP-connect, Ping, JNLP2-connect]
Sep 22, 2017 12:57:59 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Agent discovery successful
  Agent address: SERVER
  Agent port:    51967
  Identity:      XXX
Sep 22, 2017 12:57:59 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Handshaking
Sep 22, 2017 12:57:59 PM hudson.remoting.jnlp.Main$CuiListener status
INFO: Connecting to SERVER:51967
Sep 22, 2017 12:57:59 PM hudson.remoting.jnlp.Main$CuiListener error
SEVERE: port out of range:-1
java.lang.IllegalArgumentException: port out of range:-1
    at java.net.InetSocketAddress.checkPort(InetSocketAddress.java:143)
    at java.net.InetSocketAddress.<init>(InetSocketAddress.java:224)
    at org.jenkinsci.remoting.engine.JnlpAgentEndpointResolver.getResolvedHttpProxyAddress(JnlpAgentEndpointResolver.java:359)
    at org.jenkinsci.remoting.engine.JnlpAgentEndpoint.open(JnlpAgentEndpoint.java:193)
    at hudson.remoting.Engine.connect(Engine.java:500)
    at hudson.remoting.Engine.innerRun(Engine.java:364)
    at hudson.remoting.Engine.run(Engine.java:287)

错误:

严重:端口超出范围:-1
java.lang.IllegalArgumentException:端口超出范围:-1


有任何想法吗?

最佳答案

对我来说也一样,这是由代理设置引起的,我解决了添加 NO_PROXY 环境变量和适当的主机名

关于linux - Jenkins 奴隶代理 - Ubuntu : port out range:-1,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46363301/

相关文章:

linux - 这个错误是什么意思 : interpreter/lib/ld-linux-armhf. so.3error reading (Invalid argument)

linux - bash:python3.3 没有那个文件或目录

python - 在 subprocess.Popen 中使用 && 进行命令链接?

c - 打开不带扩展名的文件

java - 在 Ubuntu 中打开一个 .jar

Maven clean 插件排除 .cvsignore

linux - 查找包含匹配项和提取字段的段落

linux - 安装 linux-headers-2.6.32-042stab085.20

jenkins - 使用 Active Choice Reactive Reference 参数构建项目

security - 如何隐藏向非Jenkins用户泄露的敏感数据