Question 220 of 1,420
hardMultiple SelectObjective-mapped
350-401 Practice Question: Which three statements about Ansible roles and…
Which three statements about Ansible roles and directory structure are true? (Choose three.)
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
A role must contain at least a 'tasks' directory with a main.yml file to be functional.
Ansible roles have a predefined directory structure including tasks, handlers, vars, defaults, files, templates, and meta. Roles can be shared via Ansible Galaxy. The 'defaults' directory contains lowest-priority variables. The 'meta' directory defines role dependencies.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
A role must contain at least a 'tasks' directory with a main.yml file to be functional.
Why this is correct
Correct because the 'tasks/main.yml' file is the core of a role; it defines the list of tasks to execute.
- ✗
Variables defined in the 'defaults' directory of a role have the highest precedence.
Why it's wrong here
Incorrect because 'defaults' variables have the lowest precedence; they are overridden by inventory, playbook, and other variable sources.
- ✓
The 'meta' directory in a role can define dependencies on other roles using the 'dependencies' key.
Why this is correct
Correct because the 'meta/main.yml' file can list role dependencies, which are automatically applied when the role is used.
- ✓
Handlers in a role are defined in the 'handlers' directory and are triggered by the 'notify' directive in tasks.
Why this is correct
Correct because handlers are special tasks that run only when notified by other tasks via the 'notify' keyword; they are defined in 'handlers/main.yml'.
- ✗
Roles cannot be shared or reused across different Ansible projects.
Why it's wrong here
Incorrect because roles are designed for reusability and can be shared via Ansible Galaxy or copied between projects.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Last reviewed: Jun 18, 2026
This 350-401 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 350-401 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.