# Latest

**URL:** https://forum.ansible.com/latest.md?page=687

[Latest](https://forum.ansible.com/latest.md) · [Categories](https://forum.ansible.com/categories.md) · [Tags](https://forum.ansible.com/tags.md)

**Page:** 688

---

## [Parsing and Comparing a text file](https://forum.ansible.com/t/parsing-and-comparing-a-text-file/23680)

<div class="topic-metadata">

**Author:** [@Mona\_Gopal](https://forum.ansible.com/u/Mona_Gopal)\
**Replies:** 2\
**Last updated:** [February 8, 2017, 6:30pm UTC](https://forum.ansible.com/t/parsing-and-comparing-a-text-file/23680 "2017-02-08T18:30:33Z")

</div>

Hello, My requirement is as below: A text file with configuration contents would be given to us by the product teams. I will have to compare this file against the one on the remote host , find out the difference, and …

---

## [ec2\_elb\_facts results truncated](https://forum.ansible.com/t/ec2-elb-facts-results-truncated/23684)

<div class="topic-metadata">

**Author:** [@Gage\_Gaskins](https://forum.ansible.com/u/Gage_Gaskins)\
**Replies:** 0\
**Last updated:** [February 8, 2017, 5:30pm UTC](https://forum.ansible.com/t/ec2-elb-facts-results-truncated/23684 "2017-02-08T17:30:59Z")

</div>

Hi all, I’ve been trying to use the newest ec2\_elb\_facts module and realized that boto is truncating results for elb lists \>400. I know boto3 does this as well and that boto allows bypassing this through the use of the …

---

## [When does ansible refresh the variables from the host\_vars directory?](https://forum.ansible.com/t/when-does-ansible-refresh-the-variables-from-the-host-vars-directory/23675)

<div class="topic-metadata">

**Author:** [@Johannes\_Kastl](https://forum.ansible.com/u/Johannes_Kastl)\
**Replies:** 6\
**Last updated:** [February 8, 2017, 3:52pm UTC](https://forum.ansible.com/t/when-does-ansible-refresh-the-variables-from-the-host-vars-directory/23675 "2017-02-08T15:52:00Z")

</div>

Hi all, I have a play that adds a line to a file in the host\_vars directory on the host running the play. I have a very sporadic error, that the contents of the file are not being re-read afterwards. I'll explain wit…

---

## [default for undefined dict](https://forum.ansible.com/t/default-for-undefined-dict/23682)

<div class="topic-metadata">

**Author:** [@adrien\_nayrat](https://forum.ansible.com/u/adrien_nayrat)\
**Replies:** 4\
**Last updated:** [February 8, 2017, 11:42am UTC](https://forum.ansible.com/t/default-for-undefined-dict/23682 "2017-02-08T11:42:15Z")

</div>

Hi, Here is my variable : instances: name: ref mgservices: name: test1 My default variable: default\_mgservice : name: blah I want to use “default\_mgservice.name” when mgservices is not defined : instances: n…

---

## [postgresql\_user module help](https://forum.ansible.com/t/postgresql-user-module-help/23678)

<div class="topic-metadata">

**Author:** [@Shyam\_Yenna](https://forum.ansible.com/u/Shyam_Yenna)\
**Replies:** 2\
**Last updated:** [February 8, 2017, 8:28am UTC](https://forum.ansible.com/t/postgresql-user-module-help/23678 "2017-02-08T08:28:06Z")

</div>

I am getting below error while trying to use module postgresql\_user. I want to create a new user account in postgresql. but i am unable to create user account with become\_user postgres or commenting that line is failing …

---

## [How to copy very long(5000+ lines) out-put of commands to files](https://forum.ansible.com/t/how-to-copy-very-long-5000-lines-out-put-of-commands-to-files/23665)

<div class="topic-metadata">

**Author:** [@Satish](https://forum.ansible.com/u/Satish)\
**Replies:** 2\
**Last updated:** [February 8, 2017, 8:27am UTC](https://forum.ansible.com/t/how-to-copy-very-long-5000-lines-out-put-of-commands-to-files/23665 "2017-02-08T08:27:26Z")

</div>

Hello Team, I am using ios\_command module in a playbook. With this module we executes different commands (i.e. show version, show ISIS neighbor, show users etc…) on routers and collect respective output in text file. To…

---

## [when condition on a variable starting with a string value](https://forum.ansible.com/t/when-condition-on-a-variable-starting-with-a-string-value/23663)

<div class="topic-metadata">

**Author:** [@fanvalt](https://forum.ansible.com/u/fanvalt)\
**Replies:** 7\
**Last updated:** [February 8, 2017, 8:14am UTC](https://forum.ansible.com/t/when-condition-on-a-variable-starting-with-a-string-value/23663 "2017-02-08T08:14:29Z")

</div>

Hello, Actually I wrote my playbook this way to set values id the dual variable is the string value SRV: set\_fact: distrib: “{{ distribsrv }}” Directoryname: “{{ Directorysrv }}” when: dual == ‘SRV’ I would like t…

---

## [docker\_container networking issue](https://forum.ansible.com/t/docker-container-networking-issue/23642)

<div class="topic-metadata">

**Author:** [@Sonny\_Heer](https://forum.ansible.com/u/Sonny_Heer)\
**Replies:** 1\
**Last updated:** [February 8, 2017, 5:09am UTC](https://forum.ansible.com/t/docker-container-networking-issue/23642 "2017-02-08T05:09:22Z")

</div>

Hi all, I’ve been fighting this one for a while. adding N containers to a custom network. host1 starts services that listen on 50070. on host1 I can ‘telnet host1.dev 50070’ and it works. host2 is connected to the same …

---

## [Use dynamic inventory with windows ec2](https://forum.ansible.com/t/use-dynamic-inventory-with-windows-ec2/23016)

<div class="topic-metadata">

**Author:** [@challa.tek](https://forum.ansible.com/u/challa.tek)\
**Replies:** 3\
**Last updated:** [February 7, 2017, 10:39pm UTC](https://forum.ansible.com/t/use-dynamic-inventory-with-windows-ec2/23016 "2017-02-07T22:39:40Z")

</div>

Can any one suggest me with best way for using dynamic inventory for ec2 windows. Usually for linux ec2…i have a play which goes like creates a ec2 instance —first play refresh dynamic inventory —2nd play connect to l…

---

## [Error setting up HTTPS endpoint for WinRM](https://forum.ansible.com/t/error-setting-up-https-endpoint-for-winrm/23614)

<div class="topic-metadata">

**Author:** [@ryan.mensching](https://forum.ansible.com/u/ryan.mensching)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 10:11pm UTC](https://forum.ansible.com/t/error-setting-up-https-endpoint-for-winrm/23614 "2017-02-07T22:11:11Z")

</div>

I have been working on an issue with getting the HTTPS endpoint for WinRM to bind to the self signed cert the Ansible setup script creates. I’m pretty stumped at this point, it seems I had it working at one time but afte…

---

## [Unable to get double-backslashes right on windows](https://forum.ansible.com/t/unable-to-get-double-backslashes-right-on-windows/23673)

<div class="topic-metadata">

**Author:** [@Trond\_Hindenes](https://forum.ansible.com/u/Trond_Hindenes)\
**Replies:** 3\
**Last updated:** [February 7, 2017, 10:01pm UTC](https://forum.ansible.com/t/unable-to-get-double-backslashes-right-on-windows/23673 "2017-02-07T22:01:11Z")

</div>

In my role I have one step which sets up some pathing: name: Set consul folder var set\_fact: consul\_folder: “{{ ansible\_env\[‘DatafilesPath’\] }}\\apps\\consul” This works in Ansible and I can use the ‘consul\_folder’ va…

---

## [Support for ClearLinux OS](https://forum.ansible.com/t/support-for-clearlinux-os/23676)

<div class="topic-metadata">

**Author:** [@Alberto\_Murillo](https://forum.ansible.com/u/Alberto_Murillo)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 9:19pm UTC](https://forum.ansible.com/t/support-for-clearlinux-os/23676 "2017-02-07T21:19:30Z")

</div>

Hi there. I am working with the ClearLinux Project for Intel Architecture (clearlinux.org) which uses its own update manager (swupd) I have created the following PR to add support for swupd but I’m unsure on the proces…

---

## [Struggling with Ansible GCE inventory](https://forum.ansible.com/t/struggling-with-ansible-gce-inventory/23668)

<div class="topic-metadata">

**Author:** [@Tzach\_Livyatan2](https://forum.ansible.com/u/Tzach_Livyatan2)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 8:05pm UTC](https://forum.ansible.com/t/struggling-with-ansible-gce-inventory/23668 "2017-02-07T20:05:02Z")

</div>

I’m following the instructions at http://docs.ansible.com/ansible/guide\_gce.html but failed to get gce.py running \` ./inventories/gce/gce.py --list Traceback (most recent call last): File “./inventories/gce/gce.py”, …

---

## [How to append to the PATH](https://forum.ansible.com/t/how-to-append-to-the-path/23670)

<div class="topic-metadata">

**Author:** [@Jonty\_Needham](https://forum.ansible.com/u/Jonty_Needham)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 8:04pm UTC](https://forum.ansible.com/t/how-to-append-to-the-path/23670 "2017-02-07T20:04:23Z")

</div>

I need to update the PATH variable on the target machine. Yet I have no idea how to do it. I could update /etc/environment with an ansible play, but does that do what I want without overwriting the user’s PATH instead o…

---

## [until failing with grep command](https://forum.ansible.com/t/until-failing-with-grep-command/23674)

<div class="topic-metadata">

**Author:** [@Vikram\_Ranabhatt](https://forum.ansible.com/u/Vikram_Ranabhatt)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 7:41pm UTC](https://forum.ansible.com/t/until-failing-with-grep-command/23674 "2017-02-07T19:41:38Z")

</div>

Here with the following piece of code is waiting for the kubernetest pod to be disappeared after launch. pod do disappeared but the script fails with the error. I want to wait till pod disappeared and the continue with…

---

## [SSH to literal IPv6 address](https://forum.ansible.com/t/ssh-to-literal-ipv6-address/23659)

<div class="topic-metadata">

**Author:** [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Replies:** 7\
**Last updated:** [February 7, 2017, 7:21pm UTC](https://forum.ansible.com/t/ssh-to-literal-ipv6-address/23659 "2017-02-07T19:21:48Z")

</div>

Hi I'm trying to set up a quick test host and have added this entry in my ~/.ssh/config: # Test host Host imapsync Hostname 2001:610:148:f00d:20c:29ff:fe14:ccfe Just issuing "ssh imapsync" works fine. I have thi…

---

## [How to copy very long(5000+ lines) out-put of commands to files](https://forum.ansible.com/t/how-to-copy-very-long-5000-lines-out-put-of-commands-to-files/23666)

<div class="topic-metadata">

**Author:** [@Satish](https://forum.ansible.com/u/Satish)\
**Replies:** 0\
**Last updated:** [February 7, 2017, 2:45pm UTC](https://forum.ansible.com/t/how-to-copy-very-long-5000-lines-out-put-of-commands-to-files/23666 "2017-02-07T14:45:55Z")

</div>

Hello Team, I am using ios\_command module in a playbook. With this module we executes different commands (i.e. show version, show ISIS neighbor, show users etc…) on routers and collect respective output in text file. To…

---

## [How to put period between two variables](https://forum.ansible.com/t/how-to-put-period-between-two-variables/23656)

<div class="topic-metadata">

**Author:** [@Kenton\_Brede](https://forum.ansible.com/u/Kenton_Brede)\
**Replies:** 2\
**Last updated:** [February 7, 2017, 2:21pm UTC](https://forum.ansible.com/t/how-to-put-period-between-two-variables/23656 "2017-02-07T14:21:49Z")

</div>

So this will print what I want: debug: msg: “{{ groups.tag\_Name\_shibboleth\_aws\_dev1\[0\] }}” But I’m using a with\_items and need something like this: { host: ‘tag\_Name\_shibboleth\_aws\_dev1’, othervar: ‘blah’ } deb…

---

## [vmware\_guest: customizing new VM from template](https://forum.ansible.com/t/vmware-guest-customizing-new-vm-from-template/23664)

<div class="topic-metadata">

**Author:** [@Rodrigo\_B\_Brasil](https://forum.ansible.com/u/Rodrigo_B_Brasil)\
**Replies:** 0\
**Last updated:** [February 7, 2017, 2:17pm UTC](https://forum.ansible.com/t/vmware-guest-customizing-new-vm-from-template/23664 "2017-02-07T14:17:47Z")

</div>

Hello there, Is there any limitation when customizing an Oracle Linux OS? I’m creating a new guest from a template (with VMware Tools installed) and trying to set static IP, but its not working. The VM is created with …

---

## [WHEN CONDITION](https://forum.ansible.com/t/when-condition/23591)

<div class="topic-metadata">

**Author:** [@DHAVAL\_JAISWAL](https://forum.ansible.com/u/DHAVAL_JAISWAL)\
**Replies:** 8\
**Last updated:** [February 7, 2017, 1:16pm UTC](https://forum.ansible.com/t/when-condition/23591 "2017-02-07T13:16:27Z")

</div>

I want to use the following condition in ansible playbook. Scenario is as follows. If arg1 \> 5 follow some steps else endif; IF ELSE is not possible in ansible. However, how can i achive with the WHEN condition.

---

## [log filename in a callback plugin](https://forum.ansible.com/t/log-filename-in-a-callback-plugin/23660)

<div class="topic-metadata">

**Author:** [@fanvalt](https://forum.ansible.com/u/fanvalt)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 1:11pm UTC](https://forum.ansible.com/t/log-filename-in-a-callback-plugin/23660 "2017-02-07T13:11:24Z")

</div>

Hello, In a callback plugin, I did parameter the filename to dipatch log files by host and ansible pid this way: filename = ‘%s\_%s’ % (host,os.getpid()) I would like to add the name of the playbook that is run, in exa…

---

## [Prompt in Lookup Module](https://forum.ansible.com/t/prompt-in-lookup-module/23662)

<div class="topic-metadata">

**Author:** [@nicolas.baer](https://forum.ansible.com/u/nicolas.baer)\
**Replies:** 0\
**Last updated:** [February 7, 2017, 1:11pm UTC](https://forum.ansible.com/t/prompt-in-lookup-module/23662 "2017-02-07T13:11:13Z")

</div>

Hi There We are writing an integration to our third party password manager using a lookup plugin. We would like to prompt the user for credentials in case we can not access a certain token. Is this feasible within the L…

---

## [1.9-\>2.2: dynamic inventory and groups with spaces](https://forum.ansible.com/t/1-9-2-2-dynamic-inventory-and-groups-with-spaces/23661)

<div class="topic-metadata">

**Author:** [@sascha.lucas](https://forum.ansible.com/u/sascha.lucas)\
**Replies:** 0\
**Last updated:** [February 7, 2017, 12:25pm UTC](https://forum.ansible.com/t/1-9-2-2-dynamic-inventory-and-groups-with-spaces/23661 "2017-02-07T12:25:26Z")

</div>

Hi, after upgrade of ansible-1.9 to 2.2 groups with spaces seems no longer to work. Here is a fragment of the dynamic inventory: { "suse linux enterprise server 11 sp4": \[ "server0001", "server10…

---

## [SSH fine but keep getting errors running test playbook](https://forum.ansible.com/t/ssh-fine-but-keep-getting-errors-running-test-playbook/23653)

<div class="topic-metadata">

**Author:** [@Shiyan\_Cao](https://forum.ansible.com/u/Shiyan_Cao)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 12:14pm UTC](https://forum.ansible.com/t/ssh-fine-but-keep-getting-errors-running-test-playbook/23653 "2017-02-07T12:14:44Z")

</div>

Hi, Does anyone know why I’m getting the error? SSH connection is working fine. ansible-playbook -i inventory/qalabs -l xxxxxxx -u root -D test.yml PLAY \[all\] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*…

---

## [Obtain the user specified via '-u' cli option](https://forum.ansible.com/t/obtain-the-user-specified-via-u-cli-option/23654)

<div class="topic-metadata">

**Author:** [@Michael\_Spiegle](https://forum.ansible.com/u/Michael_Spiegle)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 12:07pm UTC](https://forum.ansible.com/t/obtain-the-user-specified-via-u-cli-option/23654 "2017-02-07T12:07:54Z")

</div>

At some point in Ansible 2.0.x, the ‘{{ansible\_user}}’ variable would reflect the argument passed to ansible-playbook ‘-u’. It doesn’t appear to be doing this any more, and I can’t seem to find a way to obtain the value …

---

## [Error while setting lamp infrastrcture.](https://forum.ansible.com/t/error-while-setting-lamp-infrastrcture/23652)

<div class="topic-metadata">

**Author:** [@Milind\_Sisodiya](https://forum.ansible.com/u/Milind_Sisodiya)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 11:59am UTC](https://forum.ansible.com/t/error-while-setting-lamp-infrastrcture/23652 "2017-02-07T11:59:34Z")

</div>

Hello All,

---

## [Problem connecting to host behind jump server when host set dynamically](https://forum.ansible.com/t/problem-connecting-to-host-behind-jump-server-when-host-set-dynamically/23647)

<div class="topic-metadata">

**Author:** [@Linus\_Sunde](https://forum.ansible.com/u/Linus_Sunde)\
**Replies:** 4\
**Last updated:** [February 7, 2017, 11:38am UTC](https://forum.ansible.com/t/problem-connecting-to-host-behind-jump-server-when-host-set-dynamically/23647 "2017-02-07T11:38:07Z")

</div>

I have a problem where a playbook using add\_host fails unless the host (which sits behind a jump server) has already been connected to by running another playbook. Can anyone explain to me why the following happens, and…

---

## [playbook do not execute](https://forum.ansible.com/t/playbook-do-not-execute/23657)

<div class="topic-metadata">

**Author:** [@user93](https://forum.ansible.com/u/user93)\
**Replies:** 2\
**Last updated:** [February 7, 2017, 10:30am UTC](https://forum.ansible.com/t/playbook-do-not-execute/23657 "2017-02-07T10:30:44Z")

</div>

Hello, I have Debian 8.1 and ansible 2.2.1.0. When I execute playbook I recive that message PLAY RECAP \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* and nothing more. My test playbook is very…

---

## [Role meta dependencies and overrides](https://forum.ansible.com/t/role-meta-dependencies-and-overrides/23658)

<div class="topic-metadata">

**Author:** [@Mark\_Olliver2](https://forum.ansible.com/u/Mark_Olliver2)\
**Replies:** 1\
**Last updated:** [February 7, 2017, 10:18am UTC](https://forum.ansible.com/t/role-meta-dependencies-and-overrides/23658 "2017-02-07T10:18:26Z")

</div>

Hi All, I am using ansible 2.2.1.0 and have a few issues with meta dependencies. I have a base role that is used for many of my environments. This role in turn has a meta file which defines a list of dependant roles. F…

---

## [How to execute a playbook for a group of hosts with some tasks that have to be executed only once](https://forum.ansible.com/t/how-to-execute-a-playbook-for-a-group-of-hosts-with-some-tasks-that-have-to-be-executed-only-once/23648)

<div class="topic-metadata">

**Author:** [@Tom\_Bartsch](https://forum.ansible.com/u/Tom_Bartsch)\
**Replies:** 4\
**Last updated:** [February 7, 2017, 10:11am UTC](https://forum.ansible.com/t/how-to-execute-a-playbook-for-a-group-of-hosts-with-some-tasks-that-have-to-be-executed-only-once/23648 "2017-02-07T10:11:17Z")

</div>

Hi there, in my hosts file I have a group “product”. This group has 4 hosts: “product-et”, “product-at”, “product-qs” and “product-pr”. “product” has special properties which are valid for all 4 hosts. Each of the 4 …

[Previous page](https://forum.ansible.com/latest.md?page=686)

[Next page](https://forum.ansible.com/latest.md?page=688)
