Every difficult point you identify in practice is one less surprise on exam day. Prep4SureReview helps you find them with 42 verified practice questions for the RedHat Red Hat Certified Specialist in Ansible Automation exam and a printable PDF for review.
RedHat EX407 Exam Syllabus Topics:
| Section | Weight | Objectives |
|---|---|---|
| Work with Inventories | 10% | - Manage static inventory groups - Validate inventory with ad-hoc commands - Use and write dynamic inventory scripts |
| Install and Configure Ansible Control Node | 15% | - Configure SSH access and privilege escalation - Create inventory and configuration files - Install required Ansible packages |
| Use Templates and Roles | 20% | - Develop and use Ansible roles - Create Jinja2 templates - Download roles from Ansible Galaxy |
| Secure and Optimize Automation | 15% | - Use Ansible Vault to protect sensitive data - Validate playbook functionality - Manage parallel execution and task flow |
| Understand Core Ansible Components | 15% | - Inventories, static and dynamic - Ansible configuration files - Modules, variables, facts, plays, playbooks |
| Create and Manage Playbooks | 25% | - Configure system state: packages, services, files, storage, security - Implement variables, conditionals, and error handling - Use common Ansible modules |
EX407 Material FAQ
The RedHat Red Hat Certified Specialist in Ansible Automation exam contains Performance-based tasks (no fixed number) questions, and you will have 240 minutes minutes to complete them. Practicing within the same limits builds the pacing the real exam demands.
This package includes 42 practice questions for the RedHat Red Hat Certified Specialist in Ansible Automation exam. Every answer is verified by an experienced team of experts, so you can trust what you study.
The PDF version downloads in seconds and prints cleanly, so you can read on paper, flip through the pages freely, and write notes in the margins as you go. Marking each mistake on paper makes review sessions concrete: you see exactly which questions tripped you up and which topics need another round.
The RedHat Red Hat Certified Specialist in Ansible Automation practice questions are organized around the official exam objectives. Key topics include:
- Secure and Optimize Automation (15%)
- Install and Configure Ansible Control Node (15%)
- Work with Inventories (10%)
Use your printed pages to flag the topics that give you trouble, then focus your next session there.
You can register for the RedHat Red Hat Certified Specialist in Ansible Automation exam through the official channels:
The RedHat Red Hat Certified Specialist in Ansible Automation exam requires a score of 70% to pass, and the official registration fee is USD 400. Because the fee is significant, preparing thoroughly the first time is the practical choice.
No mandatory prerequisites; RHCSA certification or equivalent RHEL administration experience strongly recommended
You can confirm the current eligibility requirements on the official EX407 exam page before you register.
Many candidates combine practice questions with official training. Recommended options include:
If you learn best with physical pages, the PDF version is built for you. Print the full 42 practice questions for the EX407 exam, work through them anywhere without a device, and keep your annotated pages as a personal review guide. The PC and online versions remain available whenever you want interactive practice.
RedHat Red Hat Certified Specialist in Ansible Automation Sample Questions:
Create a file called packages.yml in /home/sandy/ansible to install some packages for the following hosts. On dev, prod and webservers install packages httpd, mod_ssl, and mariadb. On dev only install the development tools package. Also, on dev host update all the packages to the latest.
Reveal Solution Discussion 0Correct Answer:
Solution as:
** NOTE 1 a more acceptable answer is likely 'present' since it's not asking to install the latest
state: present
** NOTE 2 need to update the development node
- name: update all packages on development node
yum:
name: '*'
state: latest
===================================================================================
control.realmX.example.com _ workstation.lab.example.com
node1.realmX.example.com _ servera.lab.example.com
node2.realmX.example.com _ serverb.lab.example.com
node3.realmX.example.com _ serverc.lab.example.com
node4.realmX.example.com _ serverd.lab.example.com
node5.realmX.example.com
- username:root, password:redhat
- username:admin, password:redhat
note1. don't change 'root' or 'admin' password.
note2. no need to create ssh-keygen for access, its pre-defined
note3. SELinux is in enforcing mode and firewalld is disabled/stop on whole managed hosts.
Install the RHEL system roles package and create a playbook called timesync.yml that:
--> Runs over all managed hosts.
--> Uses the timesync role.
--> Configures the role to use the time server 192.168.10.254 ( Hear in redhat lab
use "classroom.example.com" )
--> Configures the role to set the iburst parameter as enabled.
Correct Answer:
Solution as:
# pwd
home/admin/ansible/
# sudo yum install rhel-system-roles.noarch -y
# cd roles/
# ansible-galaxy list
# cp -r /usr/share/ansible/roles/rhelsystem-roles.timesync .
# vim timesync.yml
---
- name: timesynchronization
hosts: all
vars:
timesync_ntp_provider: chrony
timesync_ntp_servers:
- hostname: classroom.example.com _ in exam its ip-address
iburst: yes
timezone: Asia/Kolkata
roles:
- rhel-system-roles.timesync
tasks:
- name: set timezone
timezone:
name: "{{ timezone }}"
:wq!
timedatectl list-timezones | grep india
# ansible-playbook timesync.yml --syntax-check
# ansible-playbook timesync.yml
# ansible all -m shell -a 'chronyc sources -v'
# ansible all -m shell -a 'timedatectl'
# ansible all -m shell -a 'systemctl is-enabled chronyd'
What keyword sets a change condition for a given task?
- A. register_change
- B. changed_when
- C. change_set
- D. flag_change
Correct Answer: A 🗳️
===================================================================================
control.realmX.example.com _ workstation.lab.example.com
node1.realmX.example.com _ servera.lab.example.com
node2.realmX.example.com _ serverb.lab.example.com
node3.realmX.example.com _ serverc.lab.example.com
node4.realmX.example.com _ serverd.lab.example.com
node5.realmX.example.com
- username:root, password:redhat
- username:admin, password:redhat
note1. don't change 'root' or 'admin' password.
note2. no need to create ssh-keygen for access, its pre-defined
note3. SELinux is in enforcing mode and firewalld is disabled/stop on whole managed hosts.
Create a playbook called web.yml as follows:
* The playbook runs on managed nodes in the "dev" host group
* Create the directory /webdev with the following requirements:
--> membership in the apache group
--> regular permissions: owner=r+w+execute, group=r+w+execute, other=r+execute
s.p=set group-id
* Symbolically link /var/www/html/webdev to /webdev
* Create the file /webdev/index.html with a single line of text that reads:
"Development"
--> it should be available on http://servera.lab.example.com/webdev/index.html
Correct Answer:
Solution as:
# pwd
/home/admin/ansible/
# vim web.yml
---
- name:
hosts: dev
tasks:
- name: create group
yum:
name: httpd
state: latest
- name: create group
group:
name: apache
state: present
- name: creating directiory
file:
path: /webdev
state: directory
mode: '2775'
group: apache
- sefcontext:
target: '/webdev/index.html'
setype: httpd_sys_content_t
state: present
- name: Apply new SELinux file context to filesystem
command: restorecon -irv
- name: creating symbolic link
file:
src: /webdev
dest: /var/www/html/webdev
state: link
force: yes
- name: creating file
file:
path: /webdev/index.html
sate: touch
- name: Adding content to index.html file
copy:
dest: /webdev/index.html
content: "Development"
- name: add service to the firewall
firewalld:
service: http
permanent: yes
state: enabled
immediate: yes
- name: active http service
service:
name: httpd
state: restarted
enabled: yes
:wq
# ansible-playbook web.yml --syntax-check
# ansible-playbook web.yml
Create a playbook called regulartasks.yml which has the system that append the date to /root/datefile every day at noon. Name is job 'datejob'
Reveal Solution Discussion 0Correct Answer:
Solution as:
Viewing page 1 out of 9 pages.
Viewing questions 1-5 out of 42 questions.






