cisco.ios.ios_ospfv3 – OSPFv3 resource module
Note
This plugin is part of the cisco.ios collection (version 2.6.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 cisco.ios
.
To use it in a playbook, specify: cisco.ios.ios_ospfv3
.
New in version 1.1.0: of cisco.ios
Synopsis
This module configures and manages the Open Shortest Path First (OSPF) version 3 on IOS platforms.
Parameters
Parameter |
Comments |
---|---|
A list of configurations for ospfv3. |
|
List of OSPF instance configurations. |
|
Enter Address Family command mode |
|
Control adjacency formation |
|
Disable adjacency staggering Choices:
|
|
Maximum number of adjacencies allowed to be forming Please refer vendor documentation for valid values |
|
Initial number of adjacencies allowed to be forming in an area Please refer vendor documentation for valid values |
|
No initial Choices:
|
|
Enter Address Family command mode Choices:
|
|
OSPF area parameters |
|
OSPF area ID as a decimal value. Please refer vendor documentation of Valid values. OSPF area ID in IP address format(e.g. A.B.C.D) |
|
Authentication parameters |
|
Use a key-chain for cryptographic authentication keys |
|
Use no authentication Choices:
|
|
Set the summary default-cost of a NSSA/stub area Stub’s advertised external route metric Note, please refer vendor documentation for respective valid values |
|
Filter networks between OSPFv3 areas |
|
The direction to apply on the filter networks sent to and from this area. Choices:
|
|
Name of an IP prefix-list |
|
Specify a normal area type Choices:
|
|
Specify a NSSA area |
|
Originate Type 7 default into NSSA area |
|
OSPF default metric |
|
OSPF metric type for default routes OSPF Link State type Choices:
|
|
Limit default advertisement to this NSSA area Choices:
|
|
No redistribution into this NSSA area Choices:
|
|
Do not send summary LSA into NSSA Choices:
|
|
Enable a NSSA area Choices:
|
|
Translate LSA Always translate LSAs on this ABR Suppress forwarding address in translated LSAs Choices:
|
|
Summarize routes matching address/mask (border routers only) |
|
IP address to match |
|
Advertise this range (default) Since, advertise when enabled is not shown in running-config idempotency won’t be maintained for the play in the second or next run of the play. Choices:
|
|
User specified metric for this range |
|
IP mask for address |
|
DoNotAdvertise this range Choices:
|
|
Define a sham link and its parameters |
|
Authentication parameters |
|
Use a key-chain for cryptographic authentication keys |
|
Use no authentication Choices:
|
|
Associate a cost with the sham-link Cost of the sham-link |
|
IPv6 address associated with sham-link destination (X:X:X:X::X) |
|
IPv6 address associated with sham-link source (X:X:X:X::X) |
|
TTL security check maximum number of hops allowed |
|
Specify a stub area Backbone can not be configured as stub area |
|
Do not send summary LSA into stub area Choices:
|
|
Enable a stub area Choices:
|
|
Authentication parameters Authentication operation mode |
|
Deployment mode of operation Choices:
|
|
Normal mode of operation Choices:
|
|
Calculate OSPF interface cost according to bandwidth |
|
Use reference bandwidth method to assign OSPF cost Note, refer vendor documentation for respective valid values |
|
Enable OSPF auto-cost Choices:
|
|
BFD configuration commands |
|
Enable BFD on all interfaces Choices:
|
|
Disable BFD on all interfaces Choices:
|
|
Enable a specific feature Do not perform PE specific checks Choices:
|
|
OSPFv3 router compatibility list |
|
compatible with RFC 1583 Choices:
|
|
compatible with RFC 1587 Choices:
|
|
supports DBD exchange optimization Choices:
|
|
Control distribution of default information |
|
Always advertise default route Choices:
|
|
OSPF default metric Note, refer vendor documentation for respective valid values |
|
OSPF metric type for default routes Note, please refer vendor documentation for respective valid range |
|
Distribute a default route Choices:
|
|
Route-map reference name |
|
Set metric of redistributed routes |
|
Enable or disable discard-route installation |
|
Discard route for summarised redistributed routes Choices:
|
|
Discard route for summarised inter-area routes Choices:
|
|
Discard route for sham-link routes Choices:
|
|
Define an administrative distance Note, please refer vendor documentation for respective valid range |
|
Filter networks in routing updates |
|
IP access list |
|
Filter incoming and outgoing routing updates. Choices:
|
|
Interface configuration (GigabitEthernet A/B) Valid with incoming traffic |
|
IP access list name/number |
|
Protocol config (bgp 1). Valid with outgoing traffic |
|
Filter prefixes in routing updates |
|
Filter incoming and outgoing routing updates. Choices:
|
|
Gateway name for filtering incoming updates based on gateway |
|
Interface configuration (GigabitEthernet A/B) Valid with incoming traffic |
|
Name of an IP prefix-list |
|
Protocol config (bgp 1). Valid with outgoing traffic |
|
Filter prefixes in routing updates |
|
Route-map name |
|
Event Logging |
|
Enable event Logging Choices:
|
|
Disable Logging When Log Buffer Becomes Full Choices:
|
|
Pause Event Logging Choices:
|
|
Maximum Number of Events Stored in the Event Log Note, refer vendor documentation for respective valid values |
|
Graceful-restart options helper support |
|
disable helper support Choices:
|
|
helper support enabled Choices:
|
|
enable helper strict LSA checking Choices:
|
|
Source of the interface ID |
|
IOS interface number Choices:
|
|
SNMP MIB ifIndex Choices:
|
|
Limit a specific OSPF feature |
|
Demand circuit retransmissions |
|
Disble the feature Choices:
|
|
The maximum number of retransmissions |
|
Non-demand-circuit retransmissions |
|
Disble the feature Choices:
|
|
The maximum number of retransmissions |
|
Enable or disable usage of local RIB as route criteria |
|
Enable usage of local RIB as route criteria Choices:
|
|
Local RIB used to validate external/NSSA forwarding addresses Choices:
|
|
Local RIB used as criteria for inter-area summaries Choices:
|
|
Local RIB used as criteria for NSSA translation Choices:
|
|
Log changes in adjacency state |
|
Log all state changes Choices:
|
|
Log changes in adjacency state Choices:
|
|
Specify MANET OSPF parameters |
|
Specify MANET cache sizes |
|
Specify MANET acknowledgement cache size Maximum number of acknowledgements in cache |
|
Specify MANET LSA cache size Maximum number of LSAs in cache |
|
Unicast Hellos rather than multicast |
|
Multicast Hello requests and responses rather than unicast Choices:
|
|
Unicast Hello requests and responses rather than multicast Choices:
|
|
MANET OSPF Smart Peering |
|
Disable selective peering Choices:
|
|
Select peers per interface rather than per node Choices:
|
|
Redundant paths Number of redundant OSPF paths |
|
Enable selective peering Choices:
|
|
Specify and Relay willingness value |
|
Maximum number of non self-generated LSAs to accept |
|
Maximum number of times adjacencies can be suppressed Note, refer vendor documentation for respective valid values |
|
Number of minutes during which all adjacencies are suppressed Note, refer vendor documentation for respective valid values |
|
Maximum number of non self-generated LSAs to accept Note, refer vendor documentation for respective valid values |
|
Number of minutes after which ignore-count is reset to zero Note, refer vendor documentation for respective valid values |
|
Threshold value (%) at which to generate a warning msg Note, refer vendor documentation for respective valid values |
|
Only give a warning message when limit is exceeded Choices:
|
|
Set maximum metric Maximum metric in self-originated router-LSAs |
|
disable maximum metric in self-originated router-LSAs Choices:
|
|
Override external-lsa metric with max-metric value Overriding metric in external-LSAs Note, refer vendor documentation for respective valid values |
|
Override inter-area-lsas metric with max-metric value Overriding metric in inter-area-LSAs Note, refer vendor documentation for respective valid values |
|
Set maximum metric temporarily after reboot |
|
Time, in seconds, router-LSAs are originated with max-metric Note, please refer vendor documentation for respective valid range |
|
Let BGP decide when to originate router-LSA with normal metric Choices:
|
|
Set maximum metric for stub links in prefix LSAs Choices:
|
|
Forward packets over multiple paths Number of paths |
|
Suppress routing updates on an interface |
|
Prefix suppression |
|
Disable prefix suppression Choices:
|
|
Enable prefix suppression Choices:
|
|
Hello/Router process queue depth |
|
OSPF Hello process queue depth |
|
maximum number of packets in the queue |
|
Unlimited queue depth Choices:
|
|
OSPF Router process queue depth |
|
maximum number of packets in the queue |
|
Unlimited queue depth Choices:
|
|
Router-id address for this OSPF process OSPF router-id in IP address format (A.B.C.D) |
|
Shutdown the router process |
|
Disable Shutdown Choices:
|
|
Shutdown the router process Choices:
|
|
Configure IP address summaries |
|
IP summary address (A.B.C.D) IP prefix <network>/<length> (A.B.C.D/nn) |
|
IP Summary mask |
|
Do not advertise or translate Choices:
|
|
Limit summary to NSSA areas Choices:
|
|
Set tag |
|
Adjust routing timers |
|
OSPF LSA timers, arrival timer The minimum interval in milliseconds between accepting the same LSA Note, refer vendor documentation for respective valid values |
|
OSPF MANET timers |
|
Specify MANET cache sizes |
|
Specify MANET acknowledgement cache size |
|
Specify MANET LSA cache size |
|
Unicast Hellos rather than multicast Unicast Hello requests and responses rather than multicast Choices:
|
|
MANET OSPF Smart Peering |
|
Select peers per interface rather than per node Choices:
|
|
Redundant paths Number of redundant OSPF paths |
|
Enable selective peering Choices:
|
|
Specify and Relay willingness value |
|
OSPF pacing timers |
|
OSPF flood pacing timer The minimum interval in msec to pace limit flooding on interface Note, refer vendor documentation for respective valid values |
|
OSPF LSA group pacing timer Interval in sec between group of LSA being refreshed or maxaged Note, refer vendor documentation for respective valid values |
|
OSPF retransmission pacing timer The minimum interval in msec between neighbor retransmissions Note, refer vendor documentation for respective valid values |
|
OSPF throttle timers |
|
OSPF LSA throttle timers |
|
Delay to generate first occurrence of LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
Maximum delay between originating the same LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
Minimum delay between originating the same LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
OSPF SPF throttle timers - Delay between receiving a change to SPF calculation in milliseconds - Note, refer vendor documentation for respective valid values |
|
Delay between first and second SPF calculation in milliseconds Note, refer vendor documentation for respective valid values |
|
Maximum wait time in milliseconds for SPF calculations Note, refer vendor documentation for respective valid values |
|
Delay between receiving a change to SPF calculation in milliseconds Note, refer vendor documentation for respective valid values |
|
Address Family modifier Choices:
|
|
Specify parameters for a VPN Routing/Forwarding instance |
|
Control adjacency formation |
|
Maximum number of adjacencies allowed to be forming Please refer vendor documentation for valid values |
|
Initial number of adjacencies allowed to be forming in an area Please refer vendor documentation for valid values |
|
No initial Choices:
|
|
OSPF area parameters |
|
OSPF area ID as a decimal value. Please refer vendor documentation of Valid values. OSPF area ID in IP address format(e.g. A.B.C.D) |
|
Authentication parameters |
|
Use IPsec authentication |
|
SHA-1 key (40 chars) |
|
Use MD5 authentication |
|
Use SHA-1 authentication |
|
Set the SPI (Security Parameters Index) |
|
Use a key-chain for cryptographic authentication keys |
|
Set the summary default-cost of a NSSA/stub area Stub’s advertised external route metric Note, please refer vendor documentation for respective valid values |
|
Specify a NSSA area |
|
Originate Type 7 default into NSSA area |
|
OSPF default metric |
|
OSPF metric type for default routes OSPF Link State type Choices:
|
|
Limit default advertisement to this NSSA area Choices:
|
|
No redistribution into this NSSA area Choices:
|
|
Do not send summary LSA into NSSA Choices:
|
|
Enable a NSSA area Choices:
|
|
Translate LSA Always translate LSAs on this ABR Suppress forwarding address in translated LSAs Choices:
|
|
Specify a stub area Backbone can not be configured as stub area |
|
Do not send summary LSA into stub area Choices:
|
|
Enable a stub area Choices:
|
|
Authentication parameter mode Deployment mode of operation Choices:
|
|
Calculate OSPF interface cost according to bandwidth |
|
Use reference bandwidth method to assign OSPF cost Note, refer vendor documentation for respective valid values |
|
Enable OSPF auto-cost Choices:
|
|
BFD configuration commands Enable BFD on all interfaces Choices:
|
|
OSPFv3 router compatibility list |
|
compatible with RFC 1583 Choices:
|
|
compatible with RFC 1587 Choices:
|
|
supports DBD exchange optimization Choices:
|
|
Event Logging |
|
Enable event Logging Choices:
|
|
Disable Logging When Log Buffer Becomes Full Choices:
|
|
Pause Event Logging Choices:
|
|
Maximum Number of Events Stored in the Event Log Note, refer vendor documentation for respective valid values |
|
Graceful-restart options for helper support |
|
disable helper support Choices:
|
|
enable helper strict LSA checking Choices:
|
|
Description of the interactive help system Choices:
|
|
Source of the interface ID SNMP MIB ifIndex Choices:
|
|
Limit a specific OSPF feature and LS update, DBD, and LS request retransmissions |
|
Demand circuit retransmissions |
|
Disable the feature Choices:
|
|
The maximum number of retransmissions |
|
Non-demand-circuit retransmissions |
|
Disable the feature Choices:
|
|
The maximum number of retransmissions |
|
Enable or disable usage of local RIB as route criteria |
|
Enable usage of local RIB as route criteria Choices:
|
|
Local RIB used to validate external/NSSA forwarding addresses Choices:
|
|
Local RIB used as criteria for inter-area summaries Choices:
|
|
Local RIB used as criteria for NSSA translation Choices:
|
|
Log changes in adjacency state |
|
Log all state changes Choices:
|
|
Log changes in adjacency state Choices:
|
|
Specify MANET OSPF parameters |
|
Specify MANET cache sizes |
|
Specify MANET acknowledgement cache size |
|
Specify MANET LSA cache size |
|
Unicast Hellos rather than multicast Unicast Hello requests and responses rather than multicast Choices:
|
|
MANET OSPF Smart Peering |
|
Select peers per interface rather than per node Choices:
|
|
Redundant paths Number of redundant OSPF paths |
|
Enable selective peering Choices:
|
|
Specify and Relay willingness value |
|
Maximum number of non self-generated LSAs to accept |
|
Maximum number of times adjacencies can be suppressed Note, refer vendor documentation for respective valid values |
|
Number of minutes during which all adjacencies are suppressed Note, refer vendor documentation for respective valid values |
|
Maximum number of non self-generated LSAs to accept Note, refer vendor documentation for respective valid values |
|
Number of minutes after which ignore-count is reset to zero Note, refer vendor documentation for respective valid values |
|
Threshold value (%) at which to generate a warning msg Note, refer vendor documentation for respective valid values |
|
Only give a warning message when limit is exceeded Choices:
|
|
Set maximum metric |
|
Override external-lsa metric with max-metric value Overriding metric in external-LSAs Note, refer vendor documentation for respective valid values |
|
Set maximum metric for stub links in router-LSAs Choices:
|
|
Set maximum metric temporarily after reboot |
|
Time, in seconds, router-LSAs are originated with max-metric Note, please refer vendor documentation for respective valid range |
|
Let BGP decide when to originate router-LSA with normal metric Choices:
|
|
Maximum metric in self-originated router-LSAs Choices:
|
|
Override summary-lsa metric with max-metric value Note, please refer vendor documentation for respective valid range |
|
Suppress routing updates on an interface |
|
Enable prefix suppression Choices:
|
|
Process ID |
|
Hello/Router process queue depth |
|
OSPF Hello process queue depth |
|
maximum number of packets in the queue |
|
Unlimited queue depth Choices:
|
|
Router-id address for this OSPF process OSPF router-id in IP address format (A.B.C.D) |
|
Shutdown the router process Choices:
|
|
Adjust routing timers |
|
OSPF LSA timers, arrival timer The minimum interval in milliseconds between accepting the same LSA Note, refer vendor documentation for respective valid values |
|
OSPF MANET timers |
|
Specify MANET cache sizes |
|
Specify MANET acknowledgement cache size |
|
Specify MANET LSA cache size |
|
Unicast Hellos rather than multicast Unicast Hello requests and responses rather than multicast Choices:
|
|
MANET OSPF Smart Peering |
|
Select peers per interface rather than per node Choices:
|
|
Redundant paths Number of redundant OSPF paths |
|
Enable selective peering Choices:
|
|
Specify and Relay willingness value |
|
OSPF pacing timers |
|
OSPF flood pacing timer The minimum interval in msec to pace limit flooding on interface Note, refer vendor documentation for respective valid values |
|
OSPF LSA group pacing timer Interval in sec between group of LSA being refreshed or maxaged Note, refer vendor documentation for respective valid values |
|
OSPF retransmission pacing timer The minimum interval in msec between neighbor retransmissions Note, refer vendor documentation for respective valid values |
|
OSPF throttle timers |
|
OSPF LSA throttle timers |
|
Delay to generate first occurrence of LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
Maximum delay between originating the same LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
Minimum delay between originating the same LSA in milliseconds Note, refer vendor documentation for respective valid values |
|
OSPF SPF throttle timers - Delay between receiving a change to SPF calculation in milliseconds - Note, refer vendor documentation for respective valid values |
|
Delay between first and second SPF calculation in milliseconds Note, refer vendor documentation for respective valid values |
|
Maximum wait time in milliseconds for SPF calculations Note, refer vendor documentation for respective valid values |
|
Delay between receiving a change to SPF calculation in milliseconds Note, refer vendor documentation for respective valid values |
|
This option is used only with state parsed. The value of this option should be the output received from the IOS device by executing the command sh running-config | section ^router ospfv3. The state parsed reads the configuration from |
|
The state the configuration should be left in The states rendered, gathered and parsed does not perform any change on the device. The state rendered will transform the configuration in The state gathered will fetch the running configuration from device and transform it into structured data in the format as per the resource module argspec and the value is returned in the gathered key within the result. The state parsed reads the configuration from Choices:
|
Notes
Note
Tested against Cisco IOSv Version 15.2 on VIRL.
This module works with connection
network_cli
. See https://docs.ansible.com/ansible/latest/network/user_guide/platform_ios.html
Examples
# Using deleted
# Before state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Delete provided OSPF V3 processes
cisco.ios.ios_ospfv3:
config:
processes:
- process_id: 1
state: deleted
# Commands Fired:
# ---------------
#
# "commands": [
# "no router ospfv3 1"
# ]
# After state:
# -------------
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
# Using deleted without any config passed (NOTE: This will delete all OSPFV3 configuration from device)
# Before state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Delete all OSPF processes
cisco.ios.ios_ospfv3:
state: deleted
# Commands Fired:
# ---------------
#
# "commands": [
# "no router ospfv3 200",
# "no router ospfv3 1"
# ]
# After state:
# -------------
# router-ios#sh running-config | section ^router ospfv3
# router-ios#
# Using merged
# Before state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router-ios#
- name: Merge provided OSPFV3 configuration
cisco.ios.ios_ospfv3:
config:
processes:
- process_id: 1
max_metric:
router_lsa: true
on_startup:
time: 110
address_family:
- afi: ipv4
unicast: true
vrf: blue
adjacency:
min_adjacency: 50
max_adjacency: 50
areas:
- area_id: 25
nssa:
default_information_originate:
metric: 25
nssa_only: true
areas:
- area_id: "10"
nssa:
default_information_originate:
metric: 10
timers:
throttle:
lsa:
first_delay: 12
min_delay: 14
max_delay: 16
- process_id: 200
address_family:
- afi: ipv4
unicast: true
adjacency:
min_adjacency: 200
max_adjacency: 200
max_metric:
router_lsa: true
on_startup:
time: 100
auto_cost:
reference_bandwidth: 4
state: merged
# Commands Fired:
# ---------------
#
# "commands": [
# "router ospfv3 1",
# "max-metric router-lsa on-startup 110",
# "area 10 nssa default-information-originate metric 10",
# "address-family ipv4 unicast vrf blue",
# "adjacency stagger 50 50",
# "area 25 nssa default-information-originate metric 25 nssa-only",
# "exit-address-family",
# "router ospfv3 200",
# "auto-cost reference-bandwidth 4",
# "max-metric router-lsa on-startup 100",
# "address-family ipv4 unicast",
# "adjacency stagger 200 200",
# "exit-address-family"
# ]
# After state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
# Using overridden
# Before state:
# -------------
#
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Override provided OSPFV3 configuration
cisco.ios.ios_ospfv3:
config:
processes:
- process_id: 200
max_metric:
router_lsa: true
on_startup:
time: 200
address_family:
- afi: ipv4
unicast: true
adjacency:
min_adjacency: 50
max_adjacency: 50
areas:
- area_id: 200
nssa:
default_information_originate:
metric: 200
nssa_only: true
areas:
- area_id: "10"
nssa:
default_information_originate:
metric: 10
state: overridden
# Commands Fired:
# ---------------
#
# "commands": [
# "no router ospfv3 1",
# "router ospfv3 200",
# "no auto-cost reference-bandwidth 4",
# "max-metric router-lsa on-startup 200",
# "area 10 nssa default-information-originate metric 10",
# "address-family ipv4 unicast",
# "adjacency stagger 50 50",
# "area 200 nssa default-information-originate metric 200 nssa-only",
# "exit-address-family"
# ]
# After state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 200
# max-metric router-lsa on-startup 200
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast
# adjacency stagger 50 50
# area 200 nssa default-information-originate metric 200 nssa-only
# exit-address-family
# Using replaced
# Before state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Replaced provided OSPFV3 configuration
cisco.ios.ios_ospfv3:
config:
processes:
- process_id: 200
max_metric:
router_lsa: true
on_startup:
time: 200
address_family:
- afi: ipv4
unicast: true
adjacency:
min_adjacency: 50
max_adjacency: 50
areas:
- area_id: 200
nssa:
default_information_originate:
metric: 200
nssa_only: true
areas:
- area_id: "10"
nssa:
default_information_originate:
metric: 10
state: replaced
# Commands Fired:
# ---------------
# "commands": [
# "router ospfv3 200",
# "no auto-cost reference-bandwidth 4",
# "max-metric router-lsa on-startup 200",
# "area 10 nssa default-information-originate metric 10",
# "address-family ipv4 unicast",
# "adjacency stagger 50 50",
# "area 200 nssa default-information-originate metric 200 nssa-only",
# "exit-address-family"
# ]
# After state:
# -------------
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 200
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast
# adjacency stagger 50 50
# area 200 nssa default-information-originate metric 200 nssa-only
# exit-address-family
# Using Gathered
# Before state:
# -------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Gather OSPFV3 provided configurations
cisco.ios.ios_ospfv3:
config:
state: gathered
# Module Execution Result:
# ------------------------
#
# "gathered": {
# "processes": [
# {
# "address_family": [
# {
# "adjacency": {
# "max_adjacency": 50,
# "min_adjacency": 50
# },
# "afi": "ipv4",
# "areas": [
# {
# "area_id": "25",
# "nssa": {
# "default_information_originate": {
# "metric": 25,
# "nssa_only": true
# }
# }
# }
# ],
# "unicast": true,
# "vrf": "blue"
# }
# ],
# "areas": [
# {
# "area_id": "10",
# "nssa": {
# "default_information_originate": {
# "metric": 10
# }
# }
# }
# ],
# "max_metric": {
# "on_startup": {
# "time": 110
# },
# "router_lsa": true
# },
# "process_id": 1
# },
# {
# "address_family": [
# {
# "adjacency": {
# "max_adjacency": 200,
# "min_adjacency": 200
# },
# "afi": "ipv4",
# "unicast": true
# }
# ],
# "auto_cost": {
# "reference_bandwidth": 4
# },
# "max_metric": {
# "on_startup": {
# "time": 100
# },
# "router_lsa": true
# },
# "process_id": 200
# }
# ]
# }
# After state:
# ------------
#
# router-ios#sh running-config | section ^router ospfv3
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
# Using Rendered
- name: Render the commands for provided configuration
cisco.ios.ios_ospfv3:
config:
processes:
- process_id: 1
max_metric:
router_lsa: true
on_startup:
time: 110
address_family:
- afi: ipv4
unicast: true
vrf: blue
adjacency:
min_adjacency: 50
max_adjacency: 50
areas:
- area_id: 25
nssa:
default_information_originate:
metric: 25
nssa_only: true
areas:
- area_id: "10"
nssa:
default_information_originate:
metric: 10
timers:
throttle:
lsa:
first_delay: 12
min_delay: 14
max_delay: 16
- process_id: 200
address_family:
- afi: ipv4
unicast: true
adjacency:
min_adjacency: 200
max_adjacency: 200
max_metric:
router_lsa: true
on_startup:
time: 100
auto_cost:
reference_bandwidth: 4
state: rendered
# Module Execution Result:
# ------------------------
#
# "rendered": [
# "router ospfv3 1",
# "max-metric router-lsa on-startup 110",
# "area 10 nssa default-information-originate metric 10",
# "address-family ipv4 unicast vrf blue",
# "adjacency stagger 50 50",
# "area 25 nssa default-information-originate metric 25 nssa-only",
# "exit-address-family",
# "router ospfv3 200",
# "auto-cost reference-bandwidth 4",
# "max-metric router-lsa on-startup 100",
# "address-family ipv4 unicast",
# "adjacency stagger 200 200",
# "exit-address-family"
# ]
# Using Parsed
# File: parsed.cfg
# ----------------
#
# router ospfv3 1
# max-metric router-lsa on-startup 110
# area 10 nssa default-information-originate metric 10
# !
# address-family ipv4 unicast vrf blue
# adjacency stagger 50 50
# area 25 nssa default-information-originate metric 25 nssa-only
# exit-address-family
# router ospfv3 200
# max-metric router-lsa on-startup 100
# auto-cost reference-bandwidth 4
# !
# address-family ipv4 unicast
# adjacency stagger 200 200
# exit-address-family
- name: Parse the provided configuration with the existing running configuration
cisco.ios.ios_ospfv3:
running_config: "{{ lookup('file', 'parsed.cfg') }}"
state: parsed
# Module Execution Result:
# ------------------------
#
# "parsed": {
# "processes": [
# {
# "address_family": [
# {
# "adjacency": {
# "max_adjacency": 50,
# "min_adjacency": 50
# },
# "afi": "ipv4",
# "areas": [
# {
# "area_id": "25",
# "nssa": {
# "default_information_originate": {
# "metric": 25,
# "nssa_only": true
# }
# }
# }
# ],
# "unicast": true,
# "vrf": "blue"
# }
# ],
# "areas": [
# {
# "area_id": "10",
# "nssa": {
# "default_information_originate": {
# "metric": 10
# }
# }
# }
# ],
# "max_metric": {
# "on_startup": {
# "time": 110
# },
# "router_lsa": true
# },
# "process_id": 1
# }
# ]
# }
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
The resulting configuration model invocation. Returned: when changed Sample: “The configuration returned will always be in the same format\n of the parameters above.\n” |
|
The configuration prior to the model invocation. Returned: always Sample: “The configuration returned will always be in the same format\n of the parameters above.\n” |
|
The set of commands pushed to the remote device. Returned: always Sample: [“router ospfv3 1”, “address-family ipv4 unicast vrf blue”, “adjacency stagger 50 50”] |
Authors
Sumit Jaiswal (@justjais)