CCNP Cisco DNA Center • Complete Question Bank
Complete CCNP Cisco DNA Center question bank — all 0 questions with answers and detailed explanations.
A network engineer writes the following Python script to retrieve the list of devices from Cisco DNA Center using the REST API:
import requests import json
url = "https://dna-center.local/dna/intent/api/v1/network-device" headers = {
"Content-Type": "application/json",
"X-Auth-Token": "valid-token-here"
}response = requests.get(url, headers=headers, verify=False)
if response.status_code == 200:
devices = response.json()
for device in devices["response"]:
print(device["hostname"])else:
print("Error:", response.status_code)What is the issue with this code?
An Ansible playbook is written to configure a VLAN on a Cisco IOS-XE device via Cisco DNA Center's intent API:
- name: Configure VLAN via DNA Center hosts: localhost gather_facts: no tasks: - name: Create VLAN 100 cisco.dnac.vlan: host: "{{ dnac_host }}"
username: "{{ dnac_username }}"password: "{{ dnac_password }}" validate_certs: no state: present vlan_name: "Engineering" vlan_id: 100 site_id: "{{ site_id }}" register: result
- debug: var=result
What is a potential issue with this playbook?
A network engineer is using the Cisco DNA Center REST API to retrieve the health score of a specific device. The API response is as follows:
{
"response": [
{
"deviceId": "1234567890",
"hostname": "Core-Switch-1",
"score": 8,
"overallHealth": "good",
"timestamp": 1623456789
}
],
"version": "1.0"
}The engineer wants to extract the 'overallHealth' value. Which Python code correctly extracts it?
A network engineer is using Netmiko to connect to a Cisco IOS-XE device that is managed by Cisco DNA Center. The script is:
from netmiko import ConnectHandler
device = { 'device_type': 'cisco_ios', 'host': '10.10.10.1', 'username': 'admin', 'password': 'cisco123', 'secret': 'enable123'
}
connection = ConnectHandler(**device) connection.enable() output = connection.send_command('show ip interface brief')
print(output)
connection.disconnect()
What is a potential security concern with this script in the context of DNA Center?
An engineer is using the Cisco DNA Center GUI to create a new site hierarchy. They add a building under an existing area. After saving, they run a Python script to verify the site via API:
import requests
url = "https://dna-center.local/dna/intent/api/v1/site" headers = {"X-Auth-Token": "token"} response = requests.get(url, headers=headers, verify=False) sites = response.json()['response']
for site in sites:
if site['name'] == 'Building-A':
print(site['id'])What is the output if the building was created successfully?
An Ansible playbook uses the cisco.dnac.site module to create a new building site. The playbook is:
- name: Create building site cisco.dnac.site: host: "{{ dnac_host }}"
username: "{{ dnac_username }}"password: "{{ dnac_password }}" validate_certs: no state: present site: name: Building-B type: building parentName: Area-1 address: "123 Main St" latitude: 37.7749 longitude: -122.4194 register: result
What is the purpose of the 'parentName' parameter?
A network engineer is configuring model-driven telemetry on a Cisco IOS-XE device that is part of a DNA Center managed fabric. The telemetry subscription configuration is:
telemetry ietf subscription 101 encoding encode-kvgpb filter xpath /process-cpu-ios-xe-oper:cpu-usage/cpu-utilization stream yang-push update-policy periodic 500 receiver ip address 10.10.10.10 port 5555 protocol grpc-tcp
What is the purpose of the 'encoding encode-kvgpb' line?
A network engineer uses the Cisco DNA Center API to trigger a provisioning workflow for a new device. The API call returns the following JSON response:
{
"response": {
"taskId": "task-12345",
"url": "/api/v1/task/task-12345"
},
"version": "1.0"
}The engineer then polls the task status using the URL. Which HTTP method should be used to retrieve the task status?
An engineer is writing a Python script to use the Cisco DNA Center API to assign a device to a site. The code snippet is:
import requests
url = "https://dna-center.local/dna/intent/api/v1/network-device/assign" headers = {
"X-Auth-Token": "token",
"Content-Type": "application/json"
}payload = {
"deviceId": "device-uuid",
"siteId": "site-uuid"
}response = requests.post(url, headers=headers, json=payload, verify=False)
print(response.status_code)
What is a potential issue with this code?
Examine the following partial Cisco IOS-XE configuration:
interface GigabitEthernet0/1 switchport mode access switchport access vlan 10 ip access-group ACL_IN in spanning-tree portfast
What is the effect of this configuration?
Consider the following configuration snippet from a Cisco IOS-XE router:
router eigrp 100 network 10.0.0.0 network 192.168.1.0 passive-interface default no passive-interface GigabitEthernet0/0
What is the effect of the passive-interface commands?
Examine the following OSPF configuration on a Cisco IOS-XE router:
router ospf 1
router-id 1.1.1.1
network 10.0.0.0 0.255.255.255 area 0 network 192.168.1.0 0.0.0.255 area 1
default-information originate always metric 10 metric-type 1
What is the effect of the 'default-information originate always' command?
Consider the following BGP configuration on a Cisco IOS-XE router:
router bgp 65001 neighbor 10.0.0.2 remote-as 65002 neighbor 10.0.0.2 route-map SET_COMMUNITY out
! route-map SET_COMMUNITY permit 10 set community 65001:100
What is the effect of this configuration?
Examine the following HSRP configuration on a Cisco IOS-XE switch:
interface Vlan10 ip address 10.0.0.2 255.255.255.0 standby 10 ip 10.0.0.1 standby 10 priority 150 standby 10 preempt
What is the effect of the 'standby 10 preempt' command?
Consider the following partial configuration for QoS on a Cisco IOS-XE router:
class-map match-all VOICE match ip dscp ef ! policy-map QOS_POLICY
class VOICE
priority 1000
class class-default
fair-queue !
interface GigabitEthernet0/0
service-policy output QOS_POLICY
What is the effect of the 'priority 1000' command under class VOICE?