dellemc.enterprise_sonic.sonic_pim_global module – Manage global PIM configurations on SONiC
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_pim_global
.
New in dellemc.enterprise_sonic 2.5.0
Synopsis
This module provides configuration management of global PIM parameters for devices running SONiC.
VRF and prefix-list need to be created earlier in the device.
Parameters
Parameter |
Comments |
---|---|
Specifies global PIM configurations. |
|
Enable PIM ECMP. Choices:
|
|
Enable PIM ECMP rebalance. ECMP has to be enabled for configuring ECMP rebalance. Choices:
|
|
Specifies the PIM Join Prune Interval in seconds. The range is from 60 to 600. |
|
Specifies the PIM Keepalive timer in seconds. The range is from 31 to 60000. |
|
Specifies the SSM prefix-list. |
|
Name of the VRF to which the PIM configurations belong. Default: |
|
The state of the configuration after module completion.
Choices:
|
Notes
Note
Supports
check_mode
.
Examples
# Using deleted
#
# Before State:
# -------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 60
# ip pim vrf VrfReg1 keep-alive-timer 180
# ip pim vrf VrfReg1 ssm prefix-list prefix-list-1
# ip pim vrf VrfReg2 ecmp
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# sonic#
- name: Delete specified global PIM configurations
dellemc.enterprise_sonic.sonic_pim_global:
config:
- vrf_name: 'VrfReg1'
join_prune_interval: 60
keepalive_timer: 180
- vrf_name: 'VrfReg2'
state: deleted
# After State:
# ------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 ssm prefix-list prefix-list-1
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# sonic#
# Using deleted
#
# Before State:
# -------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 60
# ip pim vrf VrfReg1 keep-alive-timer 180
# ip pim vrf VrfReg1 ssm prefix-list prefix-list-1
# ip pim vrf VrfReg2 ecmp
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# sonic#
- name: Delete all global PIM configurations
dellemc.enterprise_sonic.sonic_pim_global:
config:
state: deleted
# After State:
# ------------
#
# sonic# show running-configuration | grep "ip pim"
# sonic#
# Using merged
#
# Before State:
# -------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf default join-prune-interval 120
# ip pim vrf default keep-alive-timer 360
# ip pim vrf default ssm prefix-list prefix-list-1
# sonic#
- name: Merge provided global PIM configurations
dellemc.enterprise_sonic.sonic_pim_global:
config:
- vrf_name: 'default'
ecmp_enable: true
ecmp_rebalance_enable: true
join_prune_interval: 60
keepalive_timer: 180
ssm_prefix_list: 'prefix-list-def'
- vrf_name: 'VrfReg1'
join_prune_interval: 60
keepalive_timer: 180
- vrf_name: 'VrfReg2'
ssm_prefix_list: 'prefix-list-2'
state: merged
# After State:
# ------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 60
# ip pim vrf VrfReg1 keep-alive-timer 180
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# ip pim vrf default join-prune-interval 60
# ip pim vrf default keep-alive-timer 180
# ip pim vrf default ssm prefix-list prefix-list-def
# sonic#
# Using replaced
#
# Before State:
# -------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 60
# ip pim vrf VrfReg1 keep-alive-timer 180
# ip pim vrf VrfReg1 ssm prefix-list prefix-list-1
# ip pim vrf VrfReg2 ecmp
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# sonic#
- name: Replace global PIM configurations of specified VRFs
dellemc.enterprise_sonic.sonic_pim_global:
config:
- vrf_name: 'default'
ecmp_enable: true
- vrf_name: 'VrfReg1'
join_prune_interval: 120
keepalive_timer: 360
state: replaced
# After State:
# ------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 120
# ip pim vrf VrfReg1 keep-alive-timer 360
# ip pim vrf VrfReg2 ecmp
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# sonic#
# Using replaced
#
# Before State:
# -------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 60
# ip pim vrf VrfReg1 keep-alive-timer 180
# ip pim vrf VrfReg1 ssm prefix-list prefix-list-1
# ip pim vrf VrfReg2 ecmp
# ip pim vrf VrfReg2 ssm prefix-list prefix-list-2
# ip pim vrf default ecmp
# ip pim vrf default ecmp rebalance
# sonic#
- name: Override global PIM configurations
dellemc.enterprise_sonic.sonic_pim_global:
config:
- vrf_name: 'default'
ecmp_enable: true
- vrf_name: 'VrfReg1'
join_prune_interval: 120
keepalive_timer: 360
state: overridden
# After State:
# ------------
#
# sonic# show running-configuration | grep "ip pim"
# ip pim vrf VrfReg1 join-prune-interval 120
# ip pim vrf VrfReg1 keep-alive-timer 360
# ip pim vrf default ecmp
# sonic#
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The resulting configuration on module invocation. Returned: when changed Sample: |
|
The generated configuration on module invocation. Returned: when Sample: |
|
The configuration prior to the module invocation. Returned: always Sample: |
|
The set of commands pushed to the remote device. Returned: always Sample: |