Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Different jenkins master URL" doesn't work #237

Closed
janisBerz opened this issue Jun 20, 2018 · 2 comments
Closed

"Different jenkins master URL" doesn't work #237

janisBerz opened this issue Jun 20, 2018 · 2 comments

Comments

@janisBerz
Copy link

I have set "Different jenkins master URL" to bypass or proxy but once the container starts it uses "Jenkins URL" as Jenkins server URL.

Environment:
Jenkins 2.89
Yet another Docker plug-in 0.1.0-rc47

Windows container log:
###################################
JENKINS_URL = https://no-proxy.com
JENKINS_USER =
JENKINS_HOME = c:\jenkins
COMPUTER_URL = computer/VH-WinDockerHost-2e30e1cf5b58/
COMPUTER_SECRET = xxx
NO_CERTIFICATE_CHECK = true
JAVA_OPTS =
SLAVE_OPTS =
###################################
Invoke-WebRequest -Uri https://no-proxy.com/jnlpJars/slave.jar -Outfile c:\jenkins/slave.jar
java -jar c:\jenkins/slave.jar -noReconnect -noCertificateCheck -jnlpUrl https://no-proxy.com/computer/VH-WinDockerHost-2e30e1cf5b58//slave-agent.jnlp -secret xxx
Skipping HTTPS certificate checks altogether. Note that this is not secure at all.
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main createEngine
INFO: Setting up slave: VH-WinDockerHost-2e30e1cf5b58
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener
INFO: Jenkins agent is running in headless mode.
Jun 20, 2018 9:33:23 AM hudson.remoting.Engine startEngine
WARNING: No Working Directory. Using the legacy JAR Cache location: C:\Users\ContainerAdministrator.jenkins\cache\jars
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Locating server among [https://proxy.com/, https://no-proxy.com/]
Jun 20, 2018 9:33:23 AM org.jenkinsci.remoting.engine.JnlpAgentEndpointResolver resolve
INFO: Remoting server accepts the following protocols: [JNLP4-connect, Ping]
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Agent discovery successful
Agent address: proxy.com
Agent port: 3698
Identity: xxx
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Handshaking
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Connecting to proxy.com:3698
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Trying protocol: JNLP4-connect
Jun 20, 2018 9:33:23 AM org.jenkinsci.remoting.protocol.impl.AckFilterLayer abort
WARNING: [JNLP4-connect connection to proxy.com/172.16.0.6:3698] Incorrect acknowledgement sequence, expected 0x000341434b got 0x485454502f
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Protocol JNLP4-connect encountered an unexpected exception
java.util.concurrent.ExecutionException: org.jenkinsci.remoting.protocol.impl.ConnectionRefusalException: Connection closed before acknowledgement sent
at org.jenkinsci.remoting.util.SettableFuture.get(SettableFuture.java:223)
at hudson.remoting.Engine.innerRun(Engine.java:594)
at hudson.remoting.Engine.run(Engine.java:455)
Caused by: org.jenkinsci.remoting.protocol.impl.ConnectionRefusalException: Connection closed before acknowledgement sent
at org.jenkinsci.remoting.protocol.impl.AckFilterLayer.onRecvClosed(AckFilterLayer.java:280)
at org.jenkinsci.remoting.protocol.FilterLayer.abort(FilterLayer.java:164)
at org.jenkinsci.remoting.protocol.impl.AckFilterLayer.abort(AckFilterLayer.java:130)
at org.jenkinsci.remoting.protocol.impl.AckFilterLayer.onRecv(AckFilterLayer.java:258)
at org.jenkinsci.remoting.protocol.ProtocolStack$Ptr.onRecv(ProtocolStack.java:669)
at org.jenkinsci.remoting.protocol.NetworkLayer.onRead(NetworkLayer.java:136)
at org.jenkinsci.remoting.protocol.impl.BIONetworkLayer.access$2200(BIONetworkLayer.java:48)
at org.jenkinsci.remoting.protocol.impl.BIONetworkLayer$Reader.run(BIONetworkLayer.java:283)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at hudson.remoting.Engine$1$1.run(Engine.java:98)
at java.lang.Thread.run(Unknown Source)

Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Connecting to proxy.com:3698
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Server reports protocol JNLP4-plaintext not supported, skipping
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Server reports protocol JNLP3-connect not supported, skipping
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Server reports protocol JNLP2-connect not supported, skipping
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener status
INFO: Server reports protocol JNLP-connect not supported, skipping
Jun 20, 2018 9:33:23 AM hudson.remoting.jnlp.Main$CuiListener error
SEVERE: The server rejected the connection: None of the protocols were accepted
java.lang.Exception: The server rejected the connection: None of the protocols were accepted
at hudson.remoting.Engine.onConnectionRejected(Engine.java:655)
at hudson.remoting.Engine.innerRun(Engine.java:619)
at hudson.remoting.Engine.run(Engine.java:455)

@KostyaSha
Copy link
Owner

It may be related to remoting. Even via proxy connection slave (remoting) gets list of master address and tries to connect firstly directly, then fails jenkinsci/remoting#275 Try block output connections to master address with ICMP REJECT.

@janisBerz
Copy link
Author

janisBerz commented Jul 2, 2018

We have managed to fix our proxy to relay TCP requests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants