Free EX407 Exam Braindumps (page: 2)

Page 1 of 26

Examine the following inventory excerpt file named /home/user/ansible/inventory. [dbservers] db1.example.com

Which of the following files does Ansible check for variables related to that inventory? (Choose all that apply.)

  1. /home/user/ansible/dbservers
  2. /home/user/ansible/host_vars/db1.example.com
  3. /home/user/ansible/host_vars/db1
  4. /home/user/ansible/group_vars/dbservers

Answer(s): B,D

Explanation:

Ansible will check in /home/user/ansible/host_vars to find files named after hosts defined in the inventory. Ansible will check this file because there is a group defined in the inventory as dbservers.



Which flags must be accepted as input for a dynamic inventory script?

  1. Only --list
  2. --host [hostname] and --list
  3. --host [hostname] and --inv-list
  4. --list and --format [file format]

Answer(s): B



A dynamic inventory must return data in what format?

  1. JSON
  2. XML
  3. YAML
  4. INI

Answer(s): A

Explanation:

Dynamic inventories must return JSON output.



Which is the default inventory file used by Ansible?

  1. ${PWD}/.inventory
  2. /etc/hosts
  3. /etc/ansible/inventory
  4. /etc/ansible/hosts

Answer(s): D

Explanation:

Ansbile refers to /etc/ansible/hosts as the default inventory.






Post your Comments and Discuss RedHat EX407 exam with other Community members:

EX407 Discussions & Posts