[JIRA] [core] (JENKINS-28499) tcpSlaveAgentListener not found

86 views
Skip to first unread message

james@howeswho.co.uk (JIRA)

unread,
May 20, 2015, 6:29:01 AM5/20/15
to jenkinsc...@googlegroups.com
James Howe created an issue
 
Jenkins / Bug JENKINS-28499
tcpSlaveAgentListener not found
Issue Type: Bug Bug
Assignee: Unassigned
Components: core, remoting
Created: 20/May/15 10:28 AM
Priority: Blocker Blocker
Reporter: James Howe

Upgraded from 1.599 to 1.614.
JNLP slaves now fail to connect with following error, where <HOST> is my actual host.
SSH slaves are unaffected.

May 20, 2015 10:57:51 AM hudson.remoting.jnlp.Main$CuiListener error
SEVERE: https://<HOST>/tcpSlaveAgentListener/ is invalid: 404 Not Found
java.lang.Exception: https://<HOST>/tcpSlaveAgentListener/ is invalid: 404 Not Found
at hudson.remoting.Engine.run(Engine.java:214)

Add Comment Add Comment
 
This message was sent by Atlassian JIRA (v6.4.2#64017-sha1:e244265)
Atlassian logo

james@howeswho.co.uk (JIRA)

unread,
May 20, 2015, 6:58:01 AM5/20/15
to jenkinsc...@googlegroups.com
James Howe commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

Downgraded to 1.611, and issue is resolved.

james@howeswho.co.uk (JIRA)

unread,
May 26, 2015, 8:34:01 AM5/26/15
to jenkinsc...@googlegroups.com
 
Re: tcpSlaveAgentListener not found

SSL is provided by an nginx proxy.

daniel@beckweb.net (JIRA)

unread,
May 26, 2015, 1:49:01 PM5/26/15
to jenkinsc...@googlegroups.com
Daniel Beck commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

Does 1.613 work correctly?

daniel@beckweb.net (JIRA)

unread,
May 26, 2015, 1:50:01 PM5/26/15
to jenkinsc...@googlegroups.com
 
Re: tcpSlaveAgentListener not found

Anything interesting in the Jenkins master log?

dbeck@cloudbees.com (JIRA)

unread,
Jun 14, 2015, 10:24:02 AM6/14/15
to jenkinsc...@googlegroups.com
Daniel Beck resolved as Incomplete
 

No response to comment asking for additional information in several weeks, so resolving as Incomplete.

Please reopen if this issue still occurs on the current Jenkins release, and provide the information requested in earlier comments. Also see https://wiki.jenkins-ci.org/display/JENKINS/How+to+report+an+issue for what information is typically useful in bug reports.

Change By: Daniel Beck
Status: Open Resolved
Resolution: Incomplete

andy@vis.ethz.ch (JIRA)

unread,
Feb 26, 2017, 2:05:02 PM2/26/17
to jenkinsc...@googlegroups.com
Andreas Tscharner reopened an issue
 

After an update this issue re-appeared, in our special configuration

Jenkins 2.32.2
Libvirt Plugin with 8 virtual machines at one and 4 times 2 virtual machines at 4 more real servers
We suffer from issue 32118 (https://issues.jenkins-ci.org/browse/JENKINS-32118), therefore we added the following Java option at our startup script: \"-Dhudson.model.DirectoryBrowserSupport.CSP=sandbox allow-scripts; default-src 'none'; img-src 'self'; style-src 'self';\"

After a restart, all our nodes stay offline (the virtual machines get started), because of this error on the clients

Change By: Andreas Tscharner
Resolution: Incomplete
Status: Resolved Reopened
This message was sent by Atlassian JIRA (v7.1.7#71011-sha1:2526d7c)
Atlassian logo

andy@vis.ethz.ch (JIRA)

unread,
Feb 26, 2017, 2:06:01 PM2/26/17
to jenkinsc...@googlegroups.com
Andreas Tscharner commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

Forget to add: If we enter this line into the script console, AFTER the startup of Jenkins, it works...

o.v.nenashev@gmail.com (JIRA)

unread,
Mar 7, 2017, 4:15:01 AM3/7/17
to jenkinsc...@googlegroups.com
Oleg Nenashev updated an issue
Change By: Oleg Nenashev
Component/s: remoting
This message was sent by Atlassian JIRA (v7.3.0#73011-sha1:3c73d0e)
Atlassian logo

o.v.nenashev@gmail.com (JIRA)

unread,
Mar 7, 2017, 4:22:07 AM3/7/17
to jenkinsc...@googlegroups.com
Oleg Nenashev commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

Andreas Tscharner Whatever happens in your use-case, it likely comes from this code: https://github.com/jenkinsci/jenkins/blob/496703d0fe133445e10c7d8d07fa7afd351c8854/core/src/main/java/jenkins/model/Jenkins.java#L1222-L1251

Due to whatever reason, the tcpAgentListener gets initialized with null. Could you please provide the full startup command line? I would suspect that one option just messes up the another one related to the TcpAgentListener

andy@vis.ethz.ch (JIRA)

unread,
Mar 8, 2017, 11:49:02 AM3/8/17
to jenkinsc...@googlegroups.com
Andreas Tscharner commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

It is the Debian startup script with the workaround:

/usr/bin/daemon --name=jenkins --inherit --env=JENKINS_HOME=/var/lib/jenkins --output=/var/log/jenkins/jenkins.log --pidfile=/var/run/jenkins/jenkins.pid – /usr/bin/java -Djava.awt.headless=true \"-Dhudson.model.DirectoryBrowserSupport.CSP=sandbox allow-scripts; default-src 'none'; img-src 'self'; style-src 'self';\" -jar /usr/share/jenkins/jenkins.war --webroot=/var/cache/jenkins/war --httpPort=8080

 

I have also tried with:  \"-Dhudson.model.DirectoryBrowserSupport.CSP= \" to no avail.

 

TIA and best regards - Andreas

andy@vis.ethz.ch (JIRA)

unread,
Mar 9, 2017, 9:32:04 AM3/9/17
to jenkinsc...@googlegroups.com
 
Re: tcpSlaveAgentListener not found

I've just realized that I have forgotten double quotes around the Java options:

/usr/bin/daemon --name=jenkins --inherit --env=JENKINS_HOME=/var/lib/jenkins --output=/var/log/jenkins/jenkins.log --pidfile=/var/run/jenkins/jenkins.pid – /usr/bin/java "-Djava.awt.headless=true \"-Dhudson.model.DirectoryBrowserSupport.CSP=sandbox allow-scripts; default-src 'none'; img-src 'self'; style-src 'self';\"" -jar /usr/share/jenkins/jenkins.war --webroot=/var/cache/jenkins/war --httpPort=8080

o.v.nenashev@gmail.com (JIRA)

unread,
Mar 13, 2017, 9:30:01 PM3/13/17
to jenkinsc...@googlegroups.com

andy@vis.ethz.ch (JIRA)

unread,
Mar 15, 2017, 6:35:02 AM3/15/17
to jenkinsc...@googlegroups.com
Andreas Tscharner commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

No. I was not clear enough before: I forgot the double quotes here in the issue tracker; on the system they have always been there...

o.v.nenashev@gmail.com (JIRA)

unread,
Mar 17, 2017, 4:54:03 AM3/17/17
to jenkinsc...@googlegroups.com
Oleg Nenashev commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

I was pretty sure we have discussed it in this ticket, but maybe I messed up the things. Could you please share your Jenkins Global Security configuration? Is the JNLP port enabled there? If no, TCPAgentListener endpoint is missing

cavegn@gmail.com (JIRA)

unread,
Feb 21, 2018, 9:32:03 AM2/21/18
to jenkinsc...@googlegroups.com
Christian Cavegn commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

Oleg Nenashev Nacho Llorens I think i just found some kind of solution:

When i enter my connection string as 'Jenkins Tunnel' instead of 'Jenkins URL', my clients seem to be able to connect to the master.

Does this make any sense?

tdh@nemlig.com (JIRA)

unread,
Oct 19, 2018, 4:36:02 AM10/19/18
to jenkinsc...@googlegroups.com
Timothy Harris commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

I am hitting the same issue. 

Background

Jenkins is running in an on premise kubernetes cluster.

NAME     READY     STATUS    RESTARTS   AGE     IP                NODE 
jenkins-0 1/1          Running   0                 5s        10.43.0.2     nem-docker-app-node05.inter-olymp.local

There are two service exposed as NodePort. One for jenkins using NodePort 30100 and one for the slave port using 30200, which is set to 50000

NAME                   TYPE                 CLUSTER-IP           EXTERNAL-IP    PORT(S)                    AGE     SELECTOR
jenkins                  NodePort         10.96.191.11          <none>            8080:30100/TCP       8s        app=jenkins
jenkins-agents      NodePort         10.108.78.226        <none>            50000:30200/TCP     8s        app=jenkins

I browse to my Jenkins instance using port 30100, e.g. http://build.mydomain.com:30100 and create a new permanent agent called test.

What I Expected

Execute the following command and the slave agent connects to Jenkins.

java -jar agent.jar -jnlpUrl http://build.mydomain.com:30100/computer/test/slave-agent.jnlp -secret c80dc7812095e908d9807b83dbb7406f03f8274f83f70ca407e9fcec2665ed7a -workDir "C:\Jenkins"

What Happened

I get a 404 not found.

Oct 19, 2018 9:57:45 AM org.jenkinsci.remoting.engine.WorkDirManager initializeWorkDir
INFO: Using C:\Jenkins\remoting as a remoting work directory
Both error and output logs will be printed to C:\Jenkins\remoting
Failing to obtain http://build.mydomain.com:30100/computer/test/slave-agent.jnlp?encrypt=true
java.io.IOException: Failed to load http://build.mydomain.com:30100/computer/test/slave-agent.jnlp?encrypt=true: 404 Not Found
at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:496)
at hudson.remoting.Launcher.run(Launcher.java:322)
at hudson.remoting.Launcher.main(Launcher.java:283)

Additional Info

Browsing to http://build.mydomain.com:30200>/ gives

Jenkins-Agent-Protocols: JNLP4-connect, Ping
Jenkins-Version: 2.121.3
Jenkins-Session: bb58e25a
Client: 10.42.0.0
Server: 10.43.0.2
Remoting-Minimum-Version: 2.60

So I am not sure what is going on here. The agent port is reachable through NodePort 30200. It sends traffic to 50000. But the slave-agent.jnlp is not found

This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

o.v.nenashev@gmail.com (JIRA)

unread,
Jan 2, 2019, 5:19:02 AM1/2/19
to jenkinsc...@googlegroups.com
Oleg Nenashev commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

JENKINS-53461 is Jenkins Remoting should address this issue for Cloud-Native platforms by removing reliance on the TCP endpoint

ozbillwang@gmail.com (JIRA)

unread,
Jan 15, 2019, 5:26:02 AM1/15/19
to jenkinsc...@googlegroups.com
Bill Wang commented on Bug JENKINS-28499
 
Re: tcpSlaveAgentListener not found

I hit the same issue, but finally fixed because I hit the wrong port

there are two default ports: 8080 and 50000 

Event 50000 is jnlp port, but when you connect to tcpSlaveAgentListener, you should use 8080

 curl localhost:8080/tcpSlaveAgentListener/

 

ozbillwang@gmail.com (JIRA)

unread,
Jan 15, 2019, 5:27:02 AM1/15/19
to jenkinsc...@googlegroups.com
I hit the same issue, but finally fixed because I hit the wrong port

there are two default ports: 8080 and 50000 

Event 50000 is jnlp port, but when you connect to *tcpSlaveAgentListener*, you should use 8080
{code:java}
curl localhost:8080/tcpSlaveAgentListener/{code}
 
Reply all
Reply to author
Forward
0 new messages