Showing exception while connecting slave to master using headless jnlp Showing exception while connecting slave to master using headless jnlp jenkins jenkins

Showing exception while connecting slave to master using headless jnlp


JNLP slave connection problems are usually due to incorrect "Jenkins URL" setting in Jenkins global configuration. Please verify it.

If the setting is correct, I think you need to seriously consider the possibility that something is blocking the connection between your Windows slave and Linux master. Could there be a firewall installed on one or both hosts?

If there is a firewall, you might want to first set up a fixed port for JNLP connections and then configure the firewall on Linux master to accept inbound connections to that port and configure Windows firewall to accept outbound connections to that port.

The first part I can show you: Go to Jenkins master, Manage Jenkins, System Configuration. Check the box "Activate security".

A new section will appear. Check the box "TCP port for JNLP slave agents" and set any free port number you want. Please note that non-root processes cannot use ports under 1024, so you should choose something above that. Port numbers are 16 bit unsigned integers, so maximum is 65535.

The second part about firewall configuration I cannot help you with. How to allow access to the JNLP port is entirely up to the firewall software on your master and slave. Please refer to the manuals of those for details.

If it still does not work, I suggest you use tcpdump host demo.sigmainfo.in to see if the slave is really sending packets to the right interface of the right host.


With a windows master and mac jenkins slave, I got;

 java.lang.exception: the serverrejected the connection: None of the protocols were accepted

because I had changed our machine's credentials and had failed to inform jenkins. Since the error seems so far off from the issue, I thought I would post for my future self.


Once, I had this error because I already had a connection up, so check your connections.