[ansible-project] Re: connection with windows

2015-06-23 Thread J Hawkesworth
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:0

[ansible-project] Re: connection with windows

2015-06-23 Thread J Hawkesworth
*** > >to retry, use: --limit @/home/guillaume/winplaybook.retry > > > windows: ok=0changed=0unreachable=1 > failed=0 > > > > > Le mardi 23 juin 2015 12:30:42 UTC+1, J Hawkesworth a écrit : >> >> Running windo

[ansible-project] Re: Cannot run 1.9.2 -- ERROR: apt is not a legal parameter in an Ansible task or handler

2015-06-23 Thread J Hawkesworth
Did you run git submodule update Otherwise I guess the modules might not be available? Hope that helps, Jon On Tuesday, June 23, 2015 at 2:39:45 PM UTC+1, Barry Kaplan wrote: > > When I try to use 1.9.2-rc2 > > ansible❯ source ~/si/ansible/hacking/env-setup >

[ansible-project] Re: [WIN] Howto built custom Powershell module. Read docs, but not getting it.

2015-06-23 Thread J Hawkesworth
I have a custom library path defined in the [defaults] section in my /etc/ansible/ansible.cfg file, like this: library= /etc/ansible/library Not sure if this is required but I use a few custom modules which are in this folder. What ansible version are you using? On Tuesday, June 23, 2

Re: [ansible-project] playbook to install software on windows clients from linux control machine

2015-06-24 Thread J Hawkesworth
I think you are most likely to be successful if you set up a web server on your ansible controller and then use win_get_url to fetch and then run the .exe to install (or use win_package as suggested above as I believe this will retrieve from http and install). Bear in mind you will have almost

[ansible-project] Trouble with Windows modules

2015-07-11 Thread J Hawkesworth
Hi, Not sure what is going on here, but please can you try putting all the module arguments inside single quotes. So your command line would end -a 'name=atom state=present' Hope that helps. Jon -- You received this message because you are subscribed to the Google Groups "Ansible Proje

[ansible-project] Re: win_unzip hanging

2015-07-15 Thread J Hawkesworth
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 p

[ansible-project] Re: how to set up kerberos

2015-07-16 Thread J Hawkesworth
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 u...@my.domain.com not kinit u...@my.domain.com Also, make sure you have patched windows server 2008 R2 -

[ansible-project] Re: how to set up kerberos

2015-07-17 Thread J Hawkesworth
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 jeu

[ansible-project] Re: Kerberos Unknown credential cache type

2015-07-17 Thread J Hawkesworth
Can you share your /etc/krb5.conf? Is it possible you have KRB5CCNAME environment variable set specifying a non standard location for the kerberos credential cache? I think that would probably cause problems? Not sure if pykerberos expects a particular type of credential cache but fairly cert

[ansible-project] Re: Run Powershell script on remote

2015-07-22 Thread J Hawkesworth
You can use the 'raw' module to run a powershell script that is already on the remote machine (or any exe), and you can use the 'script' module to have ansible transfer the powershell script from your ansible controller to your managed host and then run the powershell script. If possible though

[ansible-project] Re: Installing IIS on Windows Server 2008 R2 Standard SP1 x64

2015-07-22 Thread J Hawkesworth
I have a couple of suggestions... First, check your server 2008 is patched as per the instructions in the blue box here: http://docs.ansible.com/ansible/intro_windows.html#windows-system-prep Check that your windows host actually has the features that you want to install available. Unfortunat

[ansible-project] Re: Installing IIS on Windows Server 2008 R2 Standard SP1 x64

2015-07-23 Thread J Hawkesworth
Also, what ansible version are you using and how was it installed? On Thursday, July 23, 2015 at 6:46:11 AM UTC+1, J Hawkesworth wrote: > > I have a couple of suggestions... > > First, check your server 2008 is patched as per the instructions in the > blue box here: > http:

[ansible-project] Re: Use IP in hosts as variables in roles

2015-07-28 Thread J Hawkesworth
Have a look at: http://docs.ansible.com/ansible/faq.html#how-do-i-loop-over-a-list-of-hosts-in-a-group-inside-of-a-template and http://docs.ansible.com/ansible/faq.html#how-do-i-access-a-variable-of-the-first-host-in-a-group I think this might get you pretty close to what you want. Jon On Monday

[ansible-project] Re: List of list and variables

