NAME

App::Netdisco::SSHCollector::Platform::NXOS

DESCRIPTION

Collect ARP, MAC table, and connected subnet data from Cisco NXOS devices.

PUBLIC METHODS

arpnip($host, $ssh)

Retrieve ARP entries from device. $host is the hostname or IP address of the device. $ssh is a Net::OpenSSH connection to the device.

Returns a list of hashrefs in the format { mac => MACADDR, ip => IPADDR }. Entries from all VRFs are flattened into a single returned list. Example: [ { ip => '192.0.2.10', mac => '0011.2233.4455' }, { ip => '2001:db8::1', mac => 'aabb.ccdd.eeff' } ].

macsuck($host, $ssh)

Retrieve MAC address table entries from device. $host is the hostname or IP address of the device. $ssh is a Net::OpenSSH connection to the device.

Returns a hashref keyed by VLAN and interface, where leaf keys are MAC addresses, in the format { VLAN => { PORT => { MACADDR => COUNT } } }. Example: { 10 => { 'Ethernet1/1' => { '00:11:22:33:44:55' => 1 } }, 20 => { 'Port-channel12' => { 'aa:bb:cc:dd:ee:ff' => 2 } } }.

subnets($host, $ssh)

Retrieve directly connected IPv4 subnets from device routing tables. $host is the hostname or IP address of the device. $ssh is a Net::OpenSSH connection to the device.

Returns a list of IPv4 CIDR strings in the format X.X.X.X/NN. Example: [ '10.1.1.0/24', '192.0.2.0/25' ].