Not clear how to set up Windows node, and where to get "secret" from

405 views
Skip to first unread message

dandeliondodgeball

unread,
Oct 13, 2017, 5:40:47 PM10/13/17
to Jenkins Users
I just keep going around in circles, with all the old and out of date information I am finding on the web.

It is recommended to not try and use the Java Web Start and Launch button.  (I tried that and it doesn't work.)

But when I try and use the "java -jar slave.jar -jnlpUrl ... " solution I don't find up to date documentation on it.

I think I am just missing how to get the value for the -secret argument.

Can someone point me to the most up to date documentation?

Thanks. 

dandeliondodgeball

unread,
Oct 13, 2017, 5:43:42 PM10/13/17
to Jenkins Users
I am running Jenkins master on AWS linux, and am trying to set up a node on AWS windows.  

dandeliondodgeball

unread,
Oct 13, 2017, 5:46:38 PM10/13/17
to Jenkins Users
Is it the contents of this file?  /var/lib/jenkins/secret.key?

Mark Waite

unread,
Oct 13, 2017, 6:14:51 PM10/13/17
to jenkins...@googlegroups.com
When you open the Jenkins web page for that agent, if it is configured to start with "java -jar ...", then the specific command will be visible on the screen.  Picture attached:

Agent-Config.PNG

Mark Waite

On Fri, Oct 13, 2017 at 3:46 PM dandeliondodgeball <chris...@3derm.com> wrote:
Is it the contents of this file?  /var/lib/jenkins/secret.key?

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/97f652f5-ad24-486d-b112-241a71e6e453%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Chris Foran

unread,
Oct 13, 2017, 6:37:20 PM10/13/17
to jenkins...@googlegroups.com
Ya, that is what all the documentation says, but I never get that.  (Forgot to mention it is Windows Server 2012 R2)   I get this:
ERROR: Message not found for errorCode: 0xC00000AC
org.jinterop.dcom.common.JIException: Message not found for errorCode: 0xC00000AC
	at org.jinterop.winreg.smb.JIWinRegStub.winreg_OpenHKCR(JIWinRegStub.java:121)
	at org.jinterop.dcom.core.JIComServer.initialise(JIComServer.java:479)
Googling that I find this: https://stackoverflow.com/questions/23754417/how-to-run-jenkins-slave-on-windows-2012-r2-x64
That post says common problem is that you are running .NET 3.x 

https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/how-to-determine-which-versions-are-installed

This tells me I am running v4

How far off the trail am I now?


On Fri, Oct 13, 2017 at 6:14 PM, Mark Waite <mark.ea...@gmail.com> wrote:
When you open the Jenkins web page for that agent, if it is configured to start with "java -jar ...", then the specific command will be visible on the screen.  Picture attached:

Agent-Config.PNG

Mark Waite

On Fri, Oct 13, 2017 at 3:46 PM dandeliondodgeball <chris...@3derm.com> wrote:
Is it the contents of this file?  /var/lib/jenkins/secret.key?

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscribe@googlegroups.com.

--
You received this message because you are subscribed to a topic in the Google Groups "Jenkins Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jenkinsci-users/nQUG9G51sRM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jenkinsci-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtF9r0PkSrReXwGZPx8_ftNBQqF%3D8phw8apk9Zv06xgZqA%40mail.gmail.com.

For more options, visit https://groups.google.com/d/optout.



--
Chris Foran       | Senior Software Engineer
(617) 586-9962 | chris...@3Derm.com 

101 Huntington Ave, 17th Floor
Suite 1300 c/o 3Derm @ BCBSMA
Boston, MA 02199

Mark Waite

unread,
Oct 13, 2017, 6:49:27 PM10/13/17
to Jenkins Users


On Friday, October 13, 2017 at 4:37:20 PM UTC-6, dandeliondodgeball wrote:
Ya, that is what all the documentation says, but I never get that.  (Forgot to mention it is Windows Server 2012 R2)   I get this:
ERROR: Message not found for errorCode: 0xC00000AC
org.jinterop.dcom.common.JIException: Message not found for errorCode: 0xC00000AC
	at org.jinterop.winreg.smb.JIWinRegStub.winreg_OpenHKCR(JIWinRegStub.java:121)
	at org.jinterop.dcom.core.JIComServer.initialise(JIComServer.java:479)

I don't understand where you're getting that.  Possibly that is some output from an attempt to register a running agent as a Windows service?

Based on earlier context of your question, I'd have guessed that you:
  1. Configured a Jenkins master (Windows or Linux?)
  2. Added an agent through the Jenkins master web pages
  3. Opened the web page of that agent from the Windows machine where you want to start the agent
  4. Downloaded the slave.jar from that web page
  5. Pasted the command line to start the slave into a command window on the desktop of your new Windows agent
  6. Confirm that it connects to your Jenkins master
I don't expect any of those steps to call anything related to the Windows registry.

Can you help me understand what I've missed in the steps you're taking?

Mark Waite

 
Googling that I find this: https://stackoverflow.com/questions/23754417/how-to-run-jenkins-slave-on-windows-2012-r2-x64
That post says common problem is that you are running .NET 3.x 

https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/how-to-determine-which-versions-are-installed

This tells me I am running v4

How far off the trail am I now?

On Fri, Oct 13, 2017 at 6:14 PM, Mark Waite  wrote:
When you open the Jenkins web page for that agent, if it is configured to start with "java -jar ...", then the specific command will be visible on the screen.  Picture attached:

Agent-Config.PNG

Mark Waite

On Fri, Oct 13, 2017 at 3:46 PM dandeliondodgeball  wrote:
Is it the contents of this file?  /var/lib/jenkins/secret.key?

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/97f652f5-ad24-486d-b112-241a71e6e453%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "Jenkins Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jenkinsci-users/nQUG9G51sRM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jenkinsci-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/CAO49JtF9r0PkSrReXwGZPx8_ftNBQqF%3D8phw8apk9Zv06xgZqA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



--
Chris Foran       | Senior Software Engineer
101 Huntington Ave, 17th Floor

dandeliondodgeball

unread,
Oct 16, 2017, 10:15:40 AM10/16/17
to Jenkins Users
Not able to reply to the last post in this thread.  Tried different browsers, so don't think it is me.
Problem looks aws windows server 2012 specific, so starting a new thread.

dandeliondodgeball

unread,
Oct 16, 2017, 10:23:42 AM10/16/17
to Jenkins Users
I was wrong, about not being able to reply to the last post. So let me continue. 

  1. Jenkins master on aws linux
  2. Manually copied slave.jar to aws windows server 2012
  3. Added a node through the Jenkins master web pages
    1. Host set to public ip of aws windows server 2012
    2. Remote root directory set to C:\\Jenkins, which is where I put slave.jar
  4. Went to the overview page for that agent/node and selected "Launch agent"  
ERROR: Message not found for errorCode: 0xC00000AC
org.jinterop.dcom.common.JIException: Message not found for errorCode: 0xC00000AC
     at org.jinterop.winreg.smb.JIWinRegStub.winreg_OpenHKCR(JIWinRegStub.java:121)
     at org.jinterop.dcom.core.JIComServer.initialise(JIComServer.java:479)
 
 
That post says common problem is that you are running .NET 3.x 

 

This tells me I am running .NET v4

https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/how-to-determine-which-versions-are-installed

 

      So appears I need to spend more time looking into aws windows server 2012 settings, related to running Jenkins agents.  

      Unless someone knows the answer to my problem


Thanks.


Mark Waite

unread,
Oct 16, 2017, 10:32:15 AM10/16/17
to Jenkins Users
I think that the answer to your problem is to use the steps I listed rather than the steps that you listed.

Pressing the "launch agent" button causes the Jenkins server to attempt to start the agent on the Windows machine.  That seems to use some form of COM based entity to launch the agent on the Windows machine.

If you download the "slave.jar" file, create a local batch file that invokes that slave.jar, and run that batch file, you'll start your agent on the Windows machine.

Mark Waite

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/1640523b-3590-425d-a5c5-c9396509a743%40googlegroups.com.

dandeliondodgeball

unread,
Oct 16, 2017, 12:06:38 PM10/16/17
to Jenkins Users

> I think that the answer to your problem is to use the steps I listed rather than the steps that you listed.

Fair.  Let me back up.

 

> 4. Downloaded the slave.jar from that web page

Can you give more detail on this step?  Or is this the “Launch agent” button action?

Mark Waite

unread,
Oct 16, 2017, 12:11:18 PM10/16/17
to jenkins...@googlegroups.com
In the command line section of that web page (red box in the screen shot I sent), there is a clickable link for slave.jar.  That's the link to the slave.jar to download. 

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.

dandeliondodgeball

unread,
Oct 17, 2017, 11:39:37 AM10/17/17
to Jenkins Users

I think one reason I keep getting off track, is that I don't get the second bullet "Run from Agent command line", as shown in your screen shot. 

 

All I get is the "Launch" button and I keep trying to make that work.  With no luck so far.

 

AWS linux for Jenkins master

AWS Windows server 2012 for node

 

The steps I am following:

    • Configured a Jenkins master
    • Add an agent through the Jenkins master web pages
    • Open the web page of that agent from the Windows machine where you want to start the agent
      • Goto node detail page

Actually your screen shot shows “Launch” button with a Java icon, while I get a “Launch agent” button.  See screen shot.



Also on the node overview page, should the instance be listed as Windows (for Architecture)? See screen shot.




Mark Waite

unread,
Oct 17, 2017, 11:46:33 AM10/17/17
to jenkins...@googlegroups.com
On Tue, Oct 17, 2017 at 9:39 AM dandeliondodgeball <chris...@3derm.com> wrote:

I think one reason I keep getting off track, is that I don't get the second bullet "Run from Agent command line", as shown in your screen shot. 

 

All I get is the "Launch" button and I keep trying to make that work.  With no luck so far.


Thanks for the clarification!  I didn't understand how you were missing something that I see all the time.

That may indicate that you're missing one or more plugins.  I've never seen that behavior, but that is probably because I have the plugin installed.

You might compare your list of plugins installed with the set that I use.  The set I use is listed in https://github.com/MarkEWaite/docker-lfs/tree/lts-with-plugins/ref/plugins .  I admit that is a very long list of plugins, but (for example), you may need the ssh-slaves plugin or the windows-slaves plugin or the swarm plugin.

Mark Waite
 

 

AWS linux for Jenkins master

AWS Windows server 2012 for node

 

The steps I am following:

    • Configured a Jenkins master
    • Add an agent through the Jenkins master web pages
    • Open the web page of that agent from the Windows machine where you want to start the agent
      • Goto node detail page

Actually your screen shot shows “Launch” button with a Java icon, while I get a “Launch agent” button.  See screen shot.



Also on the node overview page, should the instance be listed as Windows (for Architecture)? See screen shot.




--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-use...@googlegroups.com.

Daniel Beck

unread,
Oct 17, 2017, 12:09:01 PM10/17/17
to jenkins...@googlegroups.com

> On 17. Oct 2017, at 17:39, dandeliondodgeball <chris...@3derm.com> wrote:
>
> All I get is the "Launch" button and I keep trying to make that work. With no luck so far.

Enable the JNLP agent port on the security configuration form.

dandeliondodgeball

unread,
Oct 17, 2017, 1:29:13 PM10/17/17
to Jenkins Users
> Enable the JNLP agent port on the security configuration form. 

That did it.  This blog has nice screen shots of that.  Thanks.
Reply all
Reply to author
Forward
0 new messages