2015-07-28 Thread J Hawkesworth
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 whi

[ansible-project] Re: List of list and variables

2015-07-29 Thread J Hawkesworth
s: > - {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.

[ansible-project] Re: azure required for this module error

2015-07-29 Thread J Hawkesworth
Looks like to use that module, you need to install a python library called 'azure'. Looking here http://docs.ansible.com/ansible/azure_module.html, it seems to need to be a version later than 0.7.1 This is probably something you can install using pip / yum / apt-get. Hope this helps. Jon On

[ansible-project] How are you using tags?

2015-07-30 Thread J Hawkesworth
We have built up quite a collection of playbooks during the time we've been using ansible and I'm looking for ways to consolidate them, just to keep them under control as we still have plenty more we want to add. I've not made use of tags yet but read up on it a bit and am thinking of organisin

[ansible-project] Re: Powershell script not completely executing...

2015-07-30 Thread J Hawkesworth
What ansible version are you using? If I recall we had a problem in the past with execution policy being set differently under some circumstances, which I speculate might be causing your problems. As a 'get-you-going' suggestion, you could try running the problematic commands (without the star

[ansible-project] Re: Powershell script not completely executing...

2015-07-31 Thread J Hawkesworth
>>>>> downloaded it a couple of days ago). >>>>> >>>>> >>>>> I've tried running the setup.exe and psconfig.exe without >>>>> Start-Process but within the .ps1 still, and that has the same problem. >>>>> >

[ansible-project] Re: vm_cdrom in vsphere_guest not working

2015-07-31 Thread J Hawkesworth
My guess would be its something to do with indentation in your playbook. I suggest you try editing your playbook in a yaml-aware editor. On windows you can use Notepad++ - or use yamlint.com Hope this helps, Jon On Friday, July 31, 2015 at 1:58:40 PM UTC+1, Timo wrote: > > Hi list, > > got

[ansible-project] Re: Serial across groups

2015-07-31 Thread J Hawkesworth
Not tried myself but I think you can set serial to a percentage - there are a couple of examples here: https://blog.serverdensity.com/what-ive-learnt-from-using-ansible-exclusively-for-2-years/ Hope this helps, Jon On Friday, July 31, 2015 at 1:41:15 PM UTC+1, David Edmonds wrote: > > Hi, > >

[ansible-project] Re: Powershell script not completely executing...

2015-07-31 Thread J Hawkesworth
rade): kerberos in > /usr/lib64/python2.6/site-packages > [root@centos65 ~]# > > > So why would I be getting the errors I posted in the earlier post now? > > Thanks, > Jim > > > > On Friday, July 31, 2015 at 9:13:06 AM UTC-4, J Hawkesworth wrote: >> >&g

[ansible-project] Re: vm_cdrom in vsphere_guest not working

2015-07-31 Thread J Hawkesworth
r where i >> put it.... >> >> Any other suggestions? >> >> Thx! >> >> >> On Friday, July 31, 2015 at 3:17:53 PM UTC+2, J Hawkesworth wrote: >>> >>> My guess would be its something to do with indentation in your playbook. >>&

Re: [ansible-project] Ansible quoting

2015-08-03 Thread J Hawkesworth
Worth trying current dev if you can as I think the way parameters are passed has changed. All the best, Jon -- 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 t

[ansible-project] Re: Connection problem with a windows machine since ansible

2015-08-12 Thread J Hawkesworth
UNKNOWN_PROTOCOL] > unknown protocol (_ssl.c:590) > > > On Friday, November 21, 2014 at 3:58:24 PM UTC+2, youmarva wrote: >> >> *Thanks* J Hawkesworth for your response >> >> >> >> >> >> >> >> >> >> >> &g

[ansible-project] pywinrm GSSError: No Kerberos credentials available

2015-08-13 Thread J Hawkesworth
I think you need to set up your ansible controller as a kerberos client. Your ansible box needs to know how to talk to your windows domain controllers. Assuming you have pykerberos installed, you probably already have the command line kerberos tools installed. I suggest you configure your /et

Re: [ansible-project] Windows integration

2015-08-14 Thread J Hawkesworth
I think you may need to change this setting in your ansible.cfg file to get the callback to take effect when using ansible http://docs.ansible.com/ansible/intro_configuration.html#bin-ansible-callbacks On Sunday, August 9, 2015 at 9:19:52 PM UTC+1, stephane jean wrote: > > oops thanks it's now w

