• AnsibleFest
  • Products
  • Community
  • Webinars & Training
  • Blog
Ansible Logo
Documentation
Ansible
7

Ansible getting started

  • Getting started with Ansible

Installation, Upgrade & Configuration

  • Installation Guide
  • Ansible Porting Guides

Using Ansible

  • Building Ansible inventories
  • Using Ansible command line tools
  • Using Ansible playbooks
  • Protecting sensitive data with Ansible vault
  • Using Ansible modules and plugins
  • Using Ansible collections
  • Using Ansible on Windows and BSD
  • Ansible tips and tricks

Contributing to Ansible

  • Ansible Community Guide
  • Ansible Collections Contributor Guide
  • ansible-core Contributors Guide
  • Advanced Contributor Guide
  • Ansible documentation style guide

Extending Ansible

  • Developer Guide

Common Ansible Scenarios

  • Legacy Public Cloud Guides
  • Network Technology Guides
  • Virtualization and Containerization Guides

Network Automation

  • Network Getting Started
  • Network Advanced Topics
  • Network Developer Guide

Ansible Galaxy

  • Galaxy User Guide
  • Galaxy Developer Guide

Reference & Appendices

  • Collection Index
    • Collections in the Amazon Namespace
    • Collections in the Ansible Namespace
    • Collections in the Arista Namespace
    • Collections in the Awx Namespace
    • Collections in the Azure Namespace
    • Collections in the Check_point Namespace
    • Collections in the Chocolatey Namespace
    • Collections in the Cisco Namespace
    • Collections in the Cloud Namespace
    • Collections in the Cloudscale_ch Namespace
    • Collections in the Community Namespace
    • Collections in the Containers Namespace
    • Collections in the Cyberark Namespace
    • Collections in the Dellemc Namespace
      • Dellemc.Enterprise_Sonic
        • Description
        • Plugin Index
      • Dellemc.Openmanage
      • Dellemc.Os10
      • Dellemc.Os6
      • Dellemc.Os9
      • Dellemc.Powerflex
      • Dellemc.Unity
    • Collections in the F5networks Namespace
    • Collections in the Fortinet Namespace
    • Collections in the Frr Namespace
    • Collections in the Gluster Namespace
    • Collections in the Google Namespace
    • Collections in the Grafana Namespace
    • Collections in the Hetzner Namespace
    • Collections in the Hpe Namespace
    • Collections in the Ibm Namespace
    • Collections in the Infinidat Namespace
    • Collections in the Infoblox Namespace
    • Collections in the Inspur Namespace
    • Collections in the Junipernetworks Namespace
    • Collections in the Kubernetes Namespace
    • Collections in the Lowlydba Namespace
    • Collections in the Mellanox Namespace
    • Collections in the Netapp Namespace
    • Collections in the Netapp_eseries Namespace
    • Collections in the Netbox Namespace
    • Collections in the Ngine_io Namespace
    • Collections in the Openstack Namespace
    • Collections in the Openvswitch Namespace
    • Collections in the Ovirt Namespace
    • Collections in the Purestorage Namespace
    • Collections in the Sensu Namespace
    • Collections in the Splunk Namespace
    • Collections in the T_systems_mms Namespace
    • Collections in the Theforeman Namespace
    • Collections in the Vmware Namespace
    • Collections in the Vultr Namespace
    • Collections in the Vyos Namespace
    • Collections in the Wti Namespace
  • Indexes of all modules and plugins
  • Playbook Keywords
  • Return Values
  • Ansible Configuration Settings
  • Controlling how Ansible behaves: precedence rules
  • YAML Syntax
  • Python 3 Support
  • Interpreter Discovery
  • Releases and maintenance
  • Testing Strategies
  • Sanity Tests
  • Frequently Asked Questions
  • Glossary
  • Ansible Reference: Module Utilities
  • Special Variables
  • Red Hat Ansible Automation Platform
  • Ansible Automation Hub
  • Logging Ansible output

Roadmaps

  • Ansible Roadmap
  • ansible-core Roadmaps




Ansible
  • Collection Index
  • Collections in the Dellemc Namespace
  • Dellemc.Enterprise_Sonic
  • dellemc.enterprise_sonic.sonic_lag_interfaces module – Manage link aggregation group (LAG) interface parameters


