Having trouble getting winrm running

2,214 views
Skip to first unread message

Evelyn Dibben

unread,
May 18, 2015, 3:19:14 PM5/18/15
to rundeck...@googlegroups.com
I'm new to winrm and I don't do much administration on Windows.

On my Windows 2003 SP 2 server:

>winrm set winrm/config/service/Auth @{Basic="true"}
Auth
    Basic = true
    Kerberos = true
    Negotiate = true
    Certificate = false
    CbtHardeningLevel = Relaxed

I created a job that just executes 'DIR' with Secure winrmPassword.  I'm running http not https.  I've turned on debug level logging.  Any idea of what the issue is?  Does this (Connection to http://ft-admin1:5985 refused) mean there is a firewall problem or is the an authentication problem?


[workflow] Begin execution: rundeck-workflow-node-first context: null
preparing for sequential execution on 1 nodes
Executing command on node: ft-admin1, NodeEntryImpl{tags=[Windows], attributes={osFamily=windows, tags=Windows, Location=PHX1, hostname=ft-admin1, winrm-protocol=http, username=edibben, description=TrimFleet FT Admin1, winrm-auth-type=basic, nodename=ft-admin1, node-executor=overthere-winrm, Business Unit=TrimFleet, winrm-password-storage-path=keys/projects/TrimFleetAdministration/nodes/edibben.password, osName=Windows}, project='null'}
NodeSet: MultiNodeSelector{nodenames=[ft-admin1]}
Workflow: com.dtolabs.rundeck.core.execution.workflow.StepFirstWorkflowStrategy$stepFirstWrapper@5494cccd
data context: {node={tags=Windows, os-version=, hostname=ft-admin1, Location=PHX1, winrm-protocol=http, os-name=Windows, os-family=windows, username=edibben, description=TrimFleet FT Admin1, name=ft-admin1, os-arch=, winrm-auth-type=basic, node-executor=overthere-winrm, Business Unit=TrimFleet, winrm-password-storage-path=keys/projects/TrimFleetAdministration/nodes/edibben.password}, job={loglevel=DEBUG, wasRetry=false, url=http://internal-ELB-INT-IADA-TRD-1847831999.us-east-1.elb.amazonaws.com:4440/project/TrimFleetAdministration/execution/follow/14466, id=c43421be-526a-48d0-920d-f4a2e8b9d679, project=TrimFleetAdministration, username=admin, retryAttempt=0, user.name=admin, name=Test Windows Job, serverUUID=fac1d65a-026d-418c-8393-80106a064469, group=null, execid=14466, serverUrl=http://internal-ELB-INT-IADA-TRD-1847831999.us-east-1.elb.amazonaws.com:4440/}, option={}}
[workflow] Begin step: 1,NodeDispatch
1: Workflow step executing: com.dtolabs.rundeck.execution.ExecutionItemFactory$4@3bd1e35a
preparing for sequential execution on 1 nodes
Executing command on node: ft-admin1, NodeEntryImpl{tags=[Windows], attributes={osFamily=windows, tags=Windows, Location=PHX1, hostname=ft-admin1, winrm-protocol=http, username=edibben, description=TrimFleet FT Admin1, winrm-auth-type=basic, nodename=ft-admin1, node-executor=overthere-winrm, Business Unit=TrimFleet, winrm-password-storage-path=keys/projects/TrimFleetAdministration/nodes/edibben.password, osName=Windows}, project='null'}
[workflow] beginExecuteNodeStep(ft-admin1): NodeDispatch: com.dtolabs.rundeck.execution.ExecutionItemFactory$4@3bd1e35a
[overthere-winrm:ft-admin1] dir
[overthere-winrm:ft-admin1] ConnectionOptions[ port --> 5985 os --> WINDOWS username --> edibben address --> ft-admin1 winrmEnableHttps --> false winrmKerberosAddPortToSpn --> false connectionType --> WINRM_INTERNAL connectionTimeoutMillis --> 15000 winrmKerberosUseHttpSpn --> false password --> ******** ]
com.xebialabs.overthere.cifs.winrm.WinRmRuntimeIOException: Error when sending request to http://ft-admin1:5985/wsman
Request:
<?xml version="1.0" encoding="UTF-8"?>
<env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope">
<env:Header>
<a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To>
<a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">
<a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address>
</a:ReplyTo>
<w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize>
<a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID>
<w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/>
<p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/>
<w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout>
<a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action>
<w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI>
<w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">
<w:Option Name="WINRS_NOPROFILE">FALSE</w:Option>
<w:Option Name="WINRS_CODEPAGE">437</w:Option>
</w:OptionSet>
</env:Header>
<env:Body>
<rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell">
<rsp:InputStreams>stdin</rsp:InputStreams>
<rsp:OutputStreams>stdout stderr</rsp:OutputStreams>
</rsp:Shell>
</env:Body>
</env:Envelope>
Response:
[EMPTY]
at com.xebialabs.overthere.cifs.winrm.WinRmClient.doSendRequest(WinRmClient.java:438)
at com.xebialabs.overthere.cifs.winrm.WinRmClient.sendRequest(WinRmClient.java:353)
at com.xebialabs.overthere.cifs.winrm.WinRmClient.createShell(WinRmClient.java:157)
at com.xebialabs.overthere.cifs.winrm.CifsWinRmConnection.startProcess(CifsWinRmConnection.java:120)
at com.xebialabs.overthere.spi.BaseOverthereConnection.execute(BaseOverthereConnection.java:257)
at com.dtolabs.rundeck.plugin.overthere.OTWinRMNodeExecutor.executeCommand(OTWinRMNodeExecutor.java:197)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.executeCommand(ExecutionServiceImpl.java:333)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.executeCommand(ExecutionServiceImpl.java:307)
at com.dtolabs.rundeck.core.execution.workflow.steps.node.impl.ExecNodeStepExecutor.executeNodeStep(ExecNodeStepExecutor.java:53)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.executeNodeStep(ExecutionServiceImpl.java:149)
at com.dtolabs.rundeck.core.execution.dispatch.SequentialNodeDispatcher.dispatch(SequentialNodeDispatcher.java:116)
at com.dtolabs.rundeck.core.execution.dispatch.SequentialNodeDispatcher.dispatch(SequentialNodeDispatcher.java:58)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.dispatchToNodes(ExecutionServiceImpl.java:177)
at com.dtolabs.rundeck.core.execution.workflow.steps.NodeDispatchStepExecutor.executeWorkflowStep(NodeDispatchStepExecutor.java:66)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.executeStep(ExecutionServiceImpl.java:116)
at com.dtolabs.rundeck.core.execution.workflow.BaseWorkflowStrategy.executeWFItem(BaseWorkflowStrategy.java:166)
at com.dtolabs.rundeck.core.execution.workflow.BaseWorkflowStrategy.executeWorkflowItemsForNodeSet(BaseWorkflowStrategy.java:226)
at com.dtolabs.rundeck.core.execution.workflow.BaseWorkflowStrategy.executeWorkflowItemsForNodeSet(BaseWorkflowStrategy.java:193)
at com.dtolabs.rundeck.core.execution.workflow.StepFirstWorkflowStrategy.executeWorkflowImpl(StepFirstWorkflowStrategy.java:79)
at com.dtolabs.rundeck.core.execution.workflow.BaseWorkflowStrategy.executeWorkflow(BaseWorkflowStrategy.java:124)
at com.dtolabs.rundeck.core.execution.workflow.NodeFirstWorkflowStrategy$DispatchedWorkflow.dispatch(NodeFirstWorkflowStrategy.java:366)
at com.dtolabs.rundeck.core.execution.dispatch.SequentialNodeDispatcher.dispatch(SequentialNodeDispatcher.java:118)
at com.dtolabs.rundeck.core.execution.dispatch.SequentialNodeDispatcher.dispatch(SequentialNodeDispatcher.java:64)
at com.dtolabs.rundeck.core.execution.ExecutionServiceImpl.dispatchToNodes(ExecutionServiceImpl.java:196)
at com.dtolabs.rundeck.core.execution.workflow.NodeFirstWorkflowStrategy.executeWFSectionNodeDispatch(NodeFirstWorkflowStrategy.java:178)
at com.dtolabs.rundeck.core.execution.workflow.NodeFirstWorkflowStrategy.executeWorkflowImpl(NodeFirstWorkflowStrategy.java:107)
at com.dtolabs.rundeck.core.execution.workflow.BaseWorkflowStrategy.executeWorkflow(BaseWorkflowStrategy.java:124)
at com.dtolabs.rundeck.core.execution.WorkflowExecutionServiceThread.run(WorkflowExecutionServiceThread.java:55)
Caused by: org.apache.http.conn.HttpHostConnectException: Connection to http://ft-admin1:5985 refused
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:190)
at org.apache.http.impl.conn.ManagedClientConnectionImpl.open(ManagedClientConnectionImpl.java:294)
at org.apache.http.impl.client.DefaultRequestDirector.tryConnect(DefaultRequestDirector.java:640)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:479)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:805)
at com.xebialabs.overthere.cifs.winrm.WinRmClient.doSendRequest(WinRmClient.java:420)
... 27 more
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:579)
at org.apache.http.conn.scheme.PlainSocketFactory.connectSocket(PlainSocketFactory.java:127)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:180)
... 33 more
[overthere-winrm:ft-admin1] failed: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]
Failed: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]
[workflow] finishExecuteNodeStep(ft-admin1): NodeDispatch: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]
1: Workflow step finished, result: Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]
[workflow] Finish step: 1,NodeDispatch
[workflow] Finish execution: rundeck-workflow-node-first: [Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}, Node failures: {ft-admin1=[WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsman Request: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}]
[Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}, Node failures: {ft-admin1=[WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsman Request: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}]
Execution failed: 14466: [Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsmanRequest: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}, Node failures: {ft-admin1=[WinRMProtocolError: Error when sending request to http://ft-admin1:5985/wsman Request: <?xml version="1.0" encoding="UTF-8"?> <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope"> <env:Header> <a:To xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">http://ft-admin1:5985/wsman</a:To> <a:ReplyTo xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing"> <a:Address mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous</a:Address> </a:ReplyTo> <w:MaxEnvelopeSize xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">153600</w:MaxEnvelopeSize> <a:MessageID xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing">uuid:89A20160-868E-421C-8839-59B176738D61</a:MessageID> <w:Locale xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <p:DataLocale xmlns:p="http://schemas.microsoft.com/wbem/wsman/1/wsman.xsd" mustUnderstand="false" xml:lang="en-US"/> <w:OperationTimeout xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd">PT60.000S</w:OperationTimeout> <a:Action xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" mustUnderstand="true">http://schemas.xmlsoap.org/ws/2004/09/transfer/Create</a:Action> <w:ResourceURI xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd" mustUnderstand="true">http://schemas.microsoft.com/wbem/wsman/1/windows/shell/cmd</w:ResourceURI> <w:OptionSet xmlns:w="http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd"> <w:Option Name="WINRS_NOPROFILE">FALSE</w:Option> <w:Option Name="WINRS_CODEPAGE">437</w:Option> </w:OptionSet> </env:Header> <env:Body> <rsp:Shell xmlns:rsp="http://schemas.microsoft.com/wbem/wsman/1/windows/shell"> <rsp:InputStreams>stdin</rsp:InputStreams> <rsp:OutputStreams>stdout stderr</rsp:OutputStreams> </rsp:Shell> </env:Body> </env:Envelope> Response: [EMPTY]]}]

didier ernotte

unread,
May 19, 2015, 12:40:05 PM5/19/15
to rundeck...@googlegroups.com
There is some check to do on the remote windows server :

- winrm enum winrm/config/listener
to test if there is a listener for winrm

- netstat -nab
there should be a process listening on the 5985 or 5986

on the rundeck server :
- telnet ip_of_the_window_server 5985
to check if the rundeck server is able to talk to the 5985 port. It may be a firewall issue between the 2 servers.

Didier


Evelyn Dibben

unread,
May 20, 2015, 9:59:14 AM5/20/15
to rundeck...@googlegroups.com
C>winrm enum winrm/config/listener
Listener
    Address = *
    Transport = HTTP
    Port = 5985
    Hostname
    Enabled = true
    URLPrefix = wsman
    CertificateThumb

C:\>netstat -nab |find "5985"
  TCP    0.0.0.0:5985           0.0.0.0:0              LISTENING       4
print
    ListeningOn = 10.133.84.16, 127.0.0.1


# telnet ft-admin1 5985

Trying 10.133.84.16...

Connected to ft-admin1.

Escape character is '^]'.

 

...

Greg Schueler

unread,
May 20, 2015, 12:09:56 PM5/20/15
to rundeck...@googlegroups.com
Hi Evelyn,

A few things to try:

* if using Kerberos auth, did you set the JVM properties mentioned here https://github.com/rundeck-plugins/rundeck-winrm-plugin#configure-kerberos
* if using basic/local account, make sure the user account has admin privs on the target node (add them to the Administrator group)

what is the output of "winrm g winrm/config” ?


-- 
You received this message because you are subscribed to the Google Groups "rundeck-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rundeck-discu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rundeck-discuss/a47f42e9-c0d7-434d-8a38-31b692c31615%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Evelyn Dibben

unread,
May 20, 2015, 1:45:26 PM5/20/15
to rundeck...@googlegroups.com

After giving up on Kerberos I created an account directly on the server (it is in the Administrators group).  I’ve verified the account.  Here is the error message when I try to run my job:

 

[overthere-winrm:ft-admin1] failed: WinRM Error: Unexpected HTTP response on http://ft-admin1:5985/wsman: (401)Failed: WinRMProtocolError: WinRM Error: Unexpected HTTP response on http://ft-admin1:5985/wsman: (401)Execution failed: 14869: [Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: WinRM Error: Unexpected HTTP response on http://ft-admin1:5985/wsman: (401)]}, Node failures: {ft-admin1=[WinRMProtocolError: WinRM Error: Unexpected HTTP response on http://ft-admin1:5985/wsman: (401)]}]

 

WinRM configuration:

 

C:\Documents and Settings\edibben>winrm get winrm/config

Config

    MaxEnvelopeSizekb = 150

    MaxTimeoutms = 60000

    MaxBatchItems = 32000

    MaxProviderRequests = 4294967295

    Client

        NetworkDelayms = 5000

        URLPrefix = wsman

        AllowUnencrypted = true

        Auth

            Basic = true

            Digest = true

            Kerberos = true

            Negotiate = true

            Certificate = true

        DefaultPorts

            HTTP = 5985

            HTTPS = 5986

        TrustedHosts = *

    Service

        RootSDDL = O:NSG:BAD:P(A;;GA;;;BA)S:P(AU;FA;GA;;;WD)(AU;SA;GWGX;;;WD)

        MaxConcurrentOperations = 4294967295

        MaxConcurrentOperationsPerUser = 15

        EnumerationTimeoutms = 60000

        MaxConnections = 25

        MaxPacketRetrievalTimeSeconds = 120

        AllowUnencrypted = false

        Auth

            Basic = true

            Kerberos = true

            Negotiate = true

            Certificate = false

            CbtHardeningLevel = Relaxed

        DefaultPorts

            HTTP = 5985

            HTTPS = 5986

        IPv4Filter = *

        IPv6Filter = *

        EnableCompatibilityHttpListener = false

        EnableCompatibilityHttpsListener = false

        CertificateThumbprint

    Winrs

        AllowRemoteShellAccess = true

        IdleTimeout = 180000

        MaxConcurrentUsers = 5

        MaxShellRunTime = 2147483647

        MaxProcessesPerShell = 15

        MaxMemoryPerShellMB = 150

        MaxShellsPerUser = 5

 

 

Node from resources.xml

 

  <node name="ft-admin1"

    node-executor="overthere-winrm"

    description="TrimFleet FT Admin1"

    tags="Windows"

    hostname="ft-admin1"

    username="rundeck"

    osFamily="windows"

    osName="Windows">

    <attribute name="Business Unit" value="TrimFleet"/>

    <attribute name="Location" value="PHX1"/>

  </node>

 

 

From projects.properties

 

project.winrm-auth-type="basic"

project.winrm-protocol="http"

 

The port is open:

 

# telnet ft-admin1 5985

Trying 10.133.84.16...

Connected to ft-admin1.

Escape character is '^]'.

 

 

Debug output:

 

[overthere-winrm:ft-admin1] ConnectionOptions[  port --> 5985

      os --> WINDOWS

      username --> rundeck

      address --> ft-admin1

      winrmEnableHttps --> false

      winrmKerberosAddPortToSpn --> false

      connectionType --> WINRM_INTERNAL

      connectionTimeoutMillis --> 15000

      winrmKerberosUseHttpSpn --> false

      password --> ********

]

com.xebialabs.overthere.cifs.winrm.WinRmRuntimeIOException: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)

      at com.xebialabs.overthere.cifs.winrm.WinRmClient.doSendRequest(WinRmClient.java:425)

[overthere-winrm:ft-admin1] failed: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)

