# Ansible Project

**URL:** https://forum.ansible.com/c/archives/ansible-project/30.md?page=210

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

**Page:** 211

---

## [Ansible Cisco 5k Port-Profile issues](https://forum.ansible.com/t/ansible-cisco-5k-port-profile-issues/29545)

<div class="topic-metadata">

**Author:** [@Mark\_Giusti](https://forum.ansible.com/u/Mark_Giusti)\
**Replies:** 0\
**Last updated:** [January 28, 2019, 3:33pm UTC](https://forum.ansible.com/t/ansible-cisco-5k-port-profile-issues/29545 "2019-01-28T15:33:03Z")

</div>

Hi everyone, I am rather new to network automation so do excuse my lack of knowledge on the subject. I wish to setup a playbook for a cisco nexus 5k that will assign a number of interfaces to a predefined port-profile.…

---

## [getting error while checking which java using ansible](https://forum.ansible.com/t/getting-error-while-checking-which-java-using-ansible/29494)

<div class="topic-metadata">

**Author:** [@ruben\_melvin](https://forum.ansible.com/u/ruben_melvin)\
**Replies:** 8\
**Last updated:** [January 28, 2019, 8:47am UTC](https://forum.ansible.com/t/getting-error-while-checking-which-java-using-ansible/29494 "2019-01-28T08:47:33Z")

</div>

Hi guys, I am trying to execute below ansible playbook.

---

## [ModuleNotFoundError: No module named 'ansible.parsing'](https://forum.ansible.com/t/modulenotfounderror-no-module-named-ansible-parsing/29542)

<div class="topic-metadata">

**Author:** [@shenhaowee](https://forum.ansible.com/u/shenhaowee)\
**Replies:** 0\
**Last updated:** [January 28, 2019, 8:10am UTC](https://forum.ansible.com/t/modulenotfounderror-no-module-named-ansible-parsing/29542 "2019-01-28T08:10:51Z")

</div>

From what I saw in my environment I got this error when the script wasn’t in my root directory. \[root@xxx API\]# ./my\_ansible.py Traceback (most recent call last): File "./my\_ansible.py", line 5, in \<module\> …

---

## [To call Ansible legacy module from within library's custom module](https://forum.ansible.com/t/to-call-ansible-legacy-module-from-within-librarys-custom-module/29540)

<div class="topic-metadata">

**Author:** [@Leo\_Y](https://forum.ansible.com/u/Leo_Y)\
**Replies:** 0\
**Last updated:** [January 27, 2019, 1:18pm UTC](https://forum.ansible.com/t/to-call-ansible-legacy-module-from-within-librarys-custom-module/29540 "2019-01-27T13:18:52Z")

</div>

I would like to use existing implementations while developing a custom module. For this matter, I want to use k8s\_raw module to communicate with Kubernetes cluster instead of importing python packages and managing the wh…

---

## [Ansible 2.7, yum and list of packages](https://forum.ansible.com/t/ansible-2-7-yum-and-list-of-packages/29536)

<div class="topic-metadata">

**Author:** [@Byron\_Schlemmer](https://forum.ansible.com/u/Byron_Schlemmer)\
**Replies:** 3\
**Last updated:** [January 27, 2019, 11:05am UTC](https://forum.ansible.com/t/ansible-2-7-yum-and-list-of-packages/29536 "2019-01-27T11:05:54Z")

</div>

Hi, I’m having a problem installing RPMs using the yum module from a list. Using version: $ ansible --version ansible 2.7.6.post0 (stable-2.7 f759b5463b) last updated 2019/01/26 09:42:08 (GMT +000) python version = 2…

---

## [Password change automation](https://forum.ansible.com/t/password-change-automation/29532)

<div class="topic-metadata">

**Author:** [@mboncalo](https://forum.ansible.com/u/mboncalo)\
**Replies:** 5\
**Last updated:** [January 26, 2019, 1:26pm UTC](https://forum.ansible.com/t/password-change-automation/29532 "2019-01-26T13:26:36Z")

</div>

Hi, I know there are lots of examples on the internet but I can't make it work ansible-playbook --private-key=/root/docker/aatool/ky.pem --extra-vars admin\_password=T3est@ chpass.yml \[WARNING\]: provided hosts list is…

---

## [packer with ansible](https://forum.ansible.com/t/packer-with-ansible/29534)

<div class="topic-metadata">

**Author:** [@chaitanya\_p](https://forum.ansible.com/u/chaitanya_p)\
**Replies:** 0\
**Last updated:** [January 26, 2019, 1:04pm UTC](https://forum.ansible.com/t/packer-with-ansible/29534 "2019-01-26T13:04:02Z")

</div>

could you please help me with script & process, how to create ami using packer with ansible, installing aplications available in ami for example tomcat

---

## [malformed output when we have variables in the command line-cisco ASA device](https://forum.ansible.com/t/malformed-output-when-we-have-variables-in-the-command-line-cisco-asa-device/29533)

<div class="topic-metadata">

**Author:** [@Sahar](https://forum.ansible.com/u/Sahar)\
**Replies:** 0\
**Last updated:** [January 25, 2019, 8:16pm UTC](https://forum.ansible.com/t/malformed-output-when-we-have-variables-in-the-command-line-cisco-asa-device/29533 "2019-01-25T20:16:32Z")

</div>

I’m running the following commands, the output is malformed, May I know how I can fix it? name: Checking DNS Parameters asa\_command: commands: ‘show run policy-map type inspect dns “{{ policy\_map }}” | i maximum’ …

---

## [need ansible to wait for a springboot acutuator heathcheck to show up](https://forum.ansible.com/t/need-ansible-to-wait-for-a-springboot-acutuator-heathcheck-to-show-up/29528)

<div class="topic-metadata">

**Author:** [@IP\_Freely](https://forum.ansible.com/u/IP_Freely)\
**Replies:** 1\
**Last updated:** [January 25, 2019, 5:27pm UTC](https://forum.ansible.com/t/need-ansible-to-wait-for-a-springboot-acutuator-heathcheck-to-show-up/29528 "2019-01-25T17:27:18Z")

</div>

Hi Hope you can help me again I need to wait for a spring application to start before moving on in my playbook. when the microservice starts it runs flyway script that can take a long time to run before the service act…

---

## [is there a way to exit an included file but continue the play?](https://forum.ansible.com/t/is-there-a-way-to-exit-an-included-file-but-continue-the-play/29517)

<div class="topic-metadata">

**Author:** [@Josef\_Fortier](https://forum.ansible.com/u/Josef_Fortier)\
**Replies:** 2\
**Last updated:** [January 25, 2019, 3:56pm UTC](https://forum.ansible.com/t/is-there-a-way-to-exit-an-included-file-but-continue-the-play/29517 "2019-01-25T15:56:13Z")

</div>

I’ve developed a style where I use a lot of includes of small snippets to assemble bigger plays. I’d like to be able to do a test a condition at the top of an include, and skip the rest of the include if the condition i…

---

## [Need Debug Output](https://forum.ansible.com/t/need-debug-output/29514)

<div class="topic-metadata">

**Author:** [@Diptajeet\_Khan](https://forum.ansible.com/u/Diptajeet_Khan)\
**Replies:** 7\
**Last updated:** [January 25, 2019, 1:04pm UTC](https://forum.ansible.com/t/need-debug-output/29514 "2019-01-25T13:04:59Z")

</div>

Hi, Need help to fetch output from the below output message. Bascially I need to extract “packet\_loss”, “packets\_rx”, “packets\_tx”, “rtt\_avg”, “rtt\_max” & “rtt\_min” for each “item”. Trying to use the code as Code ==…

---

## [Ansible Kerberos Cannot contact any KDC for realm](https://forum.ansible.com/t/ansible-kerberos-cannot-contact-any-kdc-for-realm/29526)

<div class="topic-metadata">

**Author:** [@sindhu\_shree](https://forum.ansible.com/u/sindhu_shree)\
**Replies:** 0\
**Last updated:** [January 25, 2019, 11:19am UTC](https://forum.ansible.com/t/ansible-kerberos-cannot-contact-any-kdc-for-realm/29526 "2019-01-25T11:19:33Z")

</div>

Can anyone guide me why am getting this error ? UNREACHABLE! =\> { “changed”: false, “msg”: “Kerberos auth failure: kinit: Cannot contact any KDC for realm ‘AD.DOMAIN.COM’ while getting initial credentials”, “unreacha…

---

## [Automating VMware migrations](https://forum.ansible.com/t/automating-vmware-migrations/29523)

<div class="topic-metadata">

**Author:** [@Mario\_Zamora](https://forum.ansible.com/u/Mario_Zamora)\
**Replies:** 0\
**Last updated:** [January 24, 2019, 11:01pm UTC](https://forum.ansible.com/t/automating-vmware-migrations/29523 "2019-01-24T23:01:10Z")

</div>

Hello, I have a playbook that I’m working on to migrate VMs to a new ESX host. I finally got 1 maybe 2 parts working where I can power-off the machine and power-on again. Here’s where the maybe comes into play. When I …

---

## [wait\_for not\_contains doesn't work](https://forum.ansible.com/t/wait-for-not-contains-doesnt-work/29521)

<div class="topic-metadata">

**Author:** [@Sahar](https://forum.ansible.com/u/Sahar)\
**Replies:** 0\
**Last updated:** [January 24, 2019, 9:07pm UTC](https://forum.ansible.com/t/wait-for-not-contains-doesnt-work/29521 "2019-01-24T21:07:09Z")

</div>

I’m trying to make sure “maximum 512” doesn’t exist in my config: name: check if the parameters has been changed to 1024 asa\_command: commands: show run | i message-length maximum wait\_for: ‘result\[0\] not contains “…

---

## [An unexpected error while registering a variable  -  "unhashable type: 'list'"](https://forum.ansible.com/t/an-unexpected-error-while-registering-a-variable-unhashable-type-list/29520)

<div class="topic-metadata">

**Author:** [@Michal\_Markiewicz](https://forum.ansible.com/u/Michal_Markiewicz)\
**Replies:** 1\
**Last updated:** [January 24, 2019, 6:54pm UTC](https://forum.ansible.com/t/an-unexpected-error-while-registering-a-variable-unhashable-type-list/29520 "2019-01-24T18:54:23Z")

</div>

Hi, I’m trying to automate the process of setting up kubernetes cluster for training purposes. The tasks to register the command for joining workers to a cluster is as follows: \` name: get join token for workers she…

---

## [Ansible-Expect command issue](https://forum.ansible.com/t/ansible-expect-command-issue/29519)

<div class="topic-metadata">

**Author:** [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Replies:** 0\
**Last updated:** [January 24, 2019, 6:44pm UTC](https://forum.ansible.com/t/ansible-expect-command-issue/29519 "2019-01-24T18:44:39Z")

</div>

You need to show us the task, this output is not enough. My suspicion is that you have multiple equal keys in your response lik "Please enter a Digit", that is not allowed and you would need to make them one key with a …

---

## [How to update host file  using ansible](https://forum.ansible.com/t/how-to-update-host-file-using-ansible/29515)

<div class="topic-metadata">

**Author:** [@Pradeep\_Ghorpade](https://forum.ansible.com/u/Pradeep_Ghorpade)\
**Replies:** 1\
**Last updated:** [January 24, 2019, 2:46pm UTC](https://forum.ansible.com/t/how-to-update-host-file-using-ansible/29515 "2019-01-24T14:46:38Z")

</div>

Hello Team, I am looking ansible playbook which will update host file in below scenario. I have 2 group server both are aws instance. \[test\] servername \[test1\] servername1 I want to update host file on test group …

---

## [How to debug why a role is not played?](https://forum.ansible.com/t/how-to-debug-why-a-role-is-not-played/29510)

<div class="topic-metadata">

**Author:** [@Kumu](https://forum.ansible.com/u/Kumu)\
**Replies:** 1\
**Last updated:** [January 23, 2019, 11:10pm UTC](https://forum.ansible.com/t/how-to-debug-why-a-role-is-not-played/29510 "2019-01-23T23:10:37Z")

</div>

Hi, I have a playbook with one play that runs several roles. But when I run the playbook, Ansible is skipping one of the roles (not the first or last, but one in the middle). I tried creating a playbook with just that…

---

## [Ansible ssh private key](https://forum.ansible.com/t/ansible-ssh-private-key/29508)

<div class="topic-metadata">

**Author:** [@Bruno\_Cochofel](https://forum.ansible.com/u/Bruno_Cochofel)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 7:42pm UTC](https://forum.ansible.com/t/ansible-ssh-private-key/29508 "2019-01-23T19:42:31Z")

</div>

Hi, Is there a way to use a vault (something like hashicorp vault for instance) to retrieve the private-key to use for SSH ansible connection? I know that AWX can handle private keys transparently so any user can run a…

---

## [Ansible script for Password less SSH](https://forum.ansible.com/t/ansible-script-for-password-less-ssh/29507)

<div class="topic-metadata">

**Author:** [@ashok\_kumar\_penumudi](https://forum.ansible.com/u/ashok_kumar_penumudi)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 5:14pm UTC](https://forum.ansible.com/t/ansible-script-for-password-less-ssh/29507 "2019-01-23T17:14:55Z")

</div>

Hi can we create new user and will give sudo access and for that user can we do password was SSH by using Ansible script, if yes please suggest I am able to create user and provided sudo privileges but unable to do passw…

---

## [How to write playbook to access to servers that ansible master can not access directly?](https://forum.ansible.com/t/how-to-write-playbook-to-access-to-servers-that-ansible-master-can-not-access-directly/29497)

<div class="topic-metadata">

**Author:** [@yuechengww](https://forum.ansible.com/u/yuechengww)\
**Replies:** 2\
**Last updated:** [January 23, 2019, 5:04pm UTC](https://forum.ansible.com/t/how-to-write-playbook-to-access-to-servers-that-ansible-master-can-not-access-directly/29497 "2019-01-23T17:04:42Z")

</div>

Ansible master -ssh- hostA -ssh- hostB, ansible master can not access HostB directly. If I want to deploy services on hostB, can I configure hostA in a playbook, and include another playbook with hostB? E.g - hosts: Ho…

---

## [Options for filtering hosts](https://forum.ansible.com/t/options-for-filtering-hosts/29504)

<div class="topic-metadata">

**Author:** [@S\_C\_Rigler](https://forum.ansible.com/u/S_C_Rigler)\
**Replies:** 1\
**Last updated:** [January 23, 2019, 4:57pm UTC](https://forum.ansible.com/t/options-for-filtering-hosts/29504 "2019-01-23T16:57:47Z")

</div>

We have a static inventory where hosts are grouped by location and purpose. I was wondering if there was a way to limit a playbook run to hosts based on cached facts as a criteria (like only run on rhel 7 hosts, or o…

---

## [\[WARNING\]: Module remote\_tmp /root/.ansible/tmp did not exist and was created with a mode of 0700](https://forum.ansible.com/t/warning-module-remote-tmp-root-ansible-tmp-did-not-exist-and-was-created-with-a-mode-of-0700/28646)

<div class="topic-metadata">

**Author:** [@Arbab\_Nazar1](https://forum.ansible.com/u/Arbab_Nazar1)\
**Replies:** 4\
**Last updated:** [January 23, 2019, 1:13pm UTC](https://forum.ansible.com/t/warning-module-remote-tmp-root-ansible-tmp-did-not-exist-and-was-created-with-a-mode-of-0700/28646 "2019-01-23T13:13:43Z")

</div>

I am in the process of porting my code from ansible 2.4.2 to ansible 2.6.x and getting of a lot of this warning, \[WARNING\]: Module remote\_tmp /root/.ansible/tmp did not exist and was created with a mode of 0700, this ma…

---

## [unable to resolve inventory\_hostname via azure dynamic inventory on windows hosts execution](https://forum.ansible.com/t/unable-to-resolve-inventory-hostname-via-azure-dynamic-inventory-on-windows-hosts-execution/29502)

<div class="topic-metadata">

**Author:** [@Dhruv\_Bansal](https://forum.ansible.com/u/Dhruv_Bansal)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 11:41am UTC](https://forum.ansible.com/t/unable-to-resolve-inventory-hostname-via-azure-dynamic-inventory-on-windows-hosts-execution/29502 "2019-01-23T11:41:14Z")

</div>

Ansbile version 2.5.1.1 while executing ansible playbook via dynamic inventory of azure failing in resolving inventory\_hostname in the wsman url. if i try to resolve hosts via local inventory file it is working absolutl…

---

## [VMWare VRA Ansible Module Available](https://forum.ansible.com/t/vmware-vra-ansible-module-available/29501)

<div class="topic-metadata">

**Author:** [@Eugene\_Wong](https://forum.ansible.com/u/Eugene_Wong)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 11:34am UTC](https://forum.ansible.com/t/vmware-vra-ansible-module-available/29501 "2019-01-23T11:34:54Z")

</div>

Hi guys, Have created an Ansible-VRA module, in case anyone would like to deploy VM blueprints and invoke other XAAS (in a future release). https://galaxy.ansible.com/eugene\_ky\_wong/vra\_ansible Hope that it is useful…

---

## [issue when variable substitution using set command in jinja2 template](https://forum.ansible.com/t/issue-when-variable-substitution-using-set-command-in-jinja2-template/29500)

<div class="topic-metadata">

**Author:** [@Priyadarshini\_Venkat](https://forum.ansible.com/u/Priyadarshini_Venkat)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 9:25am UTC](https://forum.ansible.com/t/issue-when-variable-substitution-using-set-command-in-jinja2-template/29500 "2019-01-23T09:25:26Z")

</div>

I have a YAML file that has default value for two dict defined as follows: sample: high: name: high-volume alias: hi-vl hi-vl: ab1: add: range: 0 range1: 0 remove: range: -1 …

---

## [python: can't open file '/home/openwhisk/openwhisk/ansible/tmp/ansible-tmp-\*/setup.py': Permission denied](https://forum.ansible.com/t/python-cant-open-file-home-openwhisk-openwhisk-ansible-tmp-ansible-tmp-setup-py-permission-denied/29499)

<div class="topic-metadata">

**Author:** [@axiqia](https://forum.ansible.com/u/axiqia)\
**Replies:** 0\
**Last updated:** [January 23, 2019, 6:59am UTC](https://forum.ansible.com/t/python-cant-open-file-home-openwhisk-openwhisk-ansible-tmp-ansible-tmp-setup-py-permission-denied/29499 "2019-01-23T06:59:17Z")

</div>

\` $ ansible-playbook -i environments/distributed/hosts prereq\_build.yml --become-method=sudo --ask-sudo-pass \[DEPRECATION WARNING\]: The sudo command line option has been deprecated in favor of the “become” command line …

---

## [Filter hosts matching groups](https://forum.ansible.com/t/filter-hosts-matching-groups/29488)

<div class="topic-metadata">

**Author:** [@Bruno\_Cochofel](https://forum.ansible.com/u/Bruno_Cochofel)\
**Replies:** 3\
**Last updated:** [January 23, 2019, 4:37am UTC](https://forum.ansible.com/t/filter-hosts-matching-groups/29488 "2019-01-23T04:37:33Z")

</div>

Hi all, I have a custom CMDB and I've created a script for dynamic inventory. On that script I have grouped hosts using several ways, just like VMware dynamic inventory script. My question is, how can I match using mor…

---

## [accessing nested facts](https://forum.ansible.com/t/accessing-nested-facts/29492)

<div class="topic-metadata">

**Author:** [@christian.tremel](https://forum.ansible.com/u/christian.tremel)\
**Replies:** 1\
**Last updated:** [January 22, 2019, 8:33pm UTC](https://forum.ansible.com/t/accessing-nested-facts/29492 "2019-01-22T20:33:32Z")

</div>

i have to follwing fact structure…how to access the “size\_available” stuff from the opt filesystem? i tried this but it looks dorky… - name: check free space on /opt aix\_filesystem: filesystem: /opt …

---

## [Find matched element in key value](https://forum.ansible.com/t/find-matched-element-in-key-value/29383)

<div class="topic-metadata">

**Author:** [@Rama](https://forum.ansible.com/u/Rama)\
**Replies:** 16\
**Last updated:** [January 22, 2019, 8:24pm UTC](https://forum.ansible.com/t/find-matched-element-in-key-value/29383 "2019-01-22T20:24:43Z")

</div>

Hi All, Our required in-built module gives huge output of different keys that have multiple values with objects. I used ‘with\_dict’ and when to narrow and get desired output as below. Here also am facing a road block th…

[Previous page](https://forum.ansible.com/c/archives/ansible-project/30.md?page=209)

[Next page](https://forum.ansible.com/c/archives/ansible-project/30.md?page=211)