[ansible-project] Re: pywinrm GSSError: No Kerberos credentials available

2015-08-14 Thread J Hawkesworth
m here. Just need to get more info from my > company about how to configure my machine to talk to its infrastructure. > Thanks a bunch! > > On Thursday, August 13, 2015 at 1:13:06 PM UTC-4, J Hawkesworth wrote: >> >> I think you need to set up your ansible controller as a

[ansible-project] Use kerberos error

2015-08-14 Thread J Hawkesworth
I think you need to use machine and domain names, rather than just using ip addresses. Kerberos depends on both forward and reverse dns lookups to work. You can check using ping to find ip of a host name and nslookup to find host name using ip. Hope this helps -- You received this messa

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-08-19 Thread J Hawkesworth
Not hit this- I'm not sure what you mean by 'LDAP (windows) users' but if you are logging in to your ansible controller using a windows domain user, and password then chances are you are using kerberos and ansible is then attempting to use your kerberos credentials to talk to your windows machi

[ansible-project] Re: Ignoring errors in check mode

2015-08-19 Thread J Hawkesworth
Not tried myself but I wonder if you could use failed_when to reduce the boilerplate a little: http://docs.ansible.com/ansible/playbooks_error_handling.html#controlling-what-defines-failure Something like this (as I say, untested): --- - hosts: all name: testing tasks: - name: pri

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-08-19 Thread J Hawkesworth
v.centos.org ) (gcc version 4.4.7 > 20120313 (Red Hat 4.4.7-11) (GCC) ) > > On Wednesday, August 19, 2015 at 12:56:53 PM UTC+3, J Hawkesworth wrote: >> >> Not hit this- I'm not sure what you mean by 'LDAP (windows) users' but if >> you are logging in to

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-08-20 Thread J Hawkesworth
nk you. > > does this not seem like a bug? > > On Wednesday, August 19, 2015 at 2:40:53 PM UTC+3, J Hawkesworth wrote: >> >> I think this is because when you logged into the machine, as part of the >> login process a kerberos ticket has been cached for the user you

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-08-20 Thread J Hawkesworth
eros with the '@' > char, yet it assumes that the user supplied is the user holding a kerberos > ticket. it does not validate this nor allow to use a different user but the > user which has an available ticket. > > BTW, how do i open a bug ticket? > > On Thursday, Aug

[ansible-project] Re: Debugging Windows

2015-08-21 Thread J Hawkesworth
Usually worth a quick look in the windows event log. You can also set export ANSIBLE_KEEP_REMOTE_FILES=1 before running your playbook. This will keep the generated .ps1 scripts in the users's temp directory on the windows machine. This is useful as you can then connect to the windows machine

[ansible-project] Re: Windows copy from file share

2015-08-21 Thread J Hawkesworth
No but... I suggest you take a look at Trond Hindenes' (not yet merged) win_package which I believe can install files from a network share. https://github.com/ansible/ansible-modules-extras/pull/713 You are likely to have to pass username and passord to avoid the second hop issue. Alternativel

[ansible-project] Re: Debugging Windows

2015-08-24 Thread J Hawkesworth
he temp directory and > it ran just fine, I have a feeling that's not quite the same process > though. > > > > On Friday, August 21, 2015 at 6:03:55 AM UTC-7, J Hawkesworth wrote: >> >> Usually worth a quick look in the windows event log. >> >> Y

[ansible-project] Re: ERROR: win_unzip is not a legal parameter in an Ansible task or handler

2015-08-26 Thread J Hawkesworth
Which ansible version are you using? http://docs.ansible.com/ansible/win_unzip_module.html states this module is available in version 2.0 so if you are using an older version, this won't be available yet. Jon On Tuesday, August 25, 2015 at 2:09:10 PM UTC+1, Igal Dahan wrote: > > Hi > > How can

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-08-26 Thread J Hawkesworth
can pass different domain creds other than my own. > > On Thursday, August 20, 2015 at 6:17:32 AM UTC-5, J Hawkesworth wrote: >> >> Ok so in your case running kinit deployment@YOURDOMAIN beforehand would >> be a work around. >> >> Just curious if you put >> >

[ansible-project] Re: ec2_facts and Windows