Failed: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)

[workflow] finishExecuteNodeStep(ft-admin1): NodeDispatch: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)

1: Workflow step finished, result: Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]

[workflow] Finish step: 1,NodeDispatch

[workflow] Finish execution:  rundeck-workflow-node-first: [Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}, Node failures: {ft-admin1=[WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}]

[Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}, Node failures: {ft-admin1=[WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}]

Execution failed: 14873: [Workflow step failures: {1=Dispatch failed on 1 nodes: [ft-admin1: WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}, Node failures: {ft-admin1=[WinRMProtocolError: Unexpected HTTP response on http://ft-admin1:5985/wsman:   (401)]}]

 


On Monday, May 18, 2015 at 3:19:14 PM UTC-4, Evelyn Dibben wrote:
...

Evelyn Dibben

unread,
May 20, 2015, 2:34:16 PM5/20/15
to rundeck...@googlegroups.com
Requested winrm config

C:\>winrm g winrm/config
Config
    MaxEnvelopeSizekb = 150
    MaxTimeoutms = 60000
    MaxBatchItems = 32000
    MaxProviderRequests = 4294967295
    Client
        NetworkDelayms = 5000
        URLPrefix = wsman
        AllowUnencrypted = true
        Auth
            Basic = true
            Digest = true
            Kerberos = true
            Negotiate = true
            Certificate = true
        DefaultPorts
            HTTP = 5985
            HTTPS = 5986
        TrustedHosts = *
    Service
        RootSDDL = O:NSG:BAD:P(A;;GA;;;BA)S:P(AU;FA;GA;;;WD)(AU;SA;GWGX;;;WD)
        MaxConcurrentOperations = 4294967295
        MaxConcurrentOperationsPerUser = 15
        EnumerationTimeoutms = 60000
        MaxConnections = 25
        MaxPacketRetrievalTimeSeconds = 120
        AllowUnencrypted = false
        Auth
            Basic = true
            Kerberos = true
            Negotiate = true
            Certificate = false
            CbtHardeningLevel = Relaxed
        DefaultPorts
            HTTP = 5985
            HTTPS = 5986
        IPv4Filter = *
        IPv6Filter = *
        EnableCompatibilityHttpListener = false
        EnableCompatibilityHttpsListener = false
        CertificateThumbprint
    Winrs
        AllowRemoteShellAccess = true
        IdleTimeout = 180000
        MaxConcurrentUsers = 5
        MaxShellRunTime = 2147483647
        MaxProcessesPerShell = 15
        MaxMemoryPerShellMB = 150
        MaxShellsPerUser = 5


On Monday, May 18, 2015 at 3:19:14 PM UTC-4, Evelyn Dibben wrote:
...

Greg Schueler

unread,
May 20, 2015, 4:06:59 PM5/20/15
to rundeck...@googlegroups.com
This shows the service is not allowing unencrypted requests:

On May 20, 2015, at 11:34 AM, Evelyn Dibben <evelyn...@trimble.com> wrote:

 AllowUnencrypted = false


Be sure to run this command: 

        winrm set winrm/config/service @{AllowUnencrypted="true"}

Evelyn Dibben

unread,
May 20, 2015, 4:15:32 PM5/20/15
to rundeck...@googlegroups.com
Have a virtual craft beer on me my friend!  That did the trick.  I had set AllowUnencrypted to true at the client level but not the service level.  

Woot!  

Александр Алешин

unread,
Apr 7, 2017, 12:02:43 PM4/7/17
to rundeck-discuss

Also there is a problem with winRm Timeout setting (=15 by default in a Project).
WinRm Config on Windows we generally have
   MaxTimeoutms = 60000 (in ms, 1 min)
but in Rundeck's Project the setting winrmTimeout = 15 by default and it's also in milliseconds!
Of course 15 ms is too short to get a response! set winrmTimeout = 30000 and enjoy your winrm plugin in Rundeck.
Reply all
Reply to author
Forward
0 new messages