W3cubDocs

/Ansible

arista.eos.eos_ospfv3 – OSPFv3 resource module

Note

This plugin is part of the arista.eos collection (version 2.2.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 arista.eos.

To use it in a playbook, specify: arista.eos.eos_ospfv3.

New in version 1.1.0: of arista.eos

Synopsis

  • This module configures and manages the attributes of ospfv3 on Arista EOS platforms.

Note

This module has a corresponding action plugin.

Parameters

Parameter Choices/Defaults Comments
config
dictionary
A list of configurations for ospfv3.
processes
list / elements=dictionary
A list of dictionary specifying the ospfv3 processes.
address_family
list / elements=dictionary
Enable address family and enter its config mode
adjacency
dictionary
Configure adjacency options for OSPF instance.
exchange_start
dictionary
Configure exchange-start options for OSPF instance.
threshold
integer
Number of peers to bring up simultaneously.
afi
string
    Choices:
  • ipv4
  • ipv6
address family .
areas
list / elements=dictionary
Specifies the configuration for OSPF areas
area_id
string
Specifies a 32 bit number expressed in decimal or dotted-decimal notation.
authentication
dictionary
Configure authentication for the area incase of ospfv3.
algorithm
string
    Choices:
  • md5
  • sha1
Name of algorithm to be used.
encrypt_key
boolean
    Choices:
  • no
  • yes
If False, key string is not encrypted
hidden_key
boolean
    Choices:
  • no
  • yes
If True, Specifies that a HIDDEN key will follow.
key
string
128 bit MD5 key or 140 bit SHA1 key.
passphrase
string
Passphrase String for deriving keys for authentication and encryption.
spi
integer
Specify the SPI value
default_cost
integer
Specify the cost for default summary route in stub/NSSA area.
encryption
dictionary
Configure encryption for the area
algorithm
string
    Choices:
  • sha1
  • md5
name of the algorithm to be used.
encrypt_key
boolean
    Choices:
  • no
  • yes
If False, key string is not encrypted
encryption
string
    Choices:
  • 3des-cbc
  • aes-128-cbc
  • aes-192-cbc
  • aes-256-cbc
  • null
name of encryption to be used.
hidden_key
boolean
    Choices:
  • no
  • yes
If True, Specifies that a HIDDEN key will follow.
key
string
128 bit MD5 key or 140 bit SHA1 key.
passphrase
string
Passphrase String for deriving keys for authentication and encryption.
spi
integer
Specify the SPI value
nssa
dictionary
Configures NSSA parameters.
default_information_originate
dictionary
Originate default Type 7 LSA.
metric
integer
Metric for default route.
metric_type
integer
Metric type for default route.
nssa_only
boolean
    Choices:
  • no
  • yes
Limit default advertisement to this NSSA area.
set
boolean
    Choices:
  • no
  • yes
True if only default information orignate is set
no_summary
boolean
    Choices:
  • no
  • yes
Filter all type-3 LSAs in the nssa area.
nssa_only
boolean
    Choices:
  • no
  • yes
Disable Type-7 LSA p-bit setting
set
boolean
    Choices:
  • no
  • yes
True if only nssa is set
translate
boolean
    Choices:
  • no
  • yes
Enable LSA translation.
ranges
list / elements=dictionary
Configure route summarization.
address
string
IP address.
advertise
boolean
    Choices:
  • no
  • yes
Enable Advertisement of the range.
cost
integer
Configures the metric.
subnet_address
string
IP address with mask length
subnet_mask
string
IP subnet mask
stub
dictionary
Stub area.
set
boolean
    Choices:
  • no
  • yes
True if only stub is set
summary_lsa
boolean
    Choices:
  • no
  • yes
If False , Filter all type-3 LSAs in the stub area.
auto_cost
dictionary
Set auto-cost.
reference_bandwidth
integer
reference bandwidth in megabits per sec.
bfd
dictionary
Enable BFD.
all_interfaces
boolean
    Choices:
  • no
  • yes
Enable BFD on all interfaces.
default_information
dictionary
Control distribution of default information.
always
boolean
    Choices:
  • no
  • yes
Always advertise default route.
metric
integer
Metric for default route.
metric_type
integer
Metric type for default route.
originate
boolean
    Choices:
  • no
  • yes
Distribute a default route.
route_map
string
Specify which route-map to use.
default_metric
integer
Configure the default metric for redistributed routes.
distance
integer
Specifies the administrative distance for routes.
fips_restrictions
boolean
    Choices:
  • no
  • yes
Use FIPS compliant algorithms
graceful_restart
dictionary
Enable graceful restart mode.
grace_period
integer
Specify maximum time to wait for graceful-restart to complete.
set
boolean
    Choices:
  • no
  • yes
When true sets the grace_fulrestart config alone.
graceful_restart_helper
boolean
    Choices:
  • no
  • yes
If True, Enable graceful restart helper.
log_adjacency_changes
dictionary
To configure link-state changes and transitions of OSPFv3 neighbors.
detail
boolean
    Choices:
  • no
  • yes
If true , configures the switch to log all link-state changes.
set
boolean
    Choices:
  • no
  • yes
When true sets the log_adjacency_changes config alone.
max_metric
dictionary
Set maximum metric.
router_lsa
dictionary
Maximum metric in self-originated router-LSAs.
external_lsa
dictionary
Override external-lsa metric with max-metric value.
max_metric_value
integer
Set max metric value for external LSAs.
set
boolean
    Choices:
  • no
  • yes
Set external-lsa attribute.
include_stub
boolean
    Choices:
  • no
  • yes
Set maximum metric for stub links in router-LSAs.
on_startup
dictionary
Set maximum metric temporarily after reboot.
wait_for_bgp
boolean
    Choices:
  • no
  • yes
Let BGP decide when to originate router-LSA with normal metric
wait_period
integer
Wait period in seconds after startup.
set
boolean
    Choices:
  • no
  • yes
Set router-lsa attribute.
summary_lsa
dictionary
Override summary-lsa metric with max-metric value.
max_metric_value
integer
Set max metric value for external LSAs.
set
boolean
    Choices:
  • no
  • yes
Set external-lsa attribute.
maximum_paths
integer
Maximum number of next-hops in an ECMP route.
passive_interface
boolean
    Choices:
  • no
  • yes
Include interface but without actively running OSPF.
redistribute
list / elements=dictionary
Specifies the routes to be redistributed.
route_map
string
Specify which route map to use.
routes
string
    Choices:
  • bgp
  • connected
  • static
Route types (BGP,static,connected)
router_id
string
32-bit number assigned to a router running OSPFv3.
shutdown
boolean
    Choices:
  • no
  • yes
Disable the OSPF instance.
timers
dictionary
Configure OSPF timers.
lsa
integer
Configure OSPF LSA timers.
out_delay
integer
Configure out-delay timer.
pacing
integer
Configure OSPF packet pacing.
throttle
dictionary
Configure SPF timers
initial
integer
Initial SPF schedule delay in msecs.
lsa
boolean
    Choices:
  • no
  • yes
Configure threshold for retransmission of lsa
max
integer
Max wait time between two SPFs in msecs.
min
integer
Min Hold time between two SPFs in msecs
spf
boolean
    Choices:
  • no
  • yes
Configure time between SPF calculations
adjacency
dictionary
Configure adjacency options for OSPF instance.
exchange_start
dictionary
Configure exchange-start options for OSPF instance.
threshold
integer
Number of peers to bring up simultaneously.
areas
list / elements=dictionary
Specifies the configuration for OSPF areas
area_id
string
Specifies a 32 bit number expressed in decimal or dotted-decimal notation.
authentication
dictionary
Configure authentication for the area incase of ospfv3.
algorithm
string
    Choices:
  • md5
  • sha1
Name of algorithm to be used.
encrypt_key
boolean
    Choices:
  • no
  • yes
If False, key string is not encrypted
hidden_key
boolean
    Choices:
  • no
  • yes
If True, Specifies that a HIDDEN key will follow.
key
string
128 bit MD5 key or 140 bit SHA1 key.
passphrase
string
Passphrase String for deriving keys for authentication and encryption.
spi
integer
Specify the SPI value
default_cost
integer
Specify the cost for default summary route in stub/NSSA area.
encryption
dictionary
Configure encryption for the area
algorithm
string
    Choices:
  • sha1
  • md5
name of the algorithm to be used.
encrypt_key
boolean
    Choices:
  • no
  • yes
If False, key string is not encrypted
encryption
string
    Choices:
  • 3des-cbc
  • aes-128-cbc
  • aes-192-cbc
  • aes-256-cbc
  • null
name of encryption to be used.
hidden_key
boolean
    Choices:
  • no
  • yes
If True, Specifies that a HIDDEN key will follow.
key
string
128 bit MD5 key or 140 bit SHA1 key.
passphrase
string
Passphrase String for deriving keys for authentication and encryption.
spi
integer
Specify the SPI value
nssa
dictionary
Configures NSSA parameters.
default_information_originate
dictionary
Originate default Type 7 LSA.
metric
integer
Metric for default route.
metric_type
integer
Metric type for default route.
nssa_only
boolean
    Choices:
  • no
  • yes
Limit default advertisement to this NSSA area.
set
boolean
    Choices:
  • no
  • yes
True if only default information orignate is set
no_summary
boolean
    Choices:
  • no
  • yes
Filter all type-3 LSAs in the nssa area.
nssa_only
boolean
    Choices:
  • no
  • yes
Disable Type-7 LSA p-bit setting
set
boolean
    Choices:
  • no
  • yes
True if only nssa is set
translate
boolean
    Choices:
  • no
  • yes
Enable LSA translation.
stub
dictionary
Stub area.
set
boolean
    Choices:
  • no
  • yes
True if only stub is set.
summary_lsa
boolean
    Choices:
  • no
  • yes
If False , Filter all type-3 LSAs in the stub area.
auto_cost
dictionary
Set auto-cost.
reference_bandwidth
integer
reference bandwidth in megabits per sec.
bfd
dictionary
Enable BFD.
all_interfaces
boolean
    Choices:
  • no
  • yes
Enable BFD on all interfaces.
fips_restrictions
boolean
    Choices:
  • no
  • yes
Use FIPS compliant algorithms
graceful_restart
dictionary
Enable graceful restart mode.
grace_period
integer
Specify maximum time to wait for graceful-restart to complete.
set
boolean
    Choices:
  • no
  • yes
When true sets the grace_fulrestart config alone.
graceful_restart_helper
boolean
    Choices:
  • no
  • yes
If True, Enable graceful restart helper.
log_adjacency_changes
dictionary
To configure link-state changes and transitions of OSPFv3 neighbors.
detail
boolean
    Choices:
  • no
  • yes
If true , configures the switch to log all link-state changes.
set
boolean
    Choices:
  • no
  • yes
When true sets the log_adjacency_changes config alone.
max_metric
dictionary
Set maximum metric.
router_lsa
dictionary
Maximum metric in self-originated router-LSAs.
external_lsa
dictionary
Override external-lsa metric with max-metric value.
max_metric_value
integer
Set max metric value for external LSAs.
set
boolean
    Choices:
  • no
  • yes
Set external-lsa attribute.
include_stub
boolean
    Choices:
  • no
  • yes
Set maximum metric for stub links in router-LSAs.
on_startup
dictionary
Set maximum metric temporarily after reboot.
wait_for_bgp
boolean
    Choices:
  • no
  • yes
Let BGP decide when to originate router-LSA with normal metric
wait_period
integer
Wait period in seconds after startup.
set
boolean
    Choices:
  • no
  • yes
Set router-lsa attribute.
summary_lsa
dictionary
Override summary-lsa metric with max-metric value.
max_metric_value
integer
Set max metric value for external LSAs.
set
boolean
    Choices:
  • no
  • yes
Set external-lsa attribute.
passive_interface
boolean
    Choices:
  • no
  • yes
Include interface but without actively running OSPF.
router_id
string
32-bit number assigned to a router running OSPFv3.
shutdown
boolean
    Choices:
  • no
  • yes
Disable the OSPF instance.
timers
dictionary
Configure OSPF timers.
lsa
integer
Configure OSPF LSA timers.
out_delay
integer
Configure out-delay timer.
pacing
integer
Configure OSPF packet pacing.
throttle
dictionary
Configure SPF timers
initial
integer
Initial SPF schedule delay in msecs.
lsa
boolean
    Choices:
  • no
  • yes
Configure threshold for retransmission of lsa
max
integer
Max wait time between two SPFs in msecs.
min
integer
Min Hold time between two SPFs in msecs
spf
boolean
    Choices:
  • no
  • yes
Configure time between SPF calculations
vrf
string
VRF name .
running_config
string
This option is used only with state parsed.
The value of this option should be the output received from the EOS device by executing the command show running-config | section ospfv3.
The state parsed reads the configuration from running_config option and transforms it into Ansible structured data as per the resource module's argspec and the value is then returned in the parsed key within the result.
state
string
    Choices:
  • deleted
  • merged
  • overridden
  • replaced
  • gathered
  • rendered
  • parsed
The state the configuration should be left in.

Notes

Note

  • Tested against Arista EOS 4.23.0F
  • This module works with connection network_cli. See the EOS Platform Options.

Examples

# Using merged

# Before state

# veos#show running-config | section ospfv3
# veos#


  -  arista.eos.eos_ospfv3:
      config:
        processes:
          - address_family:
              - timers:
                  lsa: 22
                graceful_restart:
                  grace_period: 35
                afi: "ipv6"
            timers:
              pacing: 55
            fips_restrictions: True
            router_id: "2.2.2.2"
            vrf: "vrfmerge"


# After state

# veos#show running-config | section ospfv3
# router ospfv3 vrf vrfmerge
#    router-id 2.2.2.2
#    fips restrictions
#    timers pacing flood 55
#    !
#    address-family ipv6
#       fips restrictions
#       timers lsa arrival 22
#       graceful-restart grace-period 35
# veos#

# Module Execution
#     "after": {
#         "processes": [
#             {
#                 "address_family": [
#                     {
#                         "afi": "ipv6",
#                         "fips_restrictions": true,
#                         "graceful_restart": {
#                             "grace_period": 35
#                         },
#                         "timers": {
#                             "lsa": 22
#                         }
#                     }
#                 ],
#                 "fips_restrictions": true,
#                 "router_id": "2.2.2.2",
#                 "timers": {
#                     "pacing": 55
#                 },
#                 "vrf": "vrfmerge"
#             }
#         ]
#     },
#     "before": {},
#     "changed": true,
#     "commands": [
#         "router ospfv3 vrf vrfmerge",
#         "address-family ipv6",
#         "graceful-restart grace-period 35",
#         "timers lsa arrival 22",
#         "exit",
#         "timers pacing flood 55",
#         "fips restrictions",
#         "router-id 2.2.2.2",
#         "exit"
#     ],


# using replaced

# before state

# veos#show running-config | section ospfv3
# router ospfv3
#    fips restrictions
#    area 0.0.0.0 encryption ipsec spi 43 esp null md5 passphrase 7 h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4=
# !
# router ospfv3 vrf vrfmerge
#    router-id 2.2.2.2
#    fips restrictions
#    timers pacing flood 55
#    !
#    address-family ipv6
#       fips restrictions
#       timers lsa arrival 22
#       graceful-restart grace-period 35
# veos#


  - arista.eos.eos_ospfv3:
      config:
        processes:
          - areas:
              - area_id: "0.0.0.0"
                encryption:
                  spi: 43
                  encryption: "null"
                  algorithm: "md5"
                  encrypt_key: False
                  passphrase: "7hl8FV3lZ6H1mAKpjL47hQ=="
            vrf: "default"
            address_family:
              - afi: "ipv4"
                router_id: "7.1.1.1"
      state: replaced

# After state
# veos#show running-config | section ospfv3
# router ospfv3
#    area 0.0.0.0 encryption ipsec spi 43 esp null md5 passphrase 7 h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4=
# !
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#

# Module execution

# "after": {
#     "processes": [
#         {
#             "areas": [
#                 {
#                     "area_id": "0.0.0.0",
#                     "encryption": {
#                         "algorithm": "md5",
#                         "encryption": "null",
#                         "hidden_key": true,
#                         "passphrase": "h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4="
#                     }
#                 }
#             ],
#             "vrf": "default"
#         },
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "before": {
#     "processes": [
#         {
#             "areas": [
#                 {
#                     "area_id": "0.0.0.0",
#                     "encryption": {
#                         "algorithm": "md5",
#                         "encryption": "null",
#                         "hidden_key": true,
#                         "passphrase": "h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4="
#                     }
#                 }
#             ],
#             "fips_restrictions": true,
#             "vrf": "default"
#         },
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv6",
#                     "fips_restrictions": true,
#                     "graceful_restart": {
#                         "grace_period": 35
#                     },
#                     "timers": {
#                         "lsa": 22
#                     }
#                 }
#             ],
#             "fips_restrictions": true,
#             "router_id": "2.2.2.2",
#             "timers": {
#                 "pacing": 55
#             },
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "changed": true,
# "commands": [
#     "router ospfv3 vrf vrfmerge",
#     "address-family ipv6",
#     "no fips restrictions",
#     "no graceful-restart",
#     "no timers lsa arrival 22",
#     "area 0.0.0.3 range 10.1.2.2/24 advertise",
#     "area 0.0.0.3 range 60.1.1.1 255.255.0.0 cost 30",
#     "exit",
#     "passive-interface default",
#     "no router-id",
#     "no fips restrictions",
#     "no timers pacing flood 55",
#     "exit"
# ],


# using overridden

# before state

# veos#show running-config | section ospfv3
# router ospfv3
#    area 0.0.0.0 encryption ipsec spi 43 esp null md5 passphrase 7 h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4=
# !
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#


  -  arista.eos.eos_ospfv3:
      config:
        processes:
          - address_family:
              - areas:
                  - area_id: "0.0.0.3"
                    ranges:
                      - address: 10.1.2.2/24
                        advertise: True
                      - address: 60.1.1.1
                        subnet_mask: 255.255.0.0
                        cost: 30
                afi: "ipv6"
            passive_interface: True
            vrf: "vrfmerge"
      state: overridden

# After state

# veos#show running-config | section ospfv3
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#



# Module execution

# "after": {
#     "processes": [
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "before": {
#     "processes": [
#         {
#             "areas": [
#                 {
#                     "area_id": "0.0.0.0",
#                     "encryption": {
#                         "algorithm": "md5",
#                         "encryption": "null",
#                         "hidden_key": true,
#                         "passphrase": "h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4="
#                     }
#                 }
#             ],
#             "vrf": "default"
#         },
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "changed": true,
# "commands": [
#     "no router ospfv3",
#     "router ospfv3 vrf vrfmerge",
#     "address-family ipv6",
#     "no area 0.0.0.3 range 10.1.2.0/24",
#     "no area 0.0.0.3 range 60.1.0.0/16 cost 30",
#     "area 0.0.0.3 range 10.1.2.2/24 advertise",
#     "area 0.0.0.3 range 60.1.1.1 255.255.0.0 cost 30",
#     "exit",
#     "exit"
# ],

# using deleted

# Before state

# veos#show running-config | section ospfv3
# router ospfv3
#    area 0.0.0.0 encryption ipsec spi 43 esp null md5 passphrase 7 h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4=
# !
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv4
#       redistribute connected
#       redistribute static route-map MAP01
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#


  -  arista.eos.eos_ospfv3:
      config:
        processes:
          - vrf: "default"
      state: deleted

# After state

# veos#show running-config | section ospfv3
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv4
#       redistribute connected
#       redistribute static route-map MAP01
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#


# Module execution
# "after": {
#     "processes": [
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv4",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ],
#                     "redistribute": [
#                         {
#                             "routes": "connected"
#                         },
#                         {
#                             "route_map": "MAP01",
#                             "routes": "static"
#                         }
#                     ]
#                 },
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "before": {
#     "processes": [
#         {
#             "areas": [
#                 {
#                     "area_id": "0.0.0.0",
#                     "encryption": {
#                         "algorithm": "md5",
#                         "encryption": "null",
#                         "hidden_key": true,
#                         "passphrase": "h8pZp9eprTYjjoY/NKFFe0Ei7x03Y7dyLotRhI0a5t4="
#                     }
#                 }
#             ],
#             "vrf": "default"
#         },
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv4",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ],
#                     "redistribute": [
#                         {
#                             "routes": "connected"
#                         },
#                         {
#                             "route_map": "MAP01",
#                             "routes": "static"
#                         }
#                     ]
#                 },
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]
# },
# "changed": true,
# "commands": [
#     "no router ospfv3"
# ],

# using parsed

# parsed_ospfv3.cfg

# router ospfv3
#    fips restrictions
#    area 0.0.0.20 stub
#    area 0.0.0.20 authentication ipsec spi 33 sha1 passphrase 7 4O8T3zo4xBdRWXBnsnK934o9SEb+jEhHUN6+xzZgCo2j9EnQBUvtwNxxLEmYmm6w
#    area 0.0.0.40 default-cost 45
#    area 0.0.0.40 stub
#    timers pacing flood 7
#    adjacency exchange-start threshold 11
#    !
#    address-family ipv4
#       fips restrictions
#       redistribute connected
#    !
#    address-family ipv6
#       router-id 10.1.1.1
#       fips restrictions
# !
# router ospfv3 vrf vrf01
#    bfd all-interfaces
#    fips restrictions
#    area 0.0.0.0 encryption ipsec spi 256 esp null sha1 passphrase 7 7hl8FV3lZ6H1mAKpjL47hQ==
#    log-adjacency-changes detail
#    !
#    address-family ipv4
#       passive-interface default
#       fips restrictions
#       redistribute connected route-map MAP01
#       maximum-paths 100
#    !
#    address-family ipv6
#       fips restrictions
#       area 0.0.0.10 nssa no-summary
#       default-information originate route-map DefaultRouteFilter
#       max-metric router-lsa external-lsa 25 summary-lsa
# !
# router ospfv3 vrf vrf02
#    fips restrictions
#    !
#    address-family ipv6
#       router-id 10.17.0.3
#       distance ospf intra-area 200
#       fips restrictions
#       area 0.0.0.1 stub
#       timers throttle spf 56 56 56
#       timers out-delay 10


  -  arista.eos.eos_ospfv3:
      running_config: "{{ lookup('file', './parsed_ospfv3.cfg') }}"
      state: parsed

# Module execution

# "parsed": {
#         "processes": [
#             {
#                 "address_family": [
#                     {
#                         "afi": "ipv4",
#                         "fips_restrictions": true,
#                         "redistribute": [
#                             {
#                                 "routes": "connected"
#                             }
#                         ]
#                     },
#                     {
#                         "afi": "ipv6",
#                         "fips_restrictions": true,
#                         "router_id": "10.1.1.1"
#                     }
#                 ],
#                 "adjacency": {
#                     "exchange_start": {
#                         "threshold": 11
#                     }
#                 },
#                 "areas": [
#                     {
#                         "area_id": "0.0.0.20",
#                         "authentication": {
#                             "algorithm": "sha1",
#                             "hidden_key": true,
#                             "passphrase": "4O8T3zo4xBdRWXBnsnK934o9SEb+jEhHUN6+xzZgCo2j9EnQBUvtwNxxLEmYmm6w",
#                             "spi": 33
#                         },
#                         "stub": {
#                             "set": true
#                         }
#                     },
#                     {
#                         "area_id": "0.0.0.40",
#                         "default_cost": 45,
#                         "stub": {
#                             "set": true
#                         }
#                     }
#                 ],
#                 "fips_restrictions": true,
#                 "timers": {
#                     "pacing": 7
#                 },
#                 "vrf": "default"
#             },
#             {
#                 "address_family": [
#                     {
#                         "afi": "ipv4",
#                         "fips_restrictions": true,
#                         "maximum_paths": 100,
#                         "passive_interface": true,
#                         "redistribute": [
#                             {
#                                 "route_map": "MAP01",
#                                 "routes": "connected"
#                             }
#                         ]
#                     },
#                     {
#                         "afi": "ipv6",
#                         "areas": [
#                             {
#                                 "area_id": "0.0.0.10",
#                                 "nssa": {
#                                     "no_summary": true
#                                 }
#                             }
#                         ],
#                         "default_information": {
#                             "originate": true,
#                             "route_map": "DefaultRouteFilter"
#                         },
#                         "fips_restrictions": true,
#                         "max_metric": {
#                             "router_lsa": {
#                                 "external_lsa": {
#                                     "max_metric_value": 25
#                                 },
#                                 "summary_lsa": {
#                                     "set": true
#                                 }
#                             }
#                         }
#                     }
#                 ],
#                 "areas": [
#                     {
#                         "area_id": "0.0.0.0",
#                         "encryption": {
#                             "algorithm": "sha1",
#                             "encryption": "null",
#                             "hidden_key": true,
#                             "passphrase": "7hl8FV3lZ6H1mAKpjL47hQ=="
#                         }
#                     }
#                 ],
#                 "bfd": {
#                     "all_interfaces": true
#                 },
#                 "fips_restrictions": true,
#                 "log_adjacency_changes": {
#                     "detail": true
#                 },
#                 "vrf": "vrf01"
#             },
#             {
#                 "address_family": [
#                     {
#                         "afi": "ipv6",
#                         "areas": [
#                             {
#                                 "area_id": "0.0.0.1",
#                                 "stub": {
#                                     "set": true
#                                 }
#                             }
#                         ],
#                         "distance": 200,
#                         "fips_restrictions": true,
#                         "router_id": "10.17.0.3",
#                         "timers": {
#                             "out_delay": 10,
#                             "throttle": {
#                                 "initial": 56,
#                                 "max": 56,
#                                 "min": 56,
#                                 "spf": true
#                             }
#                         }
#                     }
#                 ],
#                 "fips_restrictions": true,
#                 "vrf": "vrf02"
#             }
#         ]

# using gathered

# native config

# veos#show running-config | section ospfv3
# router ospfv3 vrf vrfmerge
#    passive-interface default
#    !
#    address-family ipv4
#       redistribute connected
#       redistribute static route-map MAP01
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
#    !
#    address-family ipv6
#       area 0.0.0.3 range 10.1.2.0/24
#       area 0.0.0.3 range 60.1.0.0/16 cost 30
# veos#


  -  arista.eos.eos_ospfv3:
      state: gathered

# module execution

# "gathered": {
#     "processes": [
#         {
#             "address_family": [
#                 {
#                     "afi": "ipv4",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ],
#                     "redistribute": [
#                         {
#                             "routes": "connected"
#                         },
#                         {
#                             "route_map": "MAP01",
#                             "routes": "static"
#                         }
#                     ]
#                 },
#                 {
#                     "afi": "ipv6",
#                     "areas": [
#                         {
#                             "area_id": "0.0.0.3",
#                             "ranges": [
#                                 {
#                                     "address": "10.1.2.0/24"
#                                 },
#                                 {
#                                     "address": "60.1.0.0/16",
#                                     "cost": 30
#                                 }
#                             ]
#                         }
#                     ]
#                 }
#             ],
#             "passive_interface": true,
#             "vrf": "vrfmerge"
#         }
#     ]

# using rendered

  -  arista.eos.eos_ospfv3:
      config:
        processes:
          - address_family:
              - timers:
                  lsa: 22
                graceful_restart:
                  grace_period: 35
                afi: "ipv6"
            timers:
              pacing: 55
            fips_restrictions: True
            router_id: "2.2.2.2"
            vrf: "vrfmerge"
      state: rendered

# module execution

# "rendered": [
#         "router ospfv3 vrf vrfmerge",
#         "address-family ipv6",
#         "graceful-restart grace-period 35",
#         "timers lsa arrival 22",
#         "exit",
#         "timers pacing flood 55",
#         "fips restrictions",
#         "router-id 2.2.2.2",
#         "exit"
#     ]

Authors

  • Gomathi Selvi Srinivasan (@GomathiselviS)

© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/collections/arista/eos/eos_ospfv3_module.html