nerdexam
Cisco

350-601 · Question #380

A network engineer must create a script to quickly verify IP reachability for multiple hosts using ping from the Cisco NX-OS switches. The script should use the management VRF and exit the shell…

The correct answer is D. Option D. To verify IP reachability for multiple hosts using 'ping' from a Cisco NX-OS switch via the management VRF and then exit the shell, the script needs to iterate through host IPs, use 'ping vrf management' for each, and then execute an 'exit' command.

Automation

Question

A network engineer must create a script to quickly verify IP reachability for multiple hosts using ping from the Cisco NX-OS switches. The script should use the management VRF and exit the shell after execution. Which script should be used to achieve this objective?

Exhibit

350-601 question #380 exhibit

Options

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

How the community answered

(37 responses)
  • A
    5% (2)
  • B
    8% (3)
  • C
    3% (1)
  • D
    84% (31)

Why each option

To verify IP reachability for multiple hosts using 'ping' from a Cisco NX-OS switch via the management VRF and then exit the shell, the script needs to iterate through host IPs, use 'ping vrf management' for each, and then execute an 'exit' command.

AOption A

This option is incorrect because it likely misses the 'vrf management' keyword, fails to properly loop through multiple hosts, or does not include an 'exit' command for proper termination.

BOption B

This option is incorrect because it probably does not correctly specify the management VRF for the ping, leading to reachability issues or incorrect testing results.

COption C

This option is incorrect because it likely has syntax errors, does not handle multiple hosts efficiently, or fails to properly exit the shell after execution.

DOption DCorrect

This option correctly constructs a script that iterates through a list of IP addresses, executing the 'ping vrf management <ip_address>' command for each to ensure reachability tests use the dedicated management VRF, and includes an 'exit' command to terminate the shell session after completion.

Concept tested: Cisco NX-OS scripting, ping with VRF, shell exit

Source: https://www.cisco.com/c/en/us/td/docs/switches/datacenter/nexus7000/sw/interfaces/config/cisco_nexus7000_interfaces_config_guide_8x/vrfs.html#C_ID_06C71D85_00

Topics

#Network Scripting#NX-OS CLI#Management VRF#IP Reachability

Community Discussion

No community discussion yet for this question.

Full 350-601 Practice