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

Missing osFamily attribute in Node definition causes command to fail #406

Closed
rborer opened this issue May 28, 2013 · 7 comments
Closed

Missing osFamily attribute in Node definition causes command to fail #406

rborer opened this issue May 28, 2013 · 7 comments
Labels
Milestone

Comments

@rborer
Copy link

rborer commented May 28, 2013

When a job is defined with options, and a Command step tries to use the value of an option, the execution always fails.

For example (see screenshot), my job takes a parameter named goal, if I try to use it with ${option.goal} the job fails to execute at that step with the following error:

01:24:55 [rbr@localhost  ][CONFIG] [workflow] Begin execution: rundeck-workflow-node-first context: null
01:24:55 [rbr@localhost  ][CONFIG] preparing for sequential execution on 1 nodes
01:24:55 [rbr@localhost  ][CONFIG] Executing command on node: val1generation1a.hrp, NodeEntryImpl{tags=[val1, odd, hrp, generation], attributes={tags=generation, hrp, odd, val1, username=rundeck-t, hostname=val1generation1a.stx.local, nodename=val1generation1a.hrp}, project='null'}
01:24:55 [rbr@localhost  ][CONFIG] NodeSet: MultiNodeSelector{nodenames=[val1generation1a.hrp]}
01:24:55 [rbr@localhost  ][CONFIG] Workflow: com.dtolabs.rundeck.core.execution.workflow.StepFirstWorkflowStrategy$stepFirstWrapper@ca8ab160
01:24:55 [rbr@localhost  ][CONFIG] data context: {node={tags=val1,odd,hrp,generation, username=rundeck-t, os-version=, description=, name=val1generation1a.hrp, os-arch=, hostname=val1generation1a.stx.local, os-name=, os-family=}, job={id=245b93da-f429-4c0e-8ed4-71a4bc9fc0dc, project=SecuTix, loglevel=DEBUG, username=rbr, user.name=rbr, name=hostname, group=deployment/generic/services, execid=52}, option={tags=val1+generation, goal=pre-install}}
01:24:55 [@  1-NodeDispatch-script][CONFIG] [workflow] Begin step: 1,NodeDispatch
01:24:55 [@  1-NodeDispatch-script][CONFIG] 1: Workflow step executing: com.dtolabs.rundeck.execution.ExecutionItemFactory$1@701d2756
01:24:55 [@  1-NodeDispatch-script][CONFIG] preparing for sequential execution on 1 nodes
01:24:55 [@  1-NodeDispatch-script][CONFIG] Executing command on node: val1generation1a.hrp, NodeEntryImpl{tags=[val1, odd, hrp, generation], attributes={tags=generation, hrp, odd, val1, username=rundeck-t, hostname=val1generation1a.stx.local, nodename=val1generation1a.hrp}, project='null'}
01:24:55 [[email protected]  1-NodeDispatch-script][CONFIG] [workflow] beginExecuteNodeStep(val1generation1a.hrp): NodeDispatch: com.dtolabs.rundeck.execution.ExecutionItemFactory$1@701d2756
01:24:56 [[email protected]  1-NodeDispatch-script][CONFIG] Using ssh keyfile: /var/lib/rundeck/.ssh/id_rsa
01:24:56 [[email protected]  1-NodeDispatch-script][CONFIG] Starting SSH Connection: [email protected] (val1generation1a.hrp)
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Set timeout to 0
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Connecting to val1generation1a.stx.local:22
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Connecting to val1generation1a.stx.local port 22
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Connection established
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Remote version string: SSH-2.0-OpenSSH_5.5p1 Debian-6+squeeze3
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Local version string: SSH-2.0-JSCH-0.1.45
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr,arcfour,arcfour128,arcfour256
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] aes256-ctr is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] aes192-ctr is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] aes256-cbc is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] aes192-cbc is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] arcfour256 is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] CheckKexes: diffie-hellman-group14-sha1
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] diffie-hellman-group14-sha1 is not available.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXINIT sent
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXINIT received
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] kex: server->client aes128-ctr hmac-md5 none
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] kex: client->server aes128-ctr hmac-md5 none
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXDH_INIT sent
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] expecting SSH_MSG_KEXDH_REPLY
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] ssh_rsa_verify: signature true
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Permanently added 'val1generation1a.stx.local' (RSA) to the list of known hosts.
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_NEWKEYS sent
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_NEWKEYS received
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_SERVICE_REQUEST sent
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_SERVICE_ACCEPT received
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Authentications that can continue: publickey,keyboard-interactive,password
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Next authentication method: publickey
01:24:56 [[email protected]  1-NodeDispatch-script][WARNING] Authentication succeeded (publickey).
01:24:57 [[email protected]  1-NodeDispatch-script][CONFIG] Adding reference: ant.PropertyHelper
01:24:57 [[email protected]  1-NodeDispatch-script][CONFIG] Setting project property: sshexec.output -> 
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Disconnecting from val1generation1a.stx.local port 22
01:24:57 [[email protected]  1-NodeDispatch-script][CONFIG] Using ssh keyfile: /var/lib/rundeck/.ssh/id_rsa
01:24:57 [[email protected]  1-NodeDispatch-script][CONFIG] Starting SSH Connection: [email protected] (val1generation1a.hrp)
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Set timeout to 0
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Connecting to val1generation1a.stx.local:22
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Connecting to val1generation1a.stx.local port 22
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Caught an exception, leaving main loop due to Socket closed
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Connection established
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Remote version string: SSH-2.0-OpenSSH_5.5p1 Debian-6+squeeze3
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Local version string: SSH-2.0-JSCH-0.1.45
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr,arcfour,arcfour128,arcfour256
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] aes256-ctr is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] aes192-ctr is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] aes256-cbc is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] aes192-cbc is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] arcfour256 is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] CheckKexes: diffie-hellman-group14-sha1
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] diffie-hellman-group14-sha1 is not available.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXINIT sent
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXINIT received
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] kex: server->client aes128-ctr hmac-md5 none
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] kex: client->server aes128-ctr hmac-md5 none
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_KEXDH_INIT sent
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] expecting SSH_MSG_KEXDH_REPLY
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] ssh_rsa_verify: signature true
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Permanently added 'val1generation1a.stx.local' (RSA) to the list of known hosts.
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_NEWKEYS sent
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_NEWKEYS received
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_SERVICE_REQUEST sent
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] SSH_MSG_SERVICE_ACCEPT received
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Authentications that can continue: publickey,keyboard-interactive,password
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Next authentication method: publickey
01:24:57 [[email protected]  1-NodeDispatch-script][WARNING] Authentication succeeded (publickey).
01:24:57 [[email protected]  1-NodeDispatch-script][INFO] Goal is pre-install
01:24:58 [[email protected]  1-NodeDispatch-script][CONFIG] Adding reference: ant.PropertyHelper
01:24:58 [[email protected]  1-NodeDispatch-script][CONFIG] Setting project property: sshexec.output -> Goal is pre-install
01:24:58 [[email protected]  1-NodeDispatch-script][WARNING] Disconnecting from val1generation1a.stx.local port 22
01:24:58 [@  1-NodeDispatch-script][CONFIG] [workflow] finishExecuteNodeStep(val1generation1a.hrp): NodeDispatch: Succeeded
01:24:58 [@  1-NodeDispatch-script][CONFIG] 1: Workflow step finished, result: Dispatch successful (1 nodes)
01:24:58 [rbr@localhost  ][CONFIG] [workflow] Finish step: 1,NodeDispatch
01:24:58 [@  2-NodeDispatch-exec][CONFIG] [workflow] Begin step: 2,NodeDispatch
01:24:58 [@  2-NodeDispatch-exec][CONFIG] 2: Workflow step executing: com.dtolabs.rundeck.execution.ExecutionItemFactory$4@a01b89b
01:24:58 [[email protected]  1-NodeDispatch-script][WARNING] Caught an exception, leaving main loop due to Socket closed
01:24:58 [@  2-NodeDispatch-exec][CONFIG] preparing for sequential execution on 1 nodes
01:24:58 [@  2-NodeDispatch-exec][CONFIG] Executing command on node: val1generation1a.hrp, NodeEntryImpl{tags=[val1, odd, hrp, generation], attributes={tags=generation, hrp, odd, val1, username=rundeck-t, hostname=val1generation1a.stx.local, nodename=val1generation1a.hrp}, project='null'}
01:24:58 [[email protected]  2-NodeDispatch-exec][CONFIG] [workflow] beginExecuteNodeStep(val1generation1a.hrp): NodeDispatch: com.dtolabs.rundeck.execution.ExecutionItemFactory$4@a01b89b
01:24:58 [@  2-NodeDispatch-exec][CONFIG] [workflow] finishExecuteNodeStep(val1generation1a.hrp): NodeDispatch: null
01:24:58 [rbr@localhost  ][CONFIG] [workflow] Finish execution:  rundeck-workflow-node-first: [Workflow , Node failures: {val1generation1a.hrp=[]}]
01:24:58 [null@null null null][SEVERE] [Workflow , Node failures: {val1generation1a.hrp=[]}]

