nerdexam
Cisco

350-601 · Question #129

Refer to Exhibit. An engineer must use the python module in the guest shell of the Cisco Nexus 9000 Series switch to shutdown port Ethernet ? Which command set will accomplish this?

The correct answer is B. Option B. When two or more commands are run individually, the state is not persistent from one command to subsequent commands. In the following example, the second command fails because the state from the first command does not persist for the second command: >>> cli("conf t") >>>…

Automation

Question

Refer to Exhibit. An engineer must use the python module in the guest shell of the Cisco Nexus 9000 Series switch to shutdown port Ethernet ? Which command set will accomplish this?

Exhibits

350-601 question #129 exhibit 1
350-601 question #129 exhibit 2

Options

  • AOption A
  • BOption B
  • COption C
  • DOption D

How the community answered

(20 responses)
  • A
    5% (1)
  • B
    70% (14)
  • C
    20% (4)
  • D
    5% (1)

Explanation

When two or more commands are run individually, the state is not persistent from one command to subsequent commands. In the following example, the second command fails because the state from the first command does not persist for the second command: >>> cli("conf t") >>> cli("interface eth4/1") When two or more commands are run together, the state is persistent from one command to subsequent commands. In the following example, the second command is successful because the state persists for the second and third commands: >>> cli("conf t ; interface eth4/1 ; shut") x/programmability/guide/b_Cisco_Nexus_9000_Series_NX- OS_Programmability_Guide_7x/Python_API.html

Topics

#Python scripting#Cisco Guest Shell#NX-OS interface management#Network automation

Community Discussion

No community discussion yet for this question.

Full 350-601 Practice