Skip to content

Latest commit

 

History

History
311 lines (277 loc) · 11.8 KB

cisco.nxos.nxos_ping_module.rst

File metadata and controls

311 lines (277 loc) · 11.8 KB

cisco.nxos.nxos_ping

Tests reachability using ping from Nexus switch.

Version added: 1.0.0

Parameter Choices/Defaults Comments
count
integer
Default:
5
Number of packets to send.
dest
string / required
IP address or hostname (resolvable by switch) of remote node.
df_bit
boolean
    Choices:
  • no ←
  • yes
Set the DF bit.
size
integer
Size of packets to send.
source
string
Source IP Address or hostname (resolvable by switch)
state
string
    Choices:
  • absent
  • present ←
Determines if the expected result is success or fail.
vrf
string
Outgoing VRF.

Note

- name: Test reachability to 8.8.8.8 using mgmt vrf
  cisco.nxos.nxos_ping:
    dest: 8.8.8.8
    vrf: management
    host: 68.170.147.165

- name: Test reachability to a few different public IPs using mgmt vrf
  cisco.nxos.nxos_ping:
    dest: "{{ item }}"
    vrf: management
    host: 68.170.147.165
  with_items:
    - 8.8.8.8
    - 4.4.4.4
    - 198.6.1.4

- name: Test reachability to 8.8.8.8 using mgmt vrf, size and df-bit
  cisco.nxos.nxos_ping:
    dest: 8.8.8.8
    df_bit: true
    size: 1400
    vrf: management

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
commands
list
always
Show the command sent

Sample:
['ping 8.8.8.8 count 2 vrf management']
packet_loss
string
always
Percentage of packets lost

Sample:
0.00%
packets_rx
integer
always
Packets successfully received

Sample:
2
packets_tx
integer
always
Packets successfully transmitted

Sample:
2
rtt
dictionary
always
Show RTT stats

Sample:
{'avg': 6.264, 'max': 6.564, 'min': 5.978}


Authors

  • Jason Edelman (@jedelman8)
  • Gabriele Gerbino (@GGabriele)