ansible / ansible.builtin / v2.9.4 / module / ce_mlag_interface Manages MLAG interfaces on HUAWEI CloudEngine switches. | "added in version" 2.4 of ansible.builtin" Authors: Li Yanfeng (@QijunPan) preview | supported by communityansible.builtin.ce_mlag_interface (v2.9.4) — module
pip
Install with pip install ansible==2.9.4
Manages MLAG interface attributes on HUAWEI CloudEngine switches.
- name: mlag interface module test hosts: cloudengine connection: local gather_facts: no vars: cli: host: "{{ inventory_hostname }}" port: "{{ ansible_ssh_port }}" username: "{{ username }}" password: "{{ password }}" transport: cli tasks: - name: Set interface mlag error down ce_mlag_interface: interface: 10GE2/0/1 mlag_error_down: enable provider: "{{ cli }}" - name: Create mlag ce_mlag_interface: eth_trunk_id: 1 dfs_group_id: 1 mlag_id: 4 provider: "{{ cli }}" - name: Set mlag global attribute ce_mlag_interface: mlag_system_id: 0020-1409-0407 mlag_priority_id: 5 provider: "{{ cli }}" - name: Set mlag interface attribute ce_mlag_interface: eth_trunk_id: 1 mlag_system_id: 0020-1409-0400 mlag_priority_id: 3 provider: "{{ cli }}"
state: choices: - present - absent default: present description: - Specify desired state of the resource. mlag_id: description: - ID of the M-LAG. The value is an integer that ranges from 1 to 2048. interface: description: - Name of the interface that enters the Error-Down state when the peer-link fails. The value is a string of 1 to 63 characters. dfs_group_id: default: present description: - ID of a DFS group.The value is 1. eth_trunk_id: description: - Name of the local M-LAG interface. The value is ranging from 0 to 511. mlag_system_id: description: - M-LAG global LACP system MAC address. The value is a string of 0 to 255 characters. The default value is the MAC address of the Ethernet port of MPU. mlag_error_down: choices: - enable - disable description: - Configure the interface on the slave device to enter the Error-Down state. mlag_priority_id: description: - M-LAG global LACP system priority. The value is an integer ranging from 0 to 65535. The default value is 32768.
changed: description: check to see if a change was made on the device returned: always sample: true type: bool end_state: description: k/v pairs of aaa params after module execution returned: always sample: {} type: dict existing: description: k/v pairs of existing aaa server returned: always sample: mlagErrorDownInfos: - dfsgroupId: '1' portName: Eth-Trunk1 type: dict proposed: description: k/v pairs of parameters passed into module returned: always sample: interface: eth-trunk1 mlag_error_down: disable state: present type: dict updates: description: command sent to the device returned: always sample: interface eth-trunk1: null undo m-lag unpaired-port suspend: null type: list