Playbook logging and verbosity
Increasing the verbosity of Ansible output can solve many problems. From invalid module arguments to incorrect connection commands, increased verbosity can be critical in pinpointing the source of an error. Playbook logging and verbosity were briefly discussed in Chapter 3, Protecting Your Secrets with Ansible, with regard to protecting secret values while executing playbooks. This section will cover verbosity and logging in further detail.
Verbosity
When executing playbooks with ansible-playbook
, the output is displayed on standard output (stdout). With the default level of verbosity, very little information is displayed. As a play is executed, ansible-playbook
will print a play header with the name of the play. Then, for each task, a task header is printed with the name of the task. As each host executes the task, the name of the host is displayed along with the task state, which...