winrm

Ansible create a zip file backup on windows host

笑着哭i 提交于 2019-12-11 04:36:53
问题 I want to zip the windows directory into zip file. archive function is not working. for windows I see win_unzip module, but I didn't find win_zip module. How do we take the backup of existing folder in windows? - name: Backup existing install folder to zip archive: path: - "{{ installdir }}" dest: "{{ stragedir }}\\{{ appname }}.zip" format: zip error: [WARNING]: FATAL ERROR DURING FILE TRANSFER: Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/ansible/plugins

Impossible to take a wget with winrm protocol

一笑奈何 提交于 2019-12-11 04:24:11
问题 I am using Rundeck. I'm tring to use a wget with the WinRM protocol, It works with a little item but when I try to download a big item (3Go) I have this error : com.xebialabs.overthere.cifs.winrm.WinRmRuntimeIOException : Unexpected HTTP response .. HTTP error 500. The problem is about a Winrm config ? Timeout configuration ? Log trace : [overthere-winrm:...] failed: WinRM Error: Unexpected HTTP response on http: http://...:5985/wsman: (500) 来源: https://stackoverflow.com/questions/40840196

“Access denied” on Remote winrm [closed]

陌路散爱 提交于 2019-12-10 03:22:37
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 5 years ago . I created a Windows VM on Windows Azure with winrm over SSL set. But, I can't connect it using a powershell script. When I'm running the following: ​Enter-PSSession -ConnectionUri https://myniceapp.cloudapp.net:5986 -Credential "hostname/username" -SessionOption (New-PSSessionOption -SkipCACheck -SkipCNCheck) I

ssl: auth method ssl requires a password

≡放荡痞女 提交于 2019-12-08 16:44:05
问题 While trying to connect to a windows VM through Ansible I get this issue: TASK [setup] ******************************************************************* <10.xx.xx.xx> ESTABLISH WINRM CONNECTION FOR USER: winad-admin on PORT 5986 TO 10.xx.xx.xx fatal: [10.xx.xx.xx]: UNREACHABLE! => {"changed": false, "msg": "ssl: auth method ssl requires a password", "unreachable": true} Inventory file : ---hosts--- [win_servers] 10.xx.xx.xx [nonprod1_ad_servers:vars] ansible_user=administrator ansible_pass

Error PSRemoting using Session and CredSSP

半城伤御伤魂 提交于 2019-12-07 10:31:21
问题 I use Windows 8.1 Enterprise 64 bit and Powershell 4.0. I want execute powershell remoting and using authentication CredSSP. I open Console Powershell, run as Administrator, and execute Enter-PSSession command to connect to remote computer. But I get error about connection. PS C:\Documents and Settings\kiquenet> Enter-PSSession -ComputerName DC -credential devrsg.com\Administrator Anyways, I test command from Windows XP and Windows 7, and connection is OK. PS C:\Documents and Settings

New-PSSession does not work locally

*爱你&永不变心* 提交于 2019-12-07 04:15:38
问题 I am trying to connect to the localhost using New-PSSession . I have Configured WinRM using winrm quickconfig Enabled PS Remoting Enable-PSRemoting Added Trusted Host Set-Item WSMan:\localhost\Client\TrustedHosts * -Force There is an inbound rule on 8173 port on firewall. Output of winrm : PS C:\> winrm get winrm/config/listener?Address=*+Transport=HTTP Listener Address = * Transport = HTTP Port = 8173 Hostname Enabled = true URLPrefix = wsman CertificateThumbprint Listening on = 127.0.0.1 I

Powershell SDDL modification

自作多情 提交于 2019-12-06 05:58:34
I am trying to allow remote access to server throught winrs. Somewhere on the internets, I find out that this will need modification of RootSDDL for winrm service, and the value of it could be fetched like this: (Get-Item WSMAN:\localhost\Service\RootSDDL).Value O:NSG:BAD:P(A;;GA;;;BA)(A;;GA;;;S-1-5-21-3231263931-1371906242-1889625497-1141)S:P(AU;FA;GA;;;WD)(AU;SA;GWGX;;;WD) Now, the question is the following: When I know SID of the user I want to allow remote access, how do I add to this SDDL ACE like (A;;GA;;;S-1-5-21-The-rest-of-my-user-SID) ? Is there any code snippets to parse SDDL into

How do I edit text remotely in Windows

非 Y 不嫁゛ 提交于 2019-12-06 02:31:31
问题 (Note, this question is also posted on technet) How can I remotely edit a text file in Windows? I am running and administering a number of Windows 7 workstations and Windows Server 2012 machines. I would like to be able to remotely edit text files on any of these machines. I can connect to any of these machines via psexec or powershell remoting. I can also connect via rdp, but for the workstations I would rather not kick the user off unless I absolutely have to. For example, we manage state

Error PSRemoting using Session and CredSSP

不问归期 提交于 2019-12-05 14:37:48
I use Windows 8.1 Enterprise 64 bit and Powershell 4.0. I want execute powershell remoting and using authentication CredSSP. I open Console Powershell, run as Administrator, and execute Enter-PSSession command to connect to remote computer. But I get error about connection. PS C:\Documents and Settings\kiquenet> Enter-PSSession -ComputerName DC -credential devrsg.com\Administrator Anyways, I test command from Windows XP and Windows 7, and connection is OK. PS C:\Documents and Settings\kiquenet> Enter-PSSession -ComputerName DC -credential devrsg.com\Administrator [dc]: PS C:\Users

New-PSSession does not work locally

*爱你&永不变心* 提交于 2019-12-05 11:34:39
I am trying to connect to the localhost using New-PSSession . I have Configured WinRM using winrm quickconfig Enabled PS Remoting Enable-PSRemoting Added Trusted Host Set-Item WSMan:\localhost\Client\TrustedHosts * -Force There is an inbound rule on 8173 port on firewall. Output of winrm : PS C:\> winrm get winrm/config/listener?Address=*+Transport=HTTP Listener Address = * Transport = HTTP Port = 8173 Hostname Enabled = true URLPrefix = wsman CertificateThumbprint Listening on = 127.0.0.1 I am trying to run the following command: New-PSSession -ConnectionUri http://localhost:8173/WSMAN but I