2015-08-28 Thread J Hawkesworth
Hey If you are using ansible from a source (git checkout) then just do what the message says and run git submodule update --init --recursive This will then pick up the modules (which are stored in git submodules) and you should be good to go. Hope that helps, Jon On Wednesday, August 26, 2

[ansible-project] Re: winrm best practices? can we use ssh on windows instead?

2015-09-03 Thread J Hawkesworth
Ssh would be nice as a transport but until its a thing, creating a connection plugin for it would be kinda hard. On Wednesday, August 26, 2015 at 11:42:36 AM UTC+1, pixel fairy wrote: > > I was thinking about that given this workaround, > https://github.com/ansible/ansible/issues/10294#issuecomm

[ansible-project] Re: Bug? Windows - Ansible uses LDAP user not ansible_ssh_user!?!

2015-09-03 Thread J Hawkesworth
When you say 'it works' can you do more than a win_ping? Server 2008 R2 comes with WMF 3.0 which had a bug when first released. Worth at least checking that you have either upgraded to WMF 4.0 or have installed hotfix (see blue box here: http://docs.ansible.com/ansible/intro_windows.html#windo

Re: [ansible-project] accessing json data

2015-09-10 Thread J Hawkesworth
I hit this yesterday too. Sorry to resurrect very old thread but thought I would add that in the end I wound up with the following syntax (to retrieve a list of conmmit messages from a jenkins build). Note that I wound up with single quotes around items: - name: collect the commit mess

Re: [ansible-project] Can't use local_action in Windows playbook in devel?

2015-09-10 Thread J Hawkesworth
Looks like you have hit https://github.com/ansible/ansible/issues/12053 changing over to delegate_to: localhost will likely work around the problem for now, until the above can be fixed. Jon On Thursday, September 10, 2015 at 9:09:20 AM UTC+1, Trond Hindenes wrote: > > That is very strange.

[ansible-project] Re: wierd substitution at regex_replace filter

2015-09-18 Thread J Hawkesworth
I think list is now a filter so perhaps try without the () on the end of list Not sure you can have {{ }} inside other {{ }} so maybe needs breaking into two parts, set_fact to get the list of regex replaced play hosts and then looking up the address from hostvars as a second step. Hope that h

[ansible-project] Re: windows winrm environment does not allow some kinds of execution

2015-09-18 Thread J Hawkesworth
Thanks for this. There's a PR around for a re-write of the win_updates module which uses the local scheduled task trick. The author of the PR was, if I recall, reluctant to generalise it as he felt there were a lot of edge cases to handle. If you are willing to create a PR for your module peo

[ansible-project] WinOps tomorrow

2015-09-21 Thread J Hawkesworth
Anyone else going to WinOps winops.org tomorrow? If so come and say hi. Jon -- 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...@googl

[ansible-project] Re: windows winrm environment does not allow some kinds of execution

2015-09-22 Thread J Hawkesworth
Thank you. Looking forward to seeing your PR. Jon -- 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 t

[ansible-project] Re: windows winrm environment does not allow some kinds of execution

2015-09-22 Thread J Hawkesworth
Thank you. Looking forward to seeing your PR. Jon -- 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 t

[ansible-project] Windows installer automatically reboots the server

2015-09-27 Thread J Hawkesworth
I don't have anything I have tested myself but I do have a couple of ideas. Maybe the way to handle is to kick off a scheduled task to run the install and then take a look at trond hindenes' win_reboot role in galaxy which I believe can wait until a reboot has been achieved. There is a PR for

[ansible-project] Re: Windows Server 2012 R2 - Process is terminated due to StackOverflowException.

2015-09-30 Thread J Hawkesworth
I wonder if you are hitting one of the quota limits. https://msdn.microsoft.com/en-us/library/ee309367(v=vs.85).aspx On Wednesday, September 30, 2015 at 7:44:50 AM UTC+1, Amir Luzon wrote: > > We are running a custom module we wrote in powershell. this module > basically runs about 5 parallel jo

[ansible-project] Re: Include task from different playbook

2015-09-30 Thread J Hawkesworth
Looks like you are attempting to include a playbook. You probably want to use pre_tasks instead of tasks for the first part to ensure things run in the order you want too. This would like something like the following: --- - hosts: localhost vars_files: - /etc/ansible/parent/parent.yml

[ansible-project] Re: Parsing for win_updates reboot hint

2015-09-30 Thread J Hawkesworth
You need to use 'register' to capture the results into a variable: http://docs.ansible.com/ansible/playbooks_variables.html#registered-variables Then you can call another module to do the reboot followed by a 'when', probably something like when: result_var.reboot_required worth having a loo

[ansible-project] Re: Parsing for win_updates reboot hint

2015-09-30 Thread J Hawkesworth
I suggest you add a debug on the registered variable and/or run ansible-playbook with -v this will show you the contents of the registered variable. It will be some JSON. Sometimes its useful to paste the JSON into http://jsonlint.com/ so you can see a pretty printed version of the JSON. then

[ansible-project] Re: Parsing for win_updates reboot hint

2015-09-30 Thread J Hawkesworth
Breaking it down a bit reboot_hint is the name of the variable you have chosen to store the registered output in. Inside reboot_hint is the output from the module. The module results are put into a key value structure with a key of results. This is probably done to keep the structured modul

[ansible-project] Re: Parsing for win_updates reboot hint

2015-10-02 Thread J Hawkesworth
the when: doesn't really default to true. Instead when: just needs to 'see' a true or a false. It doesn't care if that is from finding a value of true or false by looking up what is stored in a variable or by running something that returns a true or false. adding the '== true' makes the when:

[ansible-project] Re: Ansible deployment script, variable hosts value

2015-10-07 Thread J Hawkesworth
The value for hosts in the playbook can be a group of hosts (defined in your inventory). I'd suggest setting up different inventory files for each environment then you can run ansible-playbook -i /etc/ansible/dev-inventory deploy.yml or ansible-playbook -i /etc/ansible/staging-inventory deploy.

[ansible-project] Re: error executing raw on windows remote

2015-10-07 Thread J Hawkesworth
Hi Thorsten, running your playbook with -v or -v often helps. I think with -v you will see more of the returned error message. I think the problem here is maybe clash between windows path names containing \ and yaml syntax. I suggest you try quoting the whole of the raw string and usi

Re: [ansible-project] Unspecified GSS failure

2015-10-07 Thread J Hawkesworth
Hi, I think I've had this before where the name I had for the domain turned out to be an alias. If you run kinit -C user@SOME.DOMAIN and then do a klist if the ticket you get back is not for SOME.DOMAIN then that's the issue. I just changed my config so I was requesting a ticket for the actual

[ansible-project] Re: Ansible 1.9.4 has been released

2015-10-10 Thread J Hawkesworth
I think I read somewhere on the EPEL site that it is usually about 2 weeks. I guess there might be a little more time to wait for mirrors to catch up too. Jon -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group

[ansible-project] Re: Windows domain account using Kerberos

2015-10-12 Thread J Hawkesworth
I think you probably just need to acquire a kerberos ticket. Unless you have things set up so that you can log in to your ansible controller as a user on your domain, you won't have a kerberos ticket (which is what lets you access the machines on your domain as a specific user). I suggest yo

[ansible-project] Re: Ansible 1.9.4 CERTIFICATE_VERIFY_FAILED when connecting to Windows Server

2015-10-13 Thread J Hawkesworth
Just wondering if the callback plugin is actually getting loaded. You have callback_plugins = /callback_plugins/fix-ssl.py configured but that would be an unusual location if you intended an absolute path. I think you need to configure a full path to the folder, not the name of a file for ca

Re: [ansible-project] RedHat buys Ansible?

2015-10-16 Thread J Hawkesworth
http://www.redhat.com/en/about/press-releases/red-hat-acquire-it-automation-and-devops-leader-ansible On Friday, October 16, 2015 at 9:40:53 AM UTC+1, Dick Davies wrote: > > Sounds likely to me - I know their Satellite system is basically Cobbler > and some extra gubbins, so there's certainly pr

Re: [ansible-project] Re: Ansible 1.9.4 CERTIFICATE_VERIFY_FAILED when connecting to Windows Server

2015-10-16 Thread J Hawkesworth
m wrote: >> >> I shortened the path to make the posting easier to read. The actual >> path is something >> much longer. :) >> >> Thanks for taking the time to look though. >> >> On Tue, Oct 13, 2015 at 7:45 AM, J Hawkesworth >>

