Issue
I have installed jenkins from ubuntu server.Iam trying to create a new windows slave node.But i am unable to get the option "Launch Java Web Start slave agent" to select in the launch method
I have already tried this
Go to Jenkins dashboard -> Manage Jenkins -> Configure Global Security
Click on Enable Security, if not already checked.
Select the Random radio button for TCP port for JNLP agents option.
Save this config
It doesnot solve my issue
Name : Windows Description : windows slave No of executors : 1 Root directory : C:/jenkins/ Usage : Use this node as much as possible Launch method : Launch Java Web Start slave agent
I want this option to be available in my launch method "Launch Java Web Start slave agent"
Solution
I think maybe the wording changed and the documentation has not kept up. Documenting here even tho plenty of other answers on S/O (here, here, here, here, etc), so as to clarify the wording change:
WAS: "Launch slave agents via Java Web Start"
NOW: "Launch agent by connecting it to the master"
Validation:
Downloaded 2.176.1 and performed new simple install (java -jar jenkins.war
)
Added only "WMI Windows Agents Plugin" (aka windows slaves).
Jenkins | Manage Jenkins | Configure Global Security
Agents
TCP port for inbound agents: [o] Random
Jenkins | Manage Jenkins | Nodes
New Node [Node-1],
[o] Permanent Agent
[OK]
Remote root directory: [D:\J2-Node-1]
Launch Method: ["Launch agent by connecting it to the master"]
(This wording has changed and is what's throwing you off)
[Save]
You will now be presented with the expected options: Connect agent to Jenkins one of these ways:
•[Launch agent] Launch agent from browser
•Run from agent command line:
java -jar agent.jar -jnlpUrl http://localhost:8080/computer/Node/slave-agent.jnlp \
-secret 5580c9391dca3b680fb906647ee115b43497dc975e115d51e59cf73ef1c31789 -workDir "D:\J2-Node-1"
Clicking the launch button now works as expected and brings up the pop-up window and the option to "Install as a Service".
I'd still suggest using Launch via DCOM using "Let jenkins control this Windows agent as a Windows service", just review documentation at Windows agents fail to start via DCOM and they seem to work fine for us and is ultimately easier to manage.
Answered By - Ian W
Answer Checked By - Terry (JavaFixing Volunteer)