200-901 Infrastructure and Automation Practice Question
Exhibit
Refer to the exhibit.
---
- name: Configure interfaces
hosts: switches
gather_facts: no
tasks:
- name: Set interface description
ios_config:
lines:
- description Lab-Interface
parents: interface GigabitEthernet0/1In the Ansible playbook snippet, what connection method is typically used for the ios_config module to communicate with the devices?
⚠ Common exam trap
Cisco often tests the distinction between connection methods by making candidates think 'local' is correct because it runs on the control node, but the trap is that ios_config requires a persistent SSH session to the device, which only network_cli provides.
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
✓
network_cli
The ios_config module is designed for Cisco IOS devices and requires a persistent network connection to send configuration commands. The network_cli connection method establishes an SSH session that remains open for the duration of the playbook task, allowing the module to send multiple CLI commands and handle prompts. This is the recommended connection method for ios_config because it supports privilege escalation and command responses needed for configuration changes.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
local
Why it's wrong here
local connection runs tasks on the control node, not on remote devices.
- ✓
network_cli
Why this is correct
The ios_config module requires the network_cli connection to send CLI commands over SSH.
- ✗
netconf
Why it's wrong here
netconf is used for NETCONF-based modules, not ios_config.
- ✗
httpapi
Why it's wrong here
httpapi is for REST API modules, not CLI.
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.