[ansible-project] Re: Ansible WinRM shows 401 Unauthorized when pywinrm works with no problem

2015-10-22 Thread J Hawkesworth
Which ansible version are you using? (run 'ansible --version' to find out). Generally 401 means the expected password doesn't match the one you supplied. You could check the event log on the windows machine for more information. Also, did you run https://github.com/ansible/ansible/blob/deve

[ansible-project] Re: Domain / LDAP User running Ansible from a CI Server

2015-10-27 Thread J Hawkesworth
Just wondering if setting no_log: True on your task would do the trick: http://docs.ansible.com/ansible/faq.html#how-do-i-keep-secret-data-in-my-playbook On Tuesday, October 27, 2015 at 11:44:11 AM UTC, David O'Brien wrote: > > Hi, > > is anybody running Ansible from a CI Server (Teamcity, Jenki

[ansible-project] Re: Ansible WinRM shows 401 Unauthorized when pywinrm works with no problem

2015-11-02 Thread J Hawkesworth
I wonder if this is still looking for the older name ansible_ssh_user instead of ansible_user ? You don't mention which version of ansible you are using. I haven't checked but if it is older than current dev I think you will need to use the name ansible_ssh_user in your group vars same thing

Re: [ansible-project] How to create multiple virtual machines in azure using ansible

