[ansible-project] Re: List of list and variables
thank you for all your replies. i changed the way i am organizing my file. now i do: my_files: - {path: '/data/ansible/testing1', name: 'test1.reg', ext: '.reg'} - {path: '/data/ansible/testing1', name: 'test1.lst', ext: '.lst'} so it is less readable but easier to access to a variable (item.path, item.name, ...). Le mercredi 29 juillet 2015 06:30:55 UTC+1, J Hawkesworth a écrit : > > That's a complicated structure, and you seem to be storing some redundant > information. > Just wondering if you can simplify the structure and use filters to derive > the ext from the name > See > http://docs.ansible.com/ansible/playbooks_filters.html#other-useful-filters > - there's a splitext filter which looks appropriate. > > Hope that helps, > > Jon > > On Thursday, July 23, 2015 at 9:36:10 AM UTC+1, Guillaume Querso wrote: >> >> i am not sure it is possible to do so, but i would like to have a list of >> list. it would look like this: >> >> my_files: >> path: /data/ansible/testing1/ >> - {name: 'test1.reg', ext: '.reg'} >> - {name: 'test1.lst', ext: '.lst'} >> - {name: 'test1.sql', ext: '.sql'} >> path: /data/ansible/testing2/ >> - {name: 'test2.reg', ext: '.reg'} >> - {name: 'test2.lst', ext: '.lst'} >> - {name: 'test2.xsl', ext: '.xsl'} >> >> and most important, how can i access to those vairables in a playbook? >> >> Note: i absolutely need to keep this kind of hierarchy with the path and >> then the files in this path. >> >> Thank you! >> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/1e24433a-e412-4267-8cc2-6c1917946a67%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: authorized_keys not looking in role 'files' directory for files
what i mean is that in your main playbook (the one which trigger the roles) you have the following: vars_files: - /path/to/your/file because my understanding of your problem is that you need to access to keys stored as jinja variables in the file right? Le jeudi 23 juillet 2015 14:32:50 UTC+1, james.m...@infinityworks.com a écrit : > > Sorry bit of a noob how would this solve the problem? From my > understanding authorized_keys 'key' takes either a string (of the key) or a > url to the key file. Wouldn't having it in vars_file just be specifying the > URL in a different place? > > Also this means I have to specify this at the host level not the role > level which in my current understanding reduces the re-usabiiity. > > I've seen a couple of bug reports that report similar problems but they > all end in "patch merged" and I'm definitely on the latest stable release > of ansible... > > Thanks > > On Thursday, 23 July 2015 14:18:19 UTC+1, Guillaume Querso wrote: >> >> authorized_key seems to look in ./ssh >> have you tried to import your file in vars_files? >> >> Le jeudi 23 juillet 2015 14:06:47 UTC+1, james.m...@infinityworks.com a >> écrit : >>> >>> Hi, >>> >>> I'm trying to add an ssh key to all my servers via the authorized_keys >>> command but it doesn't seem to look in the usual places (i.e the role >>> directory(s)). Here's my code >>> >>> - name: Install SSH keys >>> authorized_key: user=vagrant key="{{ item }}" >>> with_file: >>> - id_rsa.pub >>> >>> Enter code here... >>> >>> And my directory structure is: >>> >>> /-roles >>> /-- disco >>> / files >>> /- id_rsa.pub >>> / tasks >>> /- main.yml >>> /- disco.yml >>> >>> And the error on the terminal (with -): >>> >>> TASK: [disco | Install SSH keys] >>> ** >>> fatal: [default] => could not locate file in lookup: id_rsa.pub >>> >>> FATAL: all hosts have already failed -- aborting >>> >>> It seems that the authorized_keys does not look in the same folders as >>> 'copy', for example. >>> >>> Thanks >>> James >>> >> -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/199bec8d-f066-4185-87dd-d9ed92c8bc96%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: authorized_keys not looking in role 'files' directory for files
authorized_key seems to look in ./ssh have you tried to import your file in vars_files? Le jeudi 23 juillet 2015 14:06:47 UTC+1, james.m...@infinityworks.com a écrit : > > Hi, > > I'm trying to add an ssh key to all my servers via the authorized_keys > command but it doesn't seem to look in the usual places (i.e the role > directory(s)). Here's my code > > - name: Install SSH keys > authorized_key: user=vagrant key="{{ item }}" > with_file: > - id_rsa.pub > > Enter code here... > > And my directory structure is: > > /-roles > /-- disco > / files > /- id_rsa.pub > / tasks > /- main.yml > /- disco.yml > > And the error on the terminal (with -): > > TASK: [disco | Install SSH keys] > ** > fatal: [default] => could not locate file in lookup: id_rsa.pub > > FATAL: all hosts have already failed -- aborting > > It seems that the authorized_keys does not look in the same folders as > 'copy', for example. > > Thanks > James > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/71e934bf-1e32-4d32-8b32-1ed593d4057f%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] List of list and variables
i am not sure it is possible to do so, but i would like to have a list of list. it would look like this: my_files: path: /data/ansible/testing1/ - {name: 'test1.reg', ext: '.reg'} - {name: 'test1.lst', ext: '.lst'} - {name: 'test1.sql', ext: '.sql'} path: /data/ansible/testing2/ - {name: 'test2.reg', ext: '.reg'} - {name: 'test2.lst', ext: '.lst'} - {name: 'test2.xsl', ext: '.xsl'} and most important, how can i access to those vairables in a playbook? Note: i absolutely need to keep this kind of hierarchy with the path and then the files in this path. Thank you! -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/61c7d5bf-9906-497f-a680-273f52cc22bd%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
your inventory seems ok to me, what is your opinion tkuratomi? have you tried to name your inventory "hosts" and to store it at /etc/ansible ? so you will not have to make the -i thing when you want to run your playbook Le mercredi 22 juillet 2015 08:49:35 UTC+1, Юра Фролов a écrit : > > > вторник, 21 июля 2015 г., 16:12:48 UTC+3 пользователь Guillaume Querso > написал: >> >> As suggested by the documentation ( >> http://docs.ansible.com/ansible/intro_configuration.html#sudo-user ), i >> would say the remote. just to be clear, your remote is a Linux/Unix >> machine? double check your indentation in your playbook to be sure nothing >> is wrong here. >> can you try: ansible 10.95.46.117 -m ping >> >> Maybe consider to upgrade your ansible version (and your ubuntu) >> What i don't understand is that you have an error related to syntax while >> i can't find anything unusual.. >> > > My machine Linux on both side (Ubuntu 14.10). > c# ping 10.95.46.117 > PING 10.95.46.117 (10.95.46.117) 56(84) bytes of data. > 64 bytes from 10.95.46.117: icmp_seq=1 ttl=64 time=0.682 ms > 64 bytes from 10.95.46.117: icmp_seq=2 ttl=64 time=0.404 ms > ^C > --- 10.95.46.117 ping statistics --- > # ansible 10.95.46.117 -m ping > ERROR: Invalid ini entry: This - need more than 1 value to unpack > > > > I have standard repository for Ubuntu. I have latest version ansible. > # ansible --version > ansible 1.7.2 > # apt-cache showpkg ansible > Package: ansible > Versions: > 1.7.2+dfsg-1 > > > > Can you upload your actual inventory file somewhere for us to download and >> take a look? I've just tested and one way that error can happen is if >> there's trailing, non-ascii whitespace > > inventory file <https://sites.google.com/site/vrnunit/inventory> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/cfcb1f42-a268-49c8-b9e2-cc4397af6d9e%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
As suggested by the documentation ( http://docs.ansible.com/ansible/intro_configuration.html#sudo-user ), i would say the remote. just to be clear, your remote is a Linux/Unix machine? double check your indentation in your playbook to be sure nothing is wrong here. can you try: ansible 10.95.46.117 -m ping Maybe consider to upgrade your ansible version (and your ubuntu) What i don't understand is that you have an error related to syntax while i can't find anything unusual.. Le mardi 21 juillet 2015 13:48:07 UTC+1, Юра Фролов a écrit : > > > --- > - host:10.95.46.117 > sudo:True > sudo_user:user >task: >- name: install freeradius > apt:pkg=freeradius >- name: copy config > copy:src="/etc/ansible/roles/preconf/templates/freeradius" > dest="/etc/" > owner=root group=freeradius mode=0755 > notify: > - restart freeradius > > > sudo_user:user it is user remote PC or user local PC? > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/15b23e14-41e1-41c6-a282-b4cabe1e173b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
i would like to see the content of test_new.yml Le mardi 21 juillet 2015 11:16:38 UTC+1, Юра Фролов a écrit : > > >can you post a version of your playbook? can you ping the port you are > targeting? > ~# ansible-playbook --version > ansible-playbook 1.7.2 > # ping 10.95.46.117 > PING 10.95.46.117 (10.95.46.117) 56(84) bytes of data. > 64 bytes from 10.95.46.117: icmp_seq=1 ttl=64 time=0.949 ms > 64 bytes from 10.95.46.117: icmp_seq=2 ttl=64 time=0.453 ms > ^C > > Or you're interested in the content test_new.yml? > > >by the way, you should have [testserver:vars] and not [tesserver:vars] > Oh, of course, I made a typo. I've corrected the typo. Still getting the > error message > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/1b33a854-3449-408a-9d89-794a3a2b9ee4%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
can you post a version of your playbook? can you ping the port you are targeting? Le mardi 21 juillet 2015 09:04:09 UTC+1, Юра Фролов a écrit : > > And one more question. Of what value is said in the error message? > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/360b3c19-92dd-4f2b-a098-c76a4d425c2c%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
by the way, you should have [testserver:vars] and not [tesserver:vars] Le mardi 21 juillet 2015 10:12:29 UTC+1, Guillaume Querso a écrit : > > can you post a version of your playbook? can you ping the port you are > targeting? > > Le mardi 21 juillet 2015 09:04:09 UTC+1, Юра Фролов a écrit : >> >> And one more question. Of what value is said in the error message? >> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/fc86bb7d-2b87-4e27-baf4-0be61720340e%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Kerberos Unknown credential cache type
hi, apparently, we need to use python 2.7.6 (the newest) for kerberos to work, otherwise ansible doesn't try kerberos properly (you should have transport=kerberos in the verbose). my problem is the following: i try to ping my windows server but i have this message: GSSError: ((\'Unspecified GSS failure. Minor code may provide more information\', 851968), (\'Unknown credential cache type\', -1765328244))\n', 'stdout': ''} i have: windows server 2008 R2 with powershell 4 ansible 2.0.0 or ansible stable 1.9 (same message on both verisons) a valide ticket for the domain user thank you for your help! -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/468473d2-83ce-44fc-84f7-f092601753db%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: ERROR: Invalid ini entry
i can't see any value to ansible_ssh_user, if you haven't set one, you should do it. i don't think ansible_ssh_host is needed because it is already specified. then, you should set your password and the connection type: inventory file: [testserver] 10.95.46.117 [testserver:vars] ansible_ssh_port= ansible_connection=YourConnectionType (can be ssh or winrm) ansible_ssh_user=YourUserName ansible_ssh_pass=SuperSecretPassword123 then try running: ansible-playbook -i /etc/ansible/inventory /etc/ansible/roles/preconf/tasks/test_new.yml - hope that helps Le vendredi 17 juillet 2015 13:34:01 UTC+1, Юра Фролов a écrit : > > I first time configurating ansible. I use ansible-playbook 1.7.2, ubuntu > 14.10 (this last version ansible in my ububntu). I am configured playbook > and task, created inventory file. > I started ansible follow command > ansible-playbook -i /etc/ansible/inventory > /etc/ansible/roles/preconf/tasks/test_new.yml -v --list-hosts --list-tasks > > contents my inventory file > > [testserver] > > 10.95.46.117 ansible_ssh_port= ansible_ssh_host=10.95.46.117 > ansible_ssh_use > > and receipt error: > ERROR: Invalid ini entry: This - need more than 1 value to unpack > > In what my error? What i do wrong? > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/65483768-eaa9-41b0-9343-f38521a716d6%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: how to set up kerberos
hi, quick update for this topic: apparently, we need to use python 2.7.6 (the newest) otherwise ansible doesn't try kerberos properly (you should have transport=kerberos in the verbose). the problem is now the following: i try to ping my windows server but i have this message: GSSError: ((\'Unspecified GSS failure. Minor code may provide more information\', 851968), (\'Unknown credential cache type\', -1765328244))\n', 'stdout': ''} thank you for your help! Le jeudi 16 juillet 2015 16:54:58 UTC+1, Guillaume Querso a écrit : > > hi all! > > I am currently using ansible 1.9.2 on a RHEL 6 server. what I would like > is to connect to a windows 2008 R2 server via kerberos to be able to use > domain accounts. > >- What i did: creating a ticket on the linux server for the concerned >domain account. Synchronized the clocks. >- What it is not working: i have a: 401 unauthorized access when i try >to run a playbook. > > Do you know what i am missing? > Thanks for your help on this! > > Guillaume Q > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/f7b1ed71-d606-4ca1-bfdb-737534bbc091%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: how to set up kerberos
Pykerberos is installed on the server, i have already requested a ticket for the user and domain expected with the right syntax. The server is running powershell 4 and i have checked that the encryption for the ticket and the key is the same on both sides. what i can see on the eventvwr is that there is an "Unknown user name or bad password" while they are right.. do you have anything else in mind that could help? or just ideas to identify the problem? can it be a proxy/firewall issue? Le jeudi 16 juillet 2015 21:25:19 UTC+1, J Hawkesworth a écrit : > > Have you installed pykerberos? > > Also, use klist to check that the tgt ticket is for the user and domain > you expect. > > be aware that the domain name seems to need to be in upper case so > > kinit us...@my.domain.com > not > > kinit us...@my.domain.com > > Also, make sure you have patched windows server 2008 R2 - as per this > advice on http://docs.ansible.com/intro_windows.html#windows-system-prep > > "On Windows 7 and Server 2008 R2 machines, due to a bug in Windows > Management Framework 3.0, it may be necessary to install this hotfix > http://support.microsoft.com/kb/2842230 to avoid receiving out of memory > and stack overflow exceptions. Newly-installed Server 2008 R2 systems which > are not fully up to date with windows updates are known to have this issue." > > I recommend running your ansible-playbook -v to see the connection > debugging information if it still fails. > Also running eventvwr on the windows machine and checking if there are any > logon events in Windows Logs -> Security > > Hope this helps. > > If you discover anything that helps please reply so we can provide more > information in the documentation. > > Jon > > > On Thursday, July 16, 2015 at 4:54:58 PM UTC+1, Guillaume Querso wrote: >> >> hi all! >> >> I am currently using ansible 1.9.2 on a RHEL 6 server. what I would like >> is to connect to a windows 2008 R2 server via kerberos to be able to use >> domain accounts. >> >>- What i did: creating a ticket on the linux server for the concerned >>domain account. Synchronized the clocks. >>- What it is not working: i have a: 401 unauthorized access when i >>try to run a playbook. >> >> Do you know what i am missing? >> Thanks for your help on this! >> >> Guillaume Q >> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/11b06148-fecb-4925-b9b1-e6a93c275e3d%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] how to set up kerberos
hi all! I am currently using ansible 1.9.2 on a RHEL 6 server. what I would like is to connect to a windows 2008 R2 server via kerberos to be able to use domain accounts. - What i did: creating a ticket on the linux server for the concerned domain account. Synchronized the clocks. - What it is not working: i have a: 401 unauthorized access when i try to run a playbook. Do you know what i am missing? Thanks for your help on this! Guillaume Q -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/38f7125f-0d55-42be-b964-03b948075e4b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: win_unzip hanging
hi jon, unfortunately, nothing works to solve the problem... is there anything new on the domain access? because it would make things a lot easier for me (and the windows community)!!! Thanks Le mercredi 15 juillet 2015 14:53:36 UTC+1, J Hawkesworth a écrit : > > Hi Guillaume, > > A few things you could try. > > Run with -v to see if the module is being run. > > 2/ set > ANSIBLE_KEEP_REMOTE_FILES=1 on your controller before running your > playbook. > > This will then not delete the powershell scripts so you can log into the > affected machine and run them directly in powershell > > 3/ check event log for errors. > > Hopefully you can find out what the problem is using the above. > > Jon > > On Wednesday, July 15, 2015 at 12:24:53 PM UTC+1, Guillaume Querso wrote: >> >> hi all, >> >> I am using ansible to unzip files on a windows 2008 R2 server. My >> playbook was working fine but for an unknown reason, the win_unzip module >> is now never ending. i am running ansible 1.9.2. >> Thank you for your help!! >> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/624c0525-8486-48d4-af6b-7592515eeb54%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] win_unzip hanging
hi all, I am using ansible to unzip files on a windows 2008 R2 server. My playbook was working fine but for an unknown reason, the win_unzip module is now never ending. i am running ansible 1.9.2. Thank you for your help!! -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/9ae9e225-dabd-41ed-87d8-70e36ddacbfe%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: Trouble with Windows modules
have you tried to downgrade to stable version 1.9.2? i also had troubles with ansible's modules on version 2.0 Le samedi 11 juillet 2015 01:39:27 UTC+1, anthony pangan a écrit : > > Hi all, > > I'm a complete no0b with Ansible, so sorry if I'm overlooking anything > obvious. It seems that arguments I'm sending to Windows modules are not > being acknowledged. With win_chocolatey, I'm getting a "missing required > arguments: name" error. Similarly this occurs with win_msi, but with the > path argument. Running win_ping returns successfully, so I am able to > execute remote commands on the client via Ansible. > > $ ansible windows - -i production -m win_chocolatey -a name=atom >> Using as config file >> ESTABLISH WINRM CONNECTION FOR USER: win_user on PORT 5986 >> TO win_client >> EXEC (New-Item -Type Directory -Path $env:temp -Name >> "ansible-tmp-1436569974.94-109882179190252").FullName | Write-Host >> -Separator ''; >> PUT /tmp/tmp0a8PHo TO >> C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436569974.94-109882179190252\\win_chocolatey >> EXEC PowerShell -NoProfile -NonInteractive -ExecutionPolicy >> Unrestricted -File >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436569974.94-109882179190252\\win_chocolatey.ps1"; >> >> Remove-Item >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436569974.94-109882179190252\" >> >> -Force -Recurse; >> win_client | FAILED! => {u'msg': u'missing required argument: name', >> u'failed': True, u'changed': False, u'invocation': {u'module_name': >> u'win_chocolatey', u'module_args': {u'name': u'atom'}}} > > >> $ ansible windows -vvv -i production -m win_msi -a >> path=C:\\Temp\\some_msi.msi >> Using as config file >> ESTABLISH WINRM CONNECTION FOR USER: win_user on PORT 5986 >> TO win_client >> EXEC (New-Item -Type Directory -Path $env:temp -Name >> "ansible-tmp-1436570331.32-112559327157120").FullName | Write-Host >> -Separator ''; >> PUT /tmp/tmpypj083 TO >> C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570331.32-112559327157120\\win_msi >> EXEC PowerShell -NoProfile -NonInteractive -ExecutionPolicy >> Unrestricted -File >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570331.32-112559327157120\\win_msi.ps1"; >> >> Remove-Item >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570331.32-112559327157120\" >> >> -Force -Recurse; >> win_client | FAILED! => {u'msg': u'missing required arguments: path', >> u'failed': True, u'changed': False, u'invocation': {u'module_name': >> u'win_msi', u'module_args': {u'path': u'C:\\Temp\\some_msi.msi'}}} >> >> ansible windows -vvv -i production -m win_ping >> Using as config file >> ESTABLISH WINRM CONNECTION FOR USER: win_user on PORT 5986 >> TO win_client >> EXEC (New-Item -Type Directory -Path $env:temp -Name >> "ansible-tmp-1436570360.66-113839788381177").FullName | Write-Host >> -Separator ''; >> PUT /tmp/tmp73P19o TO >> C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570360.66-113839788381177\\win_ping >> EXEC PowerShell -NoProfile -NonInteractive -ExecutionPolicy >> Unrestricted -File >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570360.66-113839788381177\\win_ping.ps1"; >> >> Remove-Item >> "C:\Users\win_user\AppData\Local\Temp\ansible-tmp-1436570360.66-113839788381177\" >> >> -Force -Recurse; >> win_client | SUCCESS => { >> "invocation": { >> "module_name": "win_ping", >> "module_args": {} >> }, >> "changed": false, >> "ping": "pong" >> } > > > ansible --version > ansible 2.0.0 (devel a9712bb0fb) last updated 2015/07/09 15:18:10 (GMT > -700) > lib/ansible/modules/core: (detached HEAD 8257053756) last updated > 2015/07/09 15:18:15 (GMT -700) > lib/ansible/modules/extras: (detached HEAD 639902ff20) last updated > 2015/07/09 15:18:20 (GMT -700) > v1/ansible/modules/core: (detached HEAD f8d8af17cd) last updated > 2015/07/09 15:18:24 (GMT -700) > v1/ansible/modules/extras: (detached HEAD 495ad450e5) last updated > 2015/07/09 15:18:29 (GMT -700) > configured module search path = None > > Controller: CentOS 6.6 > Windows Host: Windows 7 SP1 > > Thanks in advanced! > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/28ca6902-30f3-45ff-951d-94f1e43ab3a0%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: connection with windows
i have the following files: /etc/ansible/hosts [windows] WIN-F5631IBP8HG ansible_connection=winrm ansible_ssh_user=AnsibleUser ansible_ssh_pass=ansiblepass ansible_ssh_port=5986 etc/ansible/winplaybook.yml - name: Run powershell script hosts: windows gather_facts: false connection: winrm tasks: - name: Run powershell script script: C:/Users/AnsibleUser/Desktop/helloworld.ps1 the ping is working perfectly (thanks to powershell 4) and i have the following message: ansible-playbook /etc/ansible/winplaybook.yml -i windows, - PLAY [Run powershell script] ** TASK: [Run powershell script] * ESTABLISH WINRM CONNECTION FOR USER: guillaume on PORT 5986 TO windows WINRM CONNECT: transport=plaintext endpoint=https://windows:5986/wsman WINRM CONNECTION ERROR: 500 WinRMTransport. [Errno 111] Connection refused fatal: [windows] => 500 WinRMTransport. [Errno 111] Connection refused FATAL: all hosts have already failed -- aborting PLAY RECAP to retry, use: --limit @/home/guillaume/winplaybook.retry windows: ok=0changed=0unreachable=1failed=0 Le mardi 23 juin 2015 12:30:42 UTC+1, J Hawkesworth a écrit : > > Running windows as a vm should not in itself be a problem. > > What error are you getting now? > > > On Tuesday, June 23, 2015 at 10:37:34 AM UTC+1, Guillaume Querso wrote: >> >> not sure if this can help you but i am running windows locally as a vm. >> >> Le mardi 23 juin 2015 10:36:07 UTC+1, Guillaume Querso a écrit : >>> >>> i have powershell 4 now, but it is still not working porperly. it seems >>> that ansible cannot find my windows.yml file. even if is set those >>> variables in my hosts file, it doesn't work. >>> >>> Le mardi 23 juin 2015 10:05:14 UTC+1, J Hawkesworth a écrit : >>>> >>>> Maybe try different web browser to download the hotfix? >>>> You either need the hotfix or Windows Management Framework 4.0 as far >>>> as I can tell. >>>> Jon >>>> >>>> On Tuesday, June 23, 2015 at 9:54:31 AM UTC+1, Guillaume Querso wrote: >>>>> >>>>> thank you for your answer, indeed it is not a windows package but >>>>> sadly it didn't solved my problem... >>>>> >>>>> Le mardi 23 juin 2015 00:48:03 UTC+1, Trond Hindenes a écrit : >>>>>> >>>>>> On a side note: To me it looks like you're trying to use the >>>>>> "unarchive" module on a windows node. That won't work. You need to use a >>>>>> module listed in "Windows modules": >>>>>> http://docs.ansible.com/list_of_windows_modules.html >>>>>> >>>>>> On Monday, June 22, 2015 at 5:22:50 PM UTC+2, J Hawkesworth wrote: >>>>>>> >>>>>>> It is a bug in windows management framework which incorrectly sets >>>>>>> the amount of memory available to processes connected via winrm - its >>>>>>> really outside Ansible's domain. >>>>>>> >>>>>>> If you can't install the hotfix another way to get round it is to >>>>>>> install windows managment framework 4, which doesn't have this >>>>>>> particular >>>>>>> bug (and has the advantage of giving you powershell 4.0 which has a >>>>>>> number >>>>>>> of useful extra features over powershell 3.0). >>>>>>> >>>>>>> Hope this helps >>>>>>> >>>>>>> Jon >>>>>>> >>>>>>> On Monday, June 22, 2015 at 3:17:29 PM UTC+1, Guillaume Querso wrote: >>>>>>>> >>>>>>>> i can't install the hotfix, i am stuck on the terms ans conditions >>>>>>>> page. >>>>>>>> is this bug related to ansible-playbook because i can make a ping >>>>>>>> but not run my playbook? >>>>>>>> >>>>>>>> Le lundi 22 juin 2015 14:50:22 UTC+1, J Hawkesworth a écrit : >>>>>>>>> >>>>>>>>> Looks like you have hit the windows management framework 3.0 bug >>>>>>>>> described in the blue box here: >>>>>>>>> >>>>>>>>> http://do
[ansible-project] Re: connection with windows
not sure if this can help you but i am running windows locally as a vm. Le mardi 23 juin 2015 10:36:07 UTC+1, Guillaume Querso a écrit : > > i have powershell 4 now, but it is still not working porperly. it seems > that ansible cannot find my windows.yml file. even if is set those > variables in my hosts file, it doesn't work. > > Le mardi 23 juin 2015 10:05:14 UTC+1, J Hawkesworth a écrit : >> >> Maybe try different web browser to download the hotfix? >> You either need the hotfix or Windows Management Framework 4.0 as far as >> I can tell. >> Jon >> >> On Tuesday, June 23, 2015 at 9:54:31 AM UTC+1, Guillaume Querso wrote: >>> >>> thank you for your answer, indeed it is not a windows package but sadly >>> it didn't solved my problem... >>> >>> Le mardi 23 juin 2015 00:48:03 UTC+1, Trond Hindenes a écrit : >>>> >>>> On a side note: To me it looks like you're trying to use the >>>> "unarchive" module on a windows node. That won't work. You need to use a >>>> module listed in "Windows modules": >>>> http://docs.ansible.com/list_of_windows_modules.html >>>> >>>> On Monday, June 22, 2015 at 5:22:50 PM UTC+2, J Hawkesworth wrote: >>>>> >>>>> It is a bug in windows management framework which incorrectly sets the >>>>> amount of memory available to processes connected via winrm - its really >>>>> outside Ansible's domain. >>>>> >>>>> If you can't install the hotfix another way to get round it is to >>>>> install windows managment framework 4, which doesn't have this particular >>>>> bug (and has the advantage of giving you powershell 4.0 which has a >>>>> number >>>>> of useful extra features over powershell 3.0). >>>>> >>>>> Hope this helps >>>>> >>>>> Jon >>>>> >>>>> On Monday, June 22, 2015 at 3:17:29 PM UTC+1, Guillaume Querso wrote: >>>>>> >>>>>> i can't install the hotfix, i am stuck on the terms ans conditions >>>>>> page. >>>>>> is this bug related to ansible-playbook because i can make a ping but >>>>>> not run my playbook? >>>>>> >>>>>> Le lundi 22 juin 2015 14:50:22 UTC+1, J Hawkesworth a écrit : >>>>>>> >>>>>>> Looks like you have hit the windows management framework 3.0 bug >>>>>>> described in the blue box here: >>>>>>> >>>>>>> http://docs.ansible.com/intro_windows.html#windows-system-prep >>>>>>> >>>>>>> Since win_ping is working for you now, you just need to install the >>>>>>> hotfix to get up and running: >>>>>>> >>>>>>> http://support.microsoft.com/kb/2842230 >>>>>>> >>>>>>> Jon >>>>>>> >>>>>>> On Monday, June 22, 2015 at 1:56:30 PM UTC+1, Guillaume Querso wrote: >>>>>>>> >>>>>>>> i have done this as said in my edit but it is not working for the >>>>>>>> playbook. do i have anything else to do to make it run properly? >>>>>>>> >>>>>>>> Le lundi 22 juin 2015 13:48:43 UTC+1, J Hawkesworth a écrit : >>>>>>>>> >>>>>>>>> Looks like you just need to add your server into a group called >>>>>>>>> windows - the example here shows the group >>>>>>>>> http://docs.ansible.com/intro_windows.html#inventory >>>>>>>>> >>>>>>>>> So your inventory file needs to look like this: >>>>>>>>> >>>>>>>>> [windows] >>>>>>>>> WIN-F6531IBP8HG >>>>>>>>> >>>>>>>>> The group vars will then take effect for your host and ansible >>>>>>>>> will know to connect via winrm instead of ssh, which it is trying at >>>>>>>>> the >>>>>>>>> moment (which isn't going to work as Windows doesn't understand SSH). >>>>>>>>> >>>>>>>>> Hope this helps, >>>>>>>>> >>>>>>>>> Jon >>>>>>>>>
[ansible-project] Re: connection with windows
i have powershell 4 now, but it is still not working porperly. it seems that ansible cannot find my windows.yml file. even if is set those variables in my hosts file, it doesn't work. Le mardi 23 juin 2015 10:05:14 UTC+1, J Hawkesworth a écrit : > > Maybe try different web browser to download the hotfix? > You either need the hotfix or Windows Management Framework 4.0 as far as I > can tell. > Jon > > On Tuesday, June 23, 2015 at 9:54:31 AM UTC+1, Guillaume Querso wrote: >> >> thank you for your answer, indeed it is not a windows package but sadly >> it didn't solved my problem... >> >> Le mardi 23 juin 2015 00:48:03 UTC+1, Trond Hindenes a écrit : >>> >>> On a side note: To me it looks like you're trying to use the "unarchive" >>> module on a windows node. That won't work. You need to use a module listed >>> in "Windows modules": >>> http://docs.ansible.com/list_of_windows_modules.html >>> >>> On Monday, June 22, 2015 at 5:22:50 PM UTC+2, J Hawkesworth wrote: >>>> >>>> It is a bug in windows management framework which incorrectly sets the >>>> amount of memory available to processes connected via winrm - its really >>>> outside Ansible's domain. >>>> >>>> If you can't install the hotfix another way to get round it is to >>>> install windows managment framework 4, which doesn't have this particular >>>> bug (and has the advantage of giving you powershell 4.0 which has a number >>>> of useful extra features over powershell 3.0). >>>> >>>> Hope this helps >>>> >>>> Jon >>>> >>>> On Monday, June 22, 2015 at 3:17:29 PM UTC+1, Guillaume Querso wrote: >>>>> >>>>> i can't install the hotfix, i am stuck on the terms ans conditions >>>>> page. >>>>> is this bug related to ansible-playbook because i can make a ping but >>>>> not run my playbook? >>>>> >>>>> Le lundi 22 juin 2015 14:50:22 UTC+1, J Hawkesworth a écrit : >>>>>> >>>>>> Looks like you have hit the windows management framework 3.0 bug >>>>>> described in the blue box here: >>>>>> >>>>>> http://docs.ansible.com/intro_windows.html#windows-system-prep >>>>>> >>>>>> Since win_ping is working for you now, you just need to install the >>>>>> hotfix to get up and running: >>>>>> >>>>>> http://support.microsoft.com/kb/2842230 >>>>>> >>>>>> Jon >>>>>> >>>>>> On Monday, June 22, 2015 at 1:56:30 PM UTC+1, Guillaume Querso wrote: >>>>>>> >>>>>>> i have done this as said in my edit but it is not working for the >>>>>>> playbook. do i have anything else to do to make it run properly? >>>>>>> >>>>>>> Le lundi 22 juin 2015 13:48:43 UTC+1, J Hawkesworth a écrit : >>>>>>>> >>>>>>>> Looks like you just need to add your server into a group called >>>>>>>> windows - the example here shows the group >>>>>>>> http://docs.ansible.com/intro_windows.html#inventory >>>>>>>> >>>>>>>> So your inventory file needs to look like this: >>>>>>>> >>>>>>>> [windows] >>>>>>>> WIN-F6531IBP8HG >>>>>>>> >>>>>>>> The group vars will then take effect for your host and ansible will >>>>>>>> know to connect via winrm instead of ssh, which it is trying at the >>>>>>>> moment >>>>>>>> (which isn't going to work as Windows doesn't understand SSH). >>>>>>>> >>>>>>>> Hope this helps, >>>>>>>> >>>>>>>> Jon >>>>>>>> >>>>>>>> On Monday, June 22, 2015 at 12:46:56 PM UTC+1, Guillaume Querso >>>>>>>> wrote: >>>>>>>>> >>>>>>>>> Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my >>>>>>>>> remote machine is a windows 7 sp1. >>>>>>>>> i have the following files and error message, i don't understand >>>>&g
[ansible-project] Re: connection with windows
thank you for your answer, indeed it is not a windows package but sadly it didn't solved my problem... Le mardi 23 juin 2015 00:48:03 UTC+1, Trond Hindenes a écrit : > > On a side note: To me it looks like you're trying to use the "unarchive" > module on a windows node. That won't work. You need to use a module listed > in "Windows modules": http://docs.ansible.com/list_of_windows_modules.html > > On Monday, June 22, 2015 at 5:22:50 PM UTC+2, J Hawkesworth wrote: >> >> It is a bug in windows management framework which incorrectly sets the >> amount of memory available to processes connected via winrm - its really >> outside Ansible's domain. >> >> If you can't install the hotfix another way to get round it is to install >> windows managment framework 4, which doesn't have this particular bug (and >> has the advantage of giving you powershell 4.0 which has a number of useful >> extra features over powershell 3.0). >> >> Hope this helps >> >> Jon >> >> On Monday, June 22, 2015 at 3:17:29 PM UTC+1, Guillaume Querso wrote: >>> >>> i can't install the hotfix, i am stuck on the terms ans conditions >>> page. >>> is this bug related to ansible-playbook because i can make a ping but >>> not run my playbook? >>> >>> Le lundi 22 juin 2015 14:50:22 UTC+1, J Hawkesworth a écrit : >>>> >>>> Looks like you have hit the windows management framework 3.0 bug >>>> described in the blue box here: >>>> >>>> http://docs.ansible.com/intro_windows.html#windows-system-prep >>>> >>>> Since win_ping is working for you now, you just need to install the >>>> hotfix to get up and running: >>>> >>>> http://support.microsoft.com/kb/2842230 >>>> >>>> Jon >>>> >>>> On Monday, June 22, 2015 at 1:56:30 PM UTC+1, Guillaume Querso wrote: >>>>> >>>>> i have done this as said in my edit but it is not working for the >>>>> playbook. do i have anything else to do to make it run properly? >>>>> >>>>> Le lundi 22 juin 2015 13:48:43 UTC+1, J Hawkesworth a écrit : >>>>>> >>>>>> Looks like you just need to add your server into a group called >>>>>> windows - the example here shows the group >>>>>> http://docs.ansible.com/intro_windows.html#inventory >>>>>> >>>>>> So your inventory file needs to look like this: >>>>>> >>>>>> [windows] >>>>>> WIN-F6531IBP8HG >>>>>> >>>>>> The group vars will then take effect for your host and ansible will >>>>>> know to connect via winrm instead of ssh, which it is trying at the >>>>>> moment >>>>>> (which isn't going to work as Windows doesn't understand SSH). >>>>>> >>>>>> Hope this helps, >>>>>> >>>>>> Jon >>>>>> >>>>>> On Monday, June 22, 2015 at 12:46:56 PM UTC+1, Guillaume Querso wrote: >>>>>>> >>>>>>> Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my >>>>>>> remote machine is a windows 7 sp1. >>>>>>> i have the following files and error message, i don't understand >>>>>>> where the issue is.. >>>>>>> >>>>>>> /etc/ansible/group_vars/windows.yml >>>>>>> >>>>>>> ansible_ssh_user: AnsibleUser >>>>>>> ansible_ssh_pass: ansiblepass >>>>>>> ansible_ssh_port: 5986 >>>>>>> ansible_connection: winrm >>>>>>> >>>>>>> /etc/ansible/winplaybook.yml >>>>>>> >>>>>>>- hosts: WIN-F6531IBP8HG tasks: >>>>>>> - name: unarchive unarchive: src=/tmp/hello.txt.zip >>>>>>> dest=C:\Users\Querso\Desktop >>>>>>> >>>>>>> /etc/ansible/hosts >>>>>>> >>>>>>> WIN-F6531IBP8HG >>>>>>> >>>>>>> i have python 2.7.6 and i have the following error message: >>>>>>> ansible-playbook /etc/ansible/winplaybook.yml -i WIN-F6531IBP8HG, >>>>>>> >>>>>>> PLAY [WIN-F6531IBP8HG] >>>>>>&g
[ansible-project] Re: connection with windows
i can't install the hotfix, i am stuck on the terms ans conditions page. is this bug related to ansible-playbook because i can make a ping but not run my playbook? Le lundi 22 juin 2015 14:50:22 UTC+1, J Hawkesworth a écrit : > > Looks like you have hit the windows management framework 3.0 bug described > in the blue box here: > > http://docs.ansible.com/intro_windows.html#windows-system-prep > > Since win_ping is working for you now, you just need to install the hotfix > to get up and running: > > http://support.microsoft.com/kb/2842230 > > Jon > > On Monday, June 22, 2015 at 1:56:30 PM UTC+1, Guillaume Querso wrote: >> >> i have done this as said in my edit but it is not working for the >> playbook. do i have anything else to do to make it run properly? >> >> Le lundi 22 juin 2015 13:48:43 UTC+1, J Hawkesworth a écrit : >>> >>> Looks like you just need to add your server into a group called windows >>> - the example here shows the group >>> http://docs.ansible.com/intro_windows.html#inventory >>> >>> So your inventory file needs to look like this: >>> >>> [windows] >>> WIN-F6531IBP8HG >>> >>> The group vars will then take effect for your host and ansible will know >>> to connect via winrm instead of ssh, which it is trying at the moment >>> (which isn't going to work as Windows doesn't understand SSH). >>> >>> Hope this helps, >>> >>> Jon >>> >>> On Monday, June 22, 2015 at 12:46:56 PM UTC+1, Guillaume Querso wrote: >>>> >>>> Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my remote >>>> machine is a windows 7 sp1. >>>> i have the following files and error message, i don't understand where >>>> the issue is.. >>>> >>>> /etc/ansible/group_vars/windows.yml >>>> >>>> ansible_ssh_user: AnsibleUser >>>> ansible_ssh_pass: ansiblepass >>>> ansible_ssh_port: 5986 >>>> ansible_connection: winrm >>>> >>>> /etc/ansible/winplaybook.yml >>>> >>>>- hosts: WIN-F6531IBP8HG tasks: >>>> - name: unarchive unarchive: src=/tmp/hello.txt.zip >>>> dest=C:\Users\Querso\Desktop >>>> >>>> /etc/ansible/hosts >>>> >>>> WIN-F6531IBP8HG >>>> >>>> i have python 2.7.6 and i have the following error message: >>>> ansible-playbook /etc/ansible/winplaybook.yml -i WIN-F6531IBP8HG, >>>> >>>> PLAY [WIN-F6531IBP8HG] >>>> >>>> >>>> GATHERING FACTS >>>> *** >>>> fatal: [WIN-F6531IBP8HG] => SSH Error: Permission denied >>>> (publickey,password,keyboard-interactive). >>>> while connecting to 192.168.79.133:22 >>>> It is sometimes useful to re-run the command using -, which prints >>>> SSH debug output to help diagnose the issue. >>>> >>>> TASK: [unarchive] >>>> * >>>> FATAL: no hosts matched or all hosts have already failed -- aborting >>>> >>>> PLAY RECAP >>>> >>>> to retry, use: --limit @/home/guillaume/winplaybook.retry >>>> >>>> WIN-F6531IBP8HG : ok=0 changed=0 unreachable=1 failed=0 >>>> >>>> if i try to ping windows: >>>> ansible WIN-F6531IBP8HG -m win_ping >>>> WIN-F6531IBP8HG | FAILED => SSH Error: Permission denied >>>> (publickey,password,keyboard-interactive). >>>> while connecting to 192.168.79.133:22 >>>> It is sometimes useful to re-run the command using -, which prints >>>> SSH debug output to help diagnose the issue. >>>> >>>> thanks for your help!! >>>> >>> -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/8f559c26-b3d2-48c5-934f-f4037615392e%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: connection with windows
i have done this as said in my edit but it is not working for the playbook. do i have anything else to do to make it run properly? Le lundi 22 juin 2015 13:48:43 UTC+1, J Hawkesworth a écrit : > > Looks like you just need to add your server into a group called windows - > the example here shows the group > http://docs.ansible.com/intro_windows.html#inventory > > So your inventory file needs to look like this: > > [windows] > WIN-F6531IBP8HG > > The group vars will then take effect for your host and ansible will know > to connect via winrm instead of ssh, which it is trying at the moment > (which isn't going to work as Windows doesn't understand SSH). > > Hope this helps, > > Jon > > On Monday, June 22, 2015 at 12:46:56 PM UTC+1, Guillaume Querso wrote: >> >> Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my remote >> machine is a windows 7 sp1. >> i have the following files and error message, i don't understand where >> the issue is.. >> >> /etc/ansible/group_vars/windows.yml >> >> ansible_ssh_user: AnsibleUser >> ansible_ssh_pass: ansiblepass >> ansible_ssh_port: 5986 >> ansible_connection: winrm >> >> /etc/ansible/winplaybook.yml >> >>- hosts: WIN-F6531IBP8HG tasks: >> - name: unarchive unarchive: src=/tmp/hello.txt.zip >> dest=C:\Users\Querso\Desktop >> >> /etc/ansible/hosts >> >> WIN-F6531IBP8HG >> >> i have python 2.7.6 and i have the following error message: >> ansible-playbook /etc/ansible/winplaybook.yml -i WIN-F6531IBP8HG, >> >> PLAY [WIN-F6531IBP8HG] >> >> >> GATHERING FACTS >> *** >> fatal: [WIN-F6531IBP8HG] => SSH Error: Permission denied >> (publickey,password,keyboard-interactive). >> while connecting to 192.168.79.133:22 >> It is sometimes useful to re-run the command using -, which prints >> SSH debug output to help diagnose the issue. >> >> TASK: [unarchive] >> * >> FATAL: no hosts matched or all hosts have already failed -- aborting >> >> PLAY RECAP >> >> to retry, use: --limit @/home/guillaume/winplaybook.retry >> >> WIN-F6531IBP8HG : ok=0 changed=0 unreachable=1 failed=0 >> >> if i try to ping windows: >> ansible WIN-F6531IBP8HG -m win_ping >> WIN-F6531IBP8HG | FAILED => SSH Error: Permission denied >> (publickey,password,keyboard-interactive). >> while connecting to 192.168.79.133:22 >> It is sometimes useful to re-run the command using -, which prints >> SSH debug output to help diagnose the issue. >> >> thanks for your help!! >> > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/ff781b99-5626-4d46-8cd7-8c96be53567d%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] Re: connection with windows
EDIT: my files are now /etc/ansible/group_vars/windows/windows.yml ansible_ssh_user: AnsibleUser ansible_ssh_pass: ansiblepass ansible_ssh_port: 5986 ansible_connection: winrm /etc/ansible/hosts [windows] WIN-F6531IBP8NG the ping is working but sometimes it fails with this message: WIN-F6531IBP8HG | FAILED >> { "failed": true, "msg": "\nProcess is terminated due to StackOverflowException.\n", "parsed": false } or this one: WIN-F6531IBP8HG | FAILED >> { "failed": true, "msg": "", "parsed": false } but when i run the playbook, it still tries to connect via ssh and not winrm so it doesn't seem to see my windows.yml file but i don't know how to deal with this issue Le lundi 22 juin 2015 12:46:56 UTC+1, Guillaume Querso a écrit : > > Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my remote > machine is a windows 7 sp1. > i have the following files and error message, i don't understand where the > issue is.. > > /etc/ansible/group_vars/windows.yml > > ansible_ssh_user: AnsibleUser > ansible_ssh_pass: ansiblepass > ansible_ssh_port: 5986 > ansible_connection: winrm > > /etc/ansible/winplaybook.yml > >- hosts: WIN-F6531IBP8HG tasks: > - name: unarchive unarchive: src=/tmp/hello.txt.zip > dest=C:\Users\Querso\Desktop > > /etc/ansible/hosts > > WIN-F6531IBP8HG > > i have python 2.7.6 and i have the following error message: > ansible-playbook /etc/ansible/winplaybook.yml -i WIN-F6531IBP8HG, > > PLAY [WIN-F6531IBP8HG] > > > GATHERING FACTS > *** > fatal: [WIN-F6531IBP8HG] => SSH Error: Permission denied > (publickey,password,keyboard-interactive). > while connecting to 192.168.79.133:22 > It is sometimes useful to re-run the command using -, which prints SSH > debug output to help diagnose the issue. > > TASK: [unarchive] > * > FATAL: no hosts matched or all hosts have already failed -- aborting > > PLAY RECAP > > to retry, use: --limit @/home/guillaume/winplaybook.retry > > WIN-F6531IBP8HG : ok=0 changed=0 unreachable=1 failed=0 > > if i try to ping windows: > ansible WIN-F6531IBP8HG -m win_ping > WIN-F6531IBP8HG | FAILED => SSH Error: Permission denied > (publickey,password,keyboard-interactive). > while connecting to 192.168.79.133:22 > It is sometimes useful to re-run the command using -, which prints SSH > debug output to help diagnose the issue. > > thanks for your help!! > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/b1170549-b3fa-401d-b14f-d73485b12fc3%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[ansible-project] connection with windows
Hello, i am running ansible 1.9.1 on a Ubuntu server 14.04.2, my remote machine is a windows 7 sp1. i have the following files and error message, i don't understand where the issue is.. /etc/ansible/group_vars/windows.yml ansible_ssh_user: AnsibleUser ansible_ssh_pass: ansiblepass ansible_ssh_port: 5986 ansible_connection: winrm /etc/ansible/winplaybook.yml - hosts: WIN-F6531IBP8HG tasks: - name: unarchive unarchive: src=/tmp/hello.txt.zip dest=C:\Users\Querso\Desktop /etc/ansible/hosts WIN-F6531IBP8HG i have python 2.7.6 and i have the following error message: ansible-playbook /etc/ansible/winplaybook.yml -i WIN-F6531IBP8HG, PLAY [WIN-F6531IBP8HG] GATHERING FACTS *** fatal: [WIN-F6531IBP8HG] => SSH Error: Permission denied (publickey,password,keyboard-interactive). while connecting to 192.168.79.133:22 It is sometimes useful to re-run the command using -, which prints SSH debug output to help diagnose the issue. TASK: [unarchive] * FATAL: no hosts matched or all hosts have already failed -- aborting PLAY RECAP to retry, use: --limit @/home/guillaume/winplaybook.retry WIN-F6531IBP8HG : ok=0 changed=0 unreachable=1 failed=0 if i try to ping windows: ansible WIN-F6531IBP8HG -m win_ping WIN-F6531IBP8HG | FAILED => SSH Error: Permission denied (publickey,password,keyboard-interactive). while connecting to 192.168.79.133:22 It is sometimes useful to re-run the command using -, which prints SSH debug output to help diagnose the issue. thanks for your help!! -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to ansible-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/3630e85f-826e-4c9a-ba0b-0fdb4ae0307b%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.