dellemc.enterprise_sonic.sonic_lag_interfaces module – Manage link aggregation group (LAG) interface parameters

Note

This module is part of the dellemc.enterprise_sonic collection (version 2.0.0).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install dellemc.enterprise\_sonic.

To use it in a playbook, specify: dellemc.enterprise_sonic.sonic_lag_interfaces.

New in dellemc.enterprise_sonic 1.0.0

  • Synopsis

  • Parameters

  • Notes

  • Examples

  • Return Values

Synopsis

  • This module manages attributes of link aggregation group (LAG) interfaces of devices running Enterprise SONiC Distribution by Dell Technologies.

Note

This module has a corresponding action plugin.

Parameters

Parameter

Comments

config

list / elements=dictionary

A list of LAG configurations.

members

dictionary

The list of interfaces that are part of the group.

interfaces

list / elements=dictionary

The list of interfaces that are part of the group.

member

string

The interface name.

mode

string

Specifies mode of the port-channel while creation.

Choices:

  • "static"

  • "lacp"

name

string / required

ID of the LAG.

state

string

The state that the configuration should be left in.

Choices:

  • "merged" ← (default)

  • "deleted"

Notes

Note

  • Tested against Enterprise SONiC Distribution by Dell Technologies.

  • Supports check_mode.

Examples

# Using merged
#
# Before state:
# -------------
#
# interface Eth1/10
#  mtu 9100
#  speed 100000
#  no shutdown
# !
# interface Eth1/15
#  channel-group 12
#  mtu 9100
#  speed 100000
#  no shutdown
#
- name: Merges provided configuration with device configuration
  dellemc.enterprise_sonic.sonic_lag_interfaces:
    config:
     - name: PortChannel10
       members:
         interfaces:
           - member: Eth1/10
    state: merged
#
# After state:
# ------------
#
# interface Eth1/10
#  channel-group 10
#  mtu 9100
#  speed 100000
#  no shutdown
# !
# interface Eth1/15
#  channel-group 12
#  mtu 9100
#  speed 100000
#  no shutdown
#
# Using deleted
#
# Before state:
# -------------
# interface PortChannel10
# !
# interface Eth1/10
#  channel-group 10
#  mtu 9100
#  speed 100000
#  no shutdown
#
- name: Deletes LAG attributes of a given interface, This does not delete the port-channel itself
  dellemc.enterprise_sonic.sonic_lag_interfaces:
    config:
     - name: PortChannel10
       members:
         interfaces:
    state: deleted
#
# After state:
# ------------
# interface PortChannel10
# !
# interface Eth1/10
#  mtu 9100
#  speed 100000
#  no shutdown
#
# Using deleted
#
# Before state:
# -------------
# interface PortChannel 10
# !
# interface PortChannel 12
# !
# interface Eth1/10
#  channel-group 10
#  mtu 9100
#  speed 100000
#  no shutdown
# !
# interface Eth1/15
#  channel-group 12
#  mtu 9100
#  speed 100000
#  no shutdown
#
- name: Deletes all LAGs and LAG attributes of all interfaces
  dellemc.enterprise_sonic.sonic_lag_interfaces:
    config:
    state: deleted
#
# After state:
# -------------
#
# interface Eth1/10
#  mtu 9100
#  speed 100000
#  no shutdown
# !
# interface Eth1/15
#  mtu 9100
#  speed 100000
#  no shutdown
#
#

Return Values

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

Key

Description

after

list / elements=string

The resulting configuration model invocation.

Returned: when changed

Sample: ["The configuration returned is always in the same format of the parameters above.\n"]

before

list / elements=string

The configuration prior to the model invocation.

Returned: always

Sample: ["The configuration that is returned is always in the same format\n of the parameters above.\n"]

commands

list / elements=string

The set of commands pushed to the remote device.

Returned: always

Sample: ["command 1", "command 2", "command 3"]

Authors

  • Abirami N (@abirami-n)

Collection links

Issue Tracker Repository (Sources)

Previous Next

© Copyright Ansible project contributors. Last updated on Jan 31, 2023.