2015-11-02 Thread J Hawkesworth
Is the trailing } on - "{{ vm_names_list }}" } intended / needed? On Saturday, October 31, 2015 at 8:03:30 PM UTC, Brian Coca wrote: > > try this: > > - hosts: localhost > connection: local > gather_facts: no > vars_files: > - vars/azure.yml > tasks: > - nam

[ansible-project] Re: Troubleshooting Windows Host UNREACHABLE!

2015-11-11 Thread J Hawkesworth
Worth checking if Window Remote Management service is running and if using a domain user that the domain user a member of the WinRMRemoteWMIUsers__ group too. Jon On Wednesday, November 11, 2015 at 9:47:20 PM UTC, Matt Calhoun wrote: > > I have many windows hosts that have been configured ident

[ansible-project] Re: Troubleshooting Windows Host UNREACHABLE!

2015-11-12 Thread J Hawkesworth
try hitting it again with ansible and check the event logs for any evidence of a login attempt. if its not getting that far... is there a proxy between controller and windows host (guessing a bit here, not much experience with proxies)? possibly firewall rules kicking in? bear in mind differen

Re: [ansible-project] Re: Troubleshooting Windows Host UNREACHABLE!

2015-11-12 Thread J Hawkesworth
; post demonstrated that I could telnet in on the WinRM port, so no firewall > blocking. There is also no proxy or anything in between. I can connect to > over 100 different servers, many on the same subnet as myhost, but this is > the only one giving me trouble. > > On Thu, Nov

[ansible-project] ansible-playbook hangs during execution

2015-11-27 Thread J Hawkesworth
Perhaps using -l to limit the playbook run to one host at a time would at least help you isolate the problem? I think -l takes group names and patterns if you have lots of hosts. -v might give you a clue what is going on too. -- You received this message because you are subscribed to the

[ansible-project] Ansible - configuring windows win_acl

2015-11-28 Thread J Hawkesworth
Can you share your playbook, it's hard to make suggestions without some context? -- 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...@g

[ansible-project] Re: Ansible installation from source (git clone) gives "ImportError: No module named ansible.runner"

2015-12-04 Thread J Hawkesworth
Did you run source hacking/env-setup so that the paths can be set? I think I've had similar when I've got a package install of ansible and pulled the source code on the same machine. Hope this helps, Jon On Friday, December 4, 2015 at 12:42:11 PM UTC, P wrote: > > Hi all, > > I am tryin

[ansible-project] Re: Unable to Authenticate to Satellite Datacenters Using Kerberos

2015-12-13 Thread J Hawkesworth
Hey, I'm not sure I fully understand all the domains you have set up in your organisation, but... You can definitely configure multiple realms in your /etc/krb5.conf and use kinit to acquire tickets for more than one domain at a time. I've done this enough to be confident in saying it works,

[ansible-project] Re: failed_when to fail after retries have been used

2015-12-20 Thread J Hawkesworth
Could you add a task straight after to use the assert module to check the contents of curl_output? Jon On Friday, December 18, 2015 at 12:01:23 PM UTC, jepper wrote: > > I am looking for a way for below to cause a failure, if the health check > fails to see an "UP" message after 10 attempts.

Re: [ansible-project] Error - Install tomcat

