200-901 Infrastructure and Automation Practice Question
A network administrator is managing a small office with 10 Cisco 9200 switches. They want to automate the deployment of a standard base configuration (VLANs, STP, management access) to all switches. They have a Linux server with Ansible installed. The administrator writes a playbook that uses the 'ios_config' module to apply configuration blocks. However, when they run the playbook against the first switch, it fails with an authentication error. The administrator can SSH to the switch manually using the same credentials. What is the most likely cause of the failure?
⚠ Common exam trap
Cisco often tests the distinction between SSH connectivity and Ansible connection method configuration, trapping candidates who assume that successful manual SSH implies the playbook will work without setting `ansible_connection` and `ansible_network_os`.
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
✓
The Ansible playbook is missing the 'ansible_connection: network_cli' and 'ansible_network_os: ios' variables.
The most likely cause is that the playbook is missing the required connection and platform variables. When using Ansible's `ios_config` module, you must explicitly set `ansible_connection: network_cli` and `ansible_network_os: ios` in the host variables or playbook. Without these, Ansible defaults to the `smart` connection plugin, which attempts an SSH connection using the `paramiko` library but does not properly negotiate the network CLI session, leading to authentication failures even though manual SSH works.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
The Ansible playbook is missing the 'ansible_connection: network_cli' and 'ansible_network_os: ios' variables.
Why this is correct
Network devices require these variables to handle the SSH session correctly.
- ✗
The switch's SSH server does not support the key exchange algorithm used by Ansible.
Why it's wrong here
This would cause a different error (key exchange failure) not authentication.
- ✗
The playbook is using the wrong username because the variable is not defined.
Why it's wrong here
If credentials are correct for manual SSH, they are likely correct in the playbook.
- ✗
The switch is running an incompatible IOS version that does not support the commands in the playbook.
Why it's wrong here
Incompatible commands would cause command errors, not authentication errors.
Visual reference
Go deeper
Related to this question
About these practice questions
This 200-901 question is part of Courseiva's 989-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This 200-901 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 200-901 exam.