dellemc.enterprise_sonic.sonic_system module – Configure system parameters
Note
This module is part of the dellemc.enterprise_sonic collection (version 3.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_system
.
New in dellemc.enterprise_sonic 1.0.0
Synopsis
This module is used for configuration management of global system parameters on devices running Enterprise SONiC.
Note
This module has a corresponding action plugin.
Parameters
Parameter |
Comments |
---|---|
Specifies the system related configurations |
|
Specifies different types of anycast address that can be configured on the device |
|
Enable or disable ipv4 anycast-address Choices:
|
|
Enable or disable ipv6 anycast-address Choices:
|
|
Specifies the mac anycast-address |
|
Specifies audit rule profile type. Can be used on SONiC release versions 4.4.0 and above. Choices:
|
|
Specifies auto-breakout status in the device Choices:
|
|
Specifies the hostname of the SONiC device |
|
Specifies the type of interface-naming in device Choices:
|
|
Specifies different types of ECMP Load share hash algorithm Choices:
|
|
Specifies the operation to be performed on the system parameters configured on the device. In case of merged, the input configuration will be merged with the existing system configuration on the device. In case of deleted the existing system configuration will be removed from the device. Choices:
|
Notes
Note
Tested against Enterprise SONiC Distribution by Dell Technologies.
Supports
check_mode
.
Examples
# Using deleted
#
# Before state:
# -------------
#!
#SONIC(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
#ipv6 anycast-address enable
#interface-naming standard
#ip load-share hash algorithm JENKINS_HASH_HI
- name: Merge provided configuration with device configuration
dellemc.enterprise_sonic.sonic_system:
config:
hostname: SONIC
interface_naming: standard
anycast_address:
ipv6: true
load_share_hash_algo: JENKINS_HASH_HI
state: deleted
# After state:
# ------------
#!
#sonic(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
# Using deleted
#
# Before state:
# -------------
#!
#SONIC(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
#ipv6 anycast-address enable
#interface-naming standard
#ip load-share hash algorithm JENKINS_HASH_HI
- name: Delete all system related configs in device configuration
dellemc.enterprise_sonic.sonic_system:
config:
state: deleted
# After state:
# ------------
#!
#sonic(config)#do show running-configuration
#!
# Using merged
#
# Before state:
# -------------
#!
#sonic(config)#do show running-configuration
#!
- name: Merge provided configuration with device configuration
dellemc.enterprise_sonic.sonic_system:
config:
hostname: SONIC
interface_naming: standard
anycast_address:
ipv6: true
ipv4: true
mac_address: aa:bb:cc:dd:ee:ff
load_share_hash_algo: JENKINS_HASH_HI
state: merged
# After state:
# ------------
#!
#SONIC(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
#ipv6 anycast-address enable
#interface-naming standard
#ip load-share hash algorithm JENKINS_HASH_HI
# Using replaced
#
# Before state:
# -------------
#!
#sonic(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
#ipv6 anycast-address enable
- name: Replace system configuration.
sonic_system:
config:
hostname: sonic
interface_naming: standard
state: replaced
# After state:
# ------------
#!
#SONIC(config)#do show running-configuration
#!
#interface-naming standard
# Using replaced
#
# Before state:
# -------------
#!
#sonic(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#interface-naming standard
- name: Replace system device configuration.
sonic_system:
config:
hostname: sonic
interface_naming: standard
anycast_address:
ipv6: true
ipv4: true
load_share_hash_algo: JENKINS_HASH_HI
state: replaced
# After state:
# ------------
#!
#SONIC(config)#do show running-configuration
#!
#ip anycast-address enable
#ipv6 anycast-address enable
#interface-naming standard
#ip load-share hash algorithm JENKINS_HASH_HI
# Using overridden
#
# Before state:
# -------------
#!
#sonic(config)#do show running-configuration
#!
#ip anycast-mac-address aa:bb:cc:dd:ee:ff
#ip anycast-address enable
#ipv6 anycast-address enable
#ip load-share hash algorithm JENKINS_HASH_HI
- name: Override system configuration.
sonic_system:
config:
hostname: sonic
interface_naming: standard
anycast_address:
ipv4: true
mac_address: bb:aa:cc:dd:ee:ff
load_share_hash_algo: CRC_XOR
state: overridden
# After state:
# ------------
#!
#SONIC(config)#do show running-configuration
#!
#ip anycast-mac-address bb:aa:cc:dd:ee:ff
#ip anycast-address enable
#interface-naming standard
#ip load-share hash algorithm CRC_XOR
# Using merged
#
# Before state:
# -------------
#!
#sonic(config)#do show running-configuration
#!
- name: Merge provided configuration with device configuration
dellemc.enterprise_sonic.sonic_system:
config:
hostname: SONIC
interface_naming: standard
auto_breakout: ENABLE
load_share_hash_algo: JENKINS_HASH_HI
audit_rules: BASIC
state: merged
# After state:
# ------------
#!
#SONIC(config)#do show running-configuration
#!
#hostname SONIC
#interface-naming standard
#auto-breakout
#ip load-share hash algorithm JENKINS_HASH_HI
#auditd-system rules basic
# Using deleted
#
# Before state:
# -------------
#!
#SONIC(config)#do show running-configuration
#!
#hostname SONIC
#interface-naming standard
#auto-breakout
#ip load-share hash algorithm JENKINS_HASH_HI
#auditd-system rules basic
- name: Delete auto-breakout configuration on the device
dellemc.enterprise_sonic.sonic_system:
config:
hostname: SONIC
auto_breakout: ENABLE
load_share_hash_algo: JENKINS_HASH_HI
audit_rules: BASIC
state: deleted
# After state:
# ------------
#!
#sonic(config)#do show running-configuration
#!
#interface-naming standard
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The resulting configuration module invocation. Returned: when changed Sample: |
|
The configuration prior to the module invocation. Returned: always Sample: |
|
The set of commands pushed to the remote device. Returned: always Sample: |