2020-07-27 Thread 'J Hawkesworth' via Ansible Project
Also the 'when' directive is indented too far, I think. Try like this - name: install tomcat7 from rhel-x86_64-server-6-datacenter-tomcat-grid- apps package: name: apache-tomcat-7.0.81 state: present when: ansible_distribution_major_version == "6" ignore_errors: yes On Friday, Ju

[ansible-project] Re: Jinja2 Template to use as SRC Path

2020-07-27 Thread 'J Hawkesworth' via Ansible Project
I would try and organize variables so they are associated with the host in inventory, rather than setting a lot of playbook vars # ansible inventory (notice both hosts in a group called 'appservers' ) [appservers] app_server_node1 appprops_file=node1-appprops.config app_server_node2 appprops_f

[ansible-project] Re: pinging both Windows and Linux hosts

2020-08-04 Thread 'J Hawkesworth' via Ansible Project
Rather than ping/win_ping you can use the cross-platform wait_for_connection module https://docs.ansible.com/ansible/latest/modules/wait_for_connection_module.html ansible all -m wait_for_connection Hope this helps Jon On Friday, July 31, 2020 at 6:04:09 AM UTC+1, Ed Wong wrote: > > I have

[ansible-project] Re: unable to install .exe files using win package module on a windows sever

2020-08-12 Thread 'J Hawkesworth' via Ansible Project
Lots of things could be going wrong here. What error do you get? Is there anything in windows event log? Change arguments and get the installer to write to a log file and look in that for problems. Does installer need administrator privilege? May be you need to run using become runas - see

Re: [ansible-project] wild card is not working for adapter_names in win_dns_client

2020-08-12 Thread 'J Hawkesworth' via Ansible Project
You proably need to fetch the adaptor name which you can do with Get-NetAdapter powershell command https://docs.microsoft.com/en-us/powershell/module/netadapter/get-netadapter?view=win10-ps then pass that to the module parameters. On Wednesday, August 12, 2020 at 11:39:57 AM UTC+1, Prakash PMS

Re: [ansible-project] Ansible for windows

2019-09-02 Thread 'J Hawkesworth' via Ansible Project
Did you try using async to run the command? I think you should be able to use async with win_shell module. The other steps you describe sound like they could be done using win_copy module and fetch module to retrieve the test results. See https://docs.ansible.com/ansible/latest/user_guide/playbo

Re: [ansible-project] Support for installing Ansible on Windows

2019-09-02 Thread 'J Hawkesworth' via Ansible Project
I use ansible from WSL most days and it works just fine for me. Unless you are calling stuff which attempts to use a system call that hasn't been implemented in WSL translation layer it will be fine. The above shouldn't be an issue with WSL 2 but I haven't tried that myself. That said I use Li

Re: [ansible-project] Kerberos Authentication Failed | kerberos: authGSSClientStep() failed | Help URGENT

2019-10-03 Thread 'J Hawkesworth' via Ansible Project
I suspect the issue is to do with resolving the hostname, so potentially an issue with DNS. Although you are using hostnames in your ansible inventory, it appears from the trace output that you are actually connecting via an IP address - 192.168.169.131 Kerberos requires DNS to be fully working.

[ansible-project] Re: Ansible return code ok or ko

2019-10-03 Thread 'J Hawkesworth' via Ansible Project
If any of your tasks fail, you will get a non-zero return code when ansible-playbook runs. So you can wrap your ansible-playbook in a bash script if you need to detect if the playbook ran ok # this one fails jon@TENSY ~ $ ansible-playbook -i does_not_exist playbook_doesnt_exist.yml ERROR! the pla

[ansible-project] Re: Managing Windows Host?

2019-10-04 Thread 'J Hawkesworth' via Ansible Project
Well to get rid the warning, remove the "{{ and }} " from your 'when' clause. The 'when' directive is a bit different from other places where you use jinja2 expressions as the "{{ and }}" are implicit. Although this might seem a bit inconsistent, it does result in easier to read tasks. If y

Re: [ansible-project] Kerberos Authentication Failed | kerberos: authGSSClientStep() failed | Help URGENT

2019-10-04 Thread 'J Hawkesworth' via Ansible Project
Glad to hear it. On Friday, October 4, 2019 at 8:39:22 AM UTC+1, Piyush Bansal wrote: > > Hello J Hawkesworth, > > I would like to thank you very much for the suggestion. > Issue got resolved now. > Thanks for your help :) > > Thanks, > Piyush > > > On Thu, Oc

