Book Image

Mastering Ansible, Second Edition - Second Edition

By : Jesse Keating
Book Image

Mastering Ansible, Second Edition - Second Edition

By: Jesse Keating

Overview of this book

This book provides you with the knowledge you need to understand how Ansible 2.1 works at a fundamental level and leverage its advanced capabilities. You'll learn how to encrypt Ansible content at rest and decrypt data at runtime. You will master the advanced features and capabilities required to tackle the complex automation challenges of today and beyond. You will gain detailed knowledge of Ansible workflows, explore use cases for advanced features, craft well thought out orchestrations, troubleshoot unexpected behaviour, and extend Ansible through customizations. Finally, you will discover the methods used to examine and debug Ansible operations, helping you to understand and resolve issues. By the end of the book, the readers will be able to unlock the true power of the Ansible automation engine and will tackle complex real world actions with ease.
Table of Contents (16 chapters)
Mastering Ansible - Second Edition
Credits
About the Author
About the Reviewer
www.PacktPub.com
Customer Feedback
Preface

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 to pinpointing the source of an error. Playbook logging and verbosity were briefly discussed in Chapter 2, Protecting Your Secrets with Ansible, with regards to protecting secret values while executing playbooks. This section will cover verbosity and logging further in-depth.

Verbosity

When executing playbooks with ansible-playbook, the output is displayed on standard out. 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 can be ok, fatal, or changed. No further information about the task is displayed, such as the...