Chapter 3 Network device programmability Flashcards
Network device programmability
What is the purpose of the send_config_set
method in Netmiko?
To send a list of configuration commands to a device.
What is the use of save_config
method in Netmiko?
To save the configuration on the device.
What is required to find the modules supported by a device using ncclient?
Building a NETCONF session to receive capabilities in response to the hello (rpc-reply).
What are the two main methods used to retrieve data from a device with ncclient?
-
get
*get-config
How can you request just a part of the configuration using NETCONF?
Using filters, which can be either subtree or xpath.
What is the structure of a subtree filter in NETCONF?
<filter>
<container_name></container_name>
<leaf></leaf>
</container_name>
</filter>
What is the purpose of the RESTCONF API?
To manage and configure network devices using HTTP requests.
What are the three HTTP methods used for configuration changes in RESTCONF?
- PUT -> Creates or overwrites a resource.
- POST -> Create a new resource, it doesn’t update existing resources
- PATCH -> Update a resource
What is the inventory file used for in Ansible?
To contain the target devices and their information.
What is the playbook in Ansible?
The file containing plays and tasks for configuration.
What is the purpose of the edit_config
method in ncclient?
To send configuration changes to a device.
What is the significance of the auth
parameter in a RESTCONF request?
It contains a tuple with username and password for authentication.
What is the command to get the running configuration in ncclient?
m.get_config(source=’running’).data_xml
What does the ios_config module allow you to do?
Send to the target device IOS commands in config mode.
What does the ios_command module allow you to do?
Send to the target device IOS commands in exec mode.
What is the purpose of the ‘parents’ parameter in an ios_config task?
Specifies the config sub menu for commands.
What is the format for sending multiple commands with ios_config?
Using the ‘lines’ parameter.
What does the ‘wait_for’ parameter do in an ios_command task?
Waits for a specific condition in the command output.
What is telemetry in networking?
Automated communication between network devices and a central node for data and configuration gathering.
What is Model Driven Telemetry (MDT)?
A mechanism to stream data from an MDT-capable device to a destination receiver in a continuous flow using a push model.
List the roles in Model Driven Telemetry.
- Publisher: Network element that sends the telemetry data.
- Receiver: Receives the telemetry data. This is also called the collector.
- Controller: Network element that creates subscriptions but does not receive the telemetry
data. The telemetry data associated with the subscriptions, it creates goes to receivers. - Subscriber: Network element that creates subscriptions.
What is the purpose of the ‘filter’ command in telemetry configuration?
Specifies the information to send based on a YANG model.
What are the two main MDT publication/subscription models?
- Dynamic (Dial-in)
- Configured (Dial-out)
Describe the Dynamic (Dial-in) model.
Uses NETCONF or gNMI, updates are sent to the subscriber, and the subscription needs to be reinitiated after a reload.
Describe the Configured (Dial-out) model.
Requires configuration on the publisher, automatically establishes a connection to the receiver after a reload.
List the techniques for Day 0 provisioning supported by Cisco IOS XE.
- Cisco network plug and play
- Zero touch provisioning (ZTP)
- Pre-Boot Execution Environment (iPXE) Client
What is the main requirement for Cisco network plug and play?
A server running the PnP protocol and containing the devices’ firmware images.
How does Zero Touch Provisioning (ZTP) work?
Uses standard protocols like TFTP or SCP to configure the device after obtaining an IP address from a DHCP server.
What is the function of the DHCP server in iPXE?
Allows the device to reach a TFTP/FTP/HTTP server storing boot images.