[ansible-project] Re: Ansible return code ok or ko

2019-10-05 Thread 'J Hawkesworth' via Ansible Project
ther solution. > > I want get value of play_recap, when my playbook is finish, i want get > value of "skipped=0" or "Changed=5" > > Do you understand my question ?? > > Thanks very much community ansible !!! :) > > Regards, > > Karther >

[ansible-project] Re: win_shell command execution

2019-10-08 Thread 'J Hawkesworth' via Ansible Project
You would probably need to write like this: - win_shell: 'dir PackageDeploy*.* /b > {{directory}}\configurations\temp' args: executable: cmd chdir: '{{directory}}\configurations\jmxterm' register: list_out But its probably much better to use win_find module https://docs.a

Re: [ansible-project] Manual VS Ansible playbook in window server

2019-10-09 Thread 'J Hawkesworth' via Ansible Project
Have a read of this... https://docs.ansible.com/ansible/latest/user_guide/windows_faq.html#why-can-i-run-a-command-locally-that-does-not-work-under-ansible Is it possible the installer is expecting a GUI? Sometimes installers have a 'silent' or 'unattended' mode that means they can be made to r

[ansible-project] Ansible Play book for the Windows exe file

2019-10-22 Thread 'J Hawkesworth' via Ansible Project
Tomcat actually has a command line interface so you can configure it using that using a win_shell command. The command line interface is documented here: https://tomcat.apache.org/tomcat-9.0-doc/windows-service-howto.html Hope this helps, Jon -- You received this message because you are sub

[ansible-project] Setting up Windows without interaction

2019-10-22 Thread 'J Hawkesworth' via Ansible Project
Most modern versions of windows have winrm enabled by default so provided you have a suitable user with sufficient privileges, you can often connect once the OS has finished booting up. That said, there are a lot of factors that need to be considered depending on how things are set up in the en

Re: [ansible-project] Ansible Play book for the Windows exe file

2019-10-22 Thread 'J Hawkesworth' via Ansible Project
You are using ++Option. I think it will do what you want if you change to --Option syntax. Hope this helps. Jon -- 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 ema

[ansible-project] Re: Ansible V2.7 - kerberos: authGSSClientStep() failed:

2019-10-22 Thread 'J Hawkesworth' via Ansible Project
Server not found in kerberos database means that the domain controller is unaware of the server. You mention using hosts file which suggests to me that the machine you want to connect to has not been joined to the domain. You almost certainly wouldn't need to use hosts file as typically joining

Re: [ansible-project] Re: Setting up Windows without interaction

2019-10-22 Thread 'J Hawkesworth' via Ansible Project
Ssh support for Windows was merged a little while back so as long as you are running a recent ansible and can get the ssh server support on to your Windows targets, you can give it a whirl. https://github.com/ansible/ansible/pull/47732 Hope this helps Jon -- You received this message beca

[ansible-project] Ansible on Windows Environment

2019-10-23 Thread 'J Hawkesworth' via Ansible Project
Hi It is not clear what you are trying to do. By default ansible connects to Windows as batch login type, not interactive user, so usually there is no graphical user interface available to ansible. You can get an interactive user login by using the Become feature of ansible, but ansible is not

Re: [ansible-project] Ansible Play book for the Windows exe file

2019-10-23 Thread 'J Hawkesworth' via Ansible Project
If you store all the settings you need in your ansible playbook this is not a problem. I like to have ansible be fully in charge of the configuration of applications. It makes it easier to know exactly what settings are applied if they are all in ansible and you don't have to check each individ

[ansible-project] Read timeout when using WinRM to apply Windows patches on Azure

2019-10-23 Thread 'J Hawkesworth' via Ansible Project
I have had issues with single core machines when windows updates include an upgrade to the dot net version. What happens is ngen recompiles all the dot net code it can find and ties up an entire core until has finished recompiling, which leaves no cpu time for winrm. Dual core boxes aren't as ba

[ansible-project] Re: Ansible - regex help

2019-11-19 Thread 'J Hawkesworth' via Ansible Project
I think the issue is your respfile fact contains a list, not a string, hence the [ ] in the Debug output. There are a couple of ways to fix that. You can either do it when you are creating the fact (use the 'first' filter to just get the first element of the list), like this. - name: Set R

<    1   2   3   4   5   6   7   8   9   >