From the course: Red Hat Certified Engineer (EX294) Cert Prep: 3 Managing Systems with Ansible

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Troubleshooting Ansible playbooks

Troubleshooting Ansible playbooks

From the course: Red Hat Certified Engineer (EX294) Cert Prep: 3 Managing Systems with Ansible

Start my 1-month free trial

Troubleshooting Ansible playbooks

- [Instructor] One way to troubleshoot our playbooks is to run them with the dash dash check option. When a playbook is executed with the dash dash check option, it will not make any changes to the remote host. Any module that supports check mode will display what would have been done had it not been in check mode. Modules that do not support check mode will not execute, but will also not output information on the screen showing what would have been done. If you're only making changes to one task and you don't want to run check mode on the entire playbook, then you can control it at task level. We have two options for this. We can force a task to run in check mode, even if the playbook has called without dash dash check on the command line. To do this, we'd set the check mode in our task. We can also force a task to run with check mode turned off, even if we do provide dash dash check on the command line. To do so, we'd set…

Contents