arubanetworks.aoscx.aoscx_mac (4.3.2) — module

Collects information on MAC configuration.

| "added in version" 4.1.0 of arubanetworks.aoscx"

Authors: Aruba Networks (@ArubaNetworks)

preview | supported by certified

Install collection

Install with ansible-galaxy collection install arubanetworks.aoscx:==4.3.2


Add to requirements.yml

  collections:
    - name: arubanetworks.aoscx
      version: 4.3.2

Description

This module retrieves information of MAC addresses from Aruba devices running the AOS-CX operating system. MAC addresses information will be printed out when the playbook execution is done with increased verbosity.

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
---
- name: Fetch all MAC addresses from all vlans
  aoscx_mac:
    all_vlans: true
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Fetch all MAC addresses from VLAN 1
  aoscx_mac:
    vlan: 1
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Fetch MAC addresses from VLAN 3 that are static and dynamic.
  aoscx_mac:
    vlan: 3
    sources:
      - static
      - dynamic
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: Fetch MAC addresses from all VLANs that are static only.
  aoscx_mac:
    all_vlans: true
    sources:
      - static

Inputs

    
vlan:
    description: 'VLAN ID the MAC addresses are attached to. This option is mutually exclusive
      with the all_vlans option.

      '
    required: false
    type: int

sources:
    choices:
    - dynamic
    - evpn
    - hsc
    - static
    - port-access-security
    - vrrp
    - vsx
    default:
    - dynamic
    - evpn
    - hsc
    - static
    - port-access-security
    - vrrp
    - vsx
    description: 'List of sources of the MAC addresses to filter which ones will be included
      in the output.

      '
    elements: str
    required: false
    type: list

all_vlans:
    description: 'Option to fetch all MACs from all VLANs in a device. This option is
      mutually exclusive with the `vlan` option.

      '
    required: false
    type: bool

Outputs

ansible_mac_addresses:
  description: The MAC addresses from given source(s) from given VLAN(s)
  returned: always
  type: dict