Here is the defined job:

selection_039

@gschueler
Copy link
Member

is there any output in the server log?

@rborer
Copy link
Author

rborer commented May 29, 2013

Here is what I can find in rundeck.log

2013-05-29 09:21:40,149 [955974647@qtp-558834239-202] INFO  grails.app.service.rundeck.services.ScheduledExecutionService - scheduling immediate job run: TEMP:rbr:13:54
2013-05-29 09:21:40,161 [quartzScheduler_Worker-9] WARN  grails.app.task.rundeck.quartzjobs.ExecutionJob - ExecutionJob: Execution not found with ID [54], will retry for up to 60 seconds...
2013-05-29 09:21:42,197 [quartzScheduler_Worker-9] INFO  grails.app.task.rundeck.quartzjobs.ExecutionJob - ExecutionJob: Execution found with ID [54] retried (1)
2013-05-29 09:21:44,877 [quartzScheduler_Worker-9] ERROR grails.app.service.rundeck.services.ExecutionService - Execution failed: 54: [Workflow , Node failures: {val1generation1a.hrp=[]}]
2013-05-29 09:21:44,933 [quartzScheduler_Worker-9] INFO  grails.app.service.rundeck.services.ExecutionService - updated scheduled Execution

I'm not convinced it's useful, if needed I can change the log levels to have more details.

@gschueler
Copy link
Member

can you post your node definition for the target node?

@gschueler
Copy link
Member

oh I think I reproduced the issue. I think you are missing the osFamily attribute for your node, it should be set to "unix" or "windows".

When I removed the attribute from my node, I saw the same error.

@rborer
Copy link
Author

rborer commented May 29, 2013

You are right, my machines seems to not have this attribute at all. I'll try to add it and see if it solves my issue.

@rborer
Copy link
Author

rborer commented May 30, 2013

I can confirm adding this field fixed my issue.

@gschueler
Copy link
Member

@rborer thanks

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

No branches or pull requests

2 participants