arista.eos.eos_bgp_address_family 模块 – 管理 BGP 地址族资源模块

注意

此模块是 arista.eos 集合 (版本 10.0.1) 的一部分。

如果您使用的是 ansible 包,则可能已安装此集合。它不包含在 ansible-core 中。要检查是否已安装,请运行 ansible-galaxy collection list

要安装它,请使用: ansible-galaxy collection install arista.eos

要在 playbook 中使用它,请指定: arista.eos.eos_bgp_address_family

arista.eos 1.4.0 中的新增功能

概要

  • 此模块配置和管理 Arista EOS 平台上 BGP AF 的属性。

参数

参数

注释

config

字典

BGP 地址族的配置。

address_family

列表 / 元素=字典

启用地址族并进入其配置模式

afi

字符串

地址族。

选项

  • "ipv4"

  • "ipv6"

  • "evpn"

bgp_params

字典

BGP 参数。

additional_paths

字符串

BGP additional-paths 命令

选项

  • "install"

  • "send"

  • "receive"

next_hop_address_family

字符串

Next-hop 地址族配置

选项

  • "ipv6"

next_hop_unchanged

布尔值

在向 eBGP 对等体通告路由时保留原始 nexthop。

选项

  • false

  • true

redistribute_internal

布尔值

重新分发内部 BGP 路由。

选项

  • false

  • true

route

字符串

配置用于路由安装的路由映射。

graceful_restart

布尔值

启用优雅重启模式。

选项

  • false

  • true

neighbor

列表 / 元素=字典

配置网络路由。

activate

布尔值

在地址族中激活邻居。

选项

  • false

  • true

additional_paths

字符串

BGP additional-paths 命令。

选项

  • "send"

  • "receive"

default_originate

字典

向此邻居发起默认路由。

always

布尔值

始终向此邻居发起默认路由。

选项

  • false

  • true

route_map

字符串

路由映射引用。

encapsulation

字典

邻居的默认传输封装。适用于 evpn 地址族。

source_interface

字符串

更新 BGP 下一跳地址的源接口。适用于 mpls 传输。

transport

字符串

MPLS/VXLAN 传输。

选项

  • "mpls"

  • "vxlan"

graceful_restart

布尔值

启用优雅重启模式。

选项

  • false

  • true

next_hop_address_family

字符串

Next-hop 地址族配置

选项

  • "ipv6"

next_hop_unchanged

布尔值

在向 eBGP 对等体通告路由时保留原始 nexthop。

选项

  • false

  • true

peer

字符串

邻居地址/对等体组名称。

prefix_list

字典

前缀列表引用。

direction

字符串

配置入站/出站前缀列表。

选项

  • "in"

  • "out"

name

字符串

前缀列表名称。

route_map

字典

路由映射引用。

direction

字符串

配置入站/出站路由映射。

选项

  • "in"

  • "out"

name

字符串

路由映射名称。

weight

整数

要分配的权重。

network

列表 / 元素=字典

配置网络路由。

address

字符串

网络地址。

route_map

字符串

路由映射引用。

redistribute

列表 / 元素=字典

将路由重新分发到 BGP。

isis_level

字符串

适用于 isis 路由。指定 isis 路由级别。

选项

  • "level-1"

  • "level-2"

  • "level-1-2"

ospf_route

字符串

ospf 路由选项。

选项

  • "internal"

  • "external"

  • "nssa_external_1"

  • "nssa_external_2"

protocol

字符串

要重新分发的路由。

选项

  • "isis"

  • "ospfv3"

  • "dhcp"

route_map

字符串

路由映射引用。

route_target

字典

路由目标。

action

别名:mode

字符串

路由操作。

选项

  • "both"

  • "import"

  • "export"

imported_route

布尔值

导出从同一 Afi/Safi 导入的路由

选项

  • false

  • true

route_map

字符串

路由映射的名称。

target

字符串

路由目标。

type

字符串

地址族的类型

选项

  • "evpn"

  • "vpn-ipv4"

  • "vpn-ipv6"

safi

字符串

ipv4 的地址族类型。

选项

  • "labeled-unicast"

  • "multicast"

vrf

字符串

将配置 BGP 的 VRF 的名称。

as_number

字符串

自治系统编号。

running_config

字符串

此选项仅与状态 *parsed* 一起使用。

此选项的值应为通过执行命令 **show running-config | section bgp** 从 EOS 设备接收到的输出。

状态 *parsed* 从 running_config 选项读取配置并将其转换为 Ansible 结构化数据,该数据符合资源模块的 argspec,然后该值将返回结果中的 *parsed* 密钥中。

state

字符串

配置应保留的状态。

选项

  • "deleted"

  • "merged" ← (默认)

  • "overridden"

  • "replaced"

  • "gathered"

  • "rendered"

  • "parsed"

备注

注意

  • 针对 Arista EOS 4.24.6F 进行了测试

  • 此模块与连接 network_cli 一起使用。请参阅 EOS 平台选项

示例

# Using Merged

# Before state:
# -------------
# veos(config)#show running-config | section bgp
# veos(config)#

- name: Merge provided configuration with device configuration
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv4"
          redistribute:
            - protocol: "ospfv3"
              ospf_route: "external"
          network:
            - address: "1.1.1.0/24"
            - address: "1.5.1.0/24"
              route_map: "MAP01"
        - afi: "ipv6"
          bgp_params:
            additional_paths: "receive"
          neighbor:
            - peer: "peer2"
              default_originate:
                always: true
        - afi: "ipv6"
          redistribute:
            - protocol: "isis"
              isis_level: "level-2"
          route_target:
            mode: "export"
            target: "33:11"
          vrf: "vrft"
    state: merged


# Task output:
# ------------
# before: {}
#
# commands:
# - router bgp 10
# - address-family ipv4
# - redistribute ospfv3 match external
# - network 1.1.1.0/24
# - network 1.5.1.0/24 route-map MAP01
# - exit
# - address-family ipv6
# - neighbor peer2 default-originate always
# - bgp additional-paths receive
# - exit
# - vrf vrft
# - address-family ipv6
# - redistribute isis level-2
# - route-target export 33:11
# - exit
# - exit
#
# after:
#     address_family:
#     - afi: ipv4
#       neighbor:
#       - activate: true
#         peer: 1.1.1.1
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - activate: true
#         default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv6
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#       route_target:
#         action: export
#         target: '33:11'
#       vrf: vrft
#     as_number: '10'
#     "before": {},
#     "changed": true,

# After state:
# ------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       bgp additional-paths receive
#       neighbor peer2 activate
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv6
#          route-target export 33:11
#          redistribute isis level-2

# Using replaced

# Before state:
# -------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       bgp additional-paths receive
#       neighbor peer2 activate
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv6
#          route-target export 33:11
#          redistribute isis level-2

- name: Replace running config section with provided config
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv6"
          vrf: "vrft"
          redistribute:
            - protocol: "ospfv3"
              ospf_route: "external"
        - afi: "ipv6"
          redistribute:
            - protocol: "isis"
              isis_level: "level-2"
    state: replaced

# Task output:
# ------------
# before:
#     address_family:
#     - afi: ipv4
#       neighbor:
#       - activate: true
#         peer: 1.1.1.1
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - activate: true
#         default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv6
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#       route_target:
#         action: export
#         target: '33:11'
#       vrf: vrft
#     as_number: '10'
#
# commands:
# - router bgp 10
# - vrf vrft
# - address-family ipv6
# - redistribute ospfv3 match external
# - no redistribute isis level-2
# - no route-target export 33:11
# - exit
# - exit
# - address-family ipv6
# - redistribute isis level-2
# - no neighbor peer2 activate
# - no bgp additional-paths receive
# - exit
#
# after:
#     address_family:
#     - afi: ipv4
#       neighbor:
#       - activate: true
#         peer: 1.1.1.1
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#     - afi: ipv6
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#       vrf: vrft
#     as_number: '10'

# After state:
# ------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       neighbor peer2 default-originate always
#       redistribute isis level-2
#    !
#    vrf vrft
#       address-family ipv6
#          redistribute ospfv3 match external

# Using overridden (overriding af at global context):

# Before state:
# -------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       neighbor peer2 default-originate always
#       redistribute isis level-2
#    !
#    vrf vrft
#       address-family ipv6
#          redistribute ospfv3 match external

- name: Override running config with provided config
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv4"
          bgp_params:
            additional_paths: "receive"
          neighbor:
            - peer: "peer2"
              default_originate:
                always: true
    state: overridden


#
# Task output:
# ------------
# before:
#     address_family:
#     - afi: ipv4
#       neighbor:
#       - activate: true
#         peer: 1.1.1.1
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#     - afi: ipv6
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#       vrf: vrft
#     as_number: '10'
#
# commands:
# - router bgp 10
# - address-family ipv4
# - no redistribute ospfv3 match external
# - no network 1.1.1.0/24
# - no network 1.5.1.0/24 route-map MAP01
# - neighbor peer2 default-originate always
# - no neighbor 1.1.1.1 activate
# - bgp additional-paths receive
# - exit
# - no address-family ipv6
#
# after:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv6
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#       vrf: vrft
#     as_number: '10'

# After state:
# ------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv6
#          redistribute ospfv3 match external

# using Overridden (overridding af in vrf context):

# Before state:
# -------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       no neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv6
#          route-target export 33:11
#          redistribute isis level-2
#          redistribute ospfv3 match external

- name: Override running config with provided config
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv4"
          bgp_params:
            additional_paths: "receive"
          neighbor:
            - peer: "peer2"
              default_originate:
                always: true
          vrf: vrft
    state: overridden

# Task output:
# ------------
# before:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv6
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#       - ospf_route: external
#         protocol: ospfv3
#       route_target:
#         action: export
#         target: '33:11'
#       vrf: vrft
#     as_number: '10'
#
# commands:
# - router bgp 10
# - vrf vrft
# - address-family ipv4
# - neighbor peer2 default-originate always
# - bgp additional-paths receive
# - exit
# - exit
# - vrf vrft
# - no address-family ipv6
#
# after:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       vrf: vrft
#     as_number: '10'

# After state:
# ------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv4
#          bgp additional-paths receive

# Using deleted

# Before state:
# -------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       no neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#    !
#    vrf vrft
#       address-family ipv4
#          bgp additional-paths receive

- name: Delete running config for provided afi
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv6"
          vrf: "vrft"
        - afi: "ipv6"
    state: deleted

# Task output:
# ------------
# before:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       vrf: vrft
#     as_number: '10'
#
# after:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       vrf: vrft
#     as_number: '10'

# After state:
# ------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       no neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    vrf vrft
#       address-family ipv4
#          bgp additional-paths receive


# Using parsed

# parsed.cfg
# ----------
# router bgp 10
#    neighbor n2 peer group
#    neighbor n2 next-hop-unchanged
#    neighbor n2 maximum-routes 12000
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    network 1.1.1.0/24
#    network 1.5.1.0/24 route-map MAP01
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       redistribute ospfv3 match external
#    !
#    address-family ipv6
#       no bgp additional-paths receive
#       neighbor n2 next-hop-unchanged
#       redistribute isis level-2
#    !
#    vrf bgp_10
#       ip access-group acl01
#       ucmp fec threshold trigger 33 clear 22 warning-only
#       !
#       address-family ipv4
#          route-target import 20:11
#    !
#    vrf vrft
#       address-family ipv4
#          bgp additional-paths receive
#       !
#       address-family ipv6
#          redistribute ospfv3 match external

- name: parse running config and generate structred facts
  arista.eos.eos_bgp_address_family:
    running_config: "{{ lookup('file', './parsed_bgp_address_family.cfg') }}"
    state: parsed

# Task output:
# ------------
# parsed:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv6
#       neighbor:
#       - next_hop_unchanged: true
#         peer: n2
#       redistribute:
#       - isis_level: level-2
#         protocol: isis
#     - afi: ipv4
#       route_target:
#         action: import
#         target: '20:11'
#       vrf: bgp_10
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       vrf: vrft
#     - afi: ipv6
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#       vrf: vrft
#     as_number: '10'

# Using gathered

# running config
# --------------
# veos(config-router-bgp)#show running-config | section bgp
# router bgp 10
#    neighbor peer2 peer group
#    neighbor peer2 maximum-routes 12000
#    neighbor 1.1.1.1 maximum-routes 12000
#    !
#    address-family ipv4
#       bgp additional-paths receive
#       neighbor peer2 default-originate always
#       no neighbor 1.1.1.1 activate
#       network 1.1.1.0/24
#       network 1.5.1.0/24 route-map MAP01
#       redistribute ospfv3 match external
#    !
#    vrf vrft
#       address-family ipv4
#          bgp additional-paths receive

- name: gather running config
  arista.eos.eos_bgp_address_family:
    state: gathered

# Task output:
# ------------
# gathered:
#     address_family:
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       neighbor:
#       - default_originate:
#           always: true
#         peer: peer2
#       network:
#       - address: 1.1.1.0/24
#       - address: 1.5.1.0/24
#         route_map: MAP01
#       redistribute:
#       - ospf_route: external
#         protocol: ospfv3
#     - afi: ipv4
#       bgp_params:
#         additional_paths: receive
#       vrf: vrft
#     as_number: '10'

# using rendered

- name: Render CLI commands for provided config
  arista.eos.eos_bgp_address_family:
    config:
      as_number: "10"
      address_family:
        - afi: "ipv4"
          redistribute:
            - protocol: "ospfv3"
              ospf_route: "external"
          network:
            - address: "1.1.1.0/24"
            - address: "1.5.1.0/24"
              route_map: "MAP01"
        - afi: "ipv6"
          bgp_params:
            additional_paths: "receive"
          neighbor:
            - peer: "peer2"
              default_originate:
                always: true
        - afi: "ipv6"
          redistribute:
            - protocol: "isis"
              isis_level: "level-2"
          route_target:
            mode: "export"
            target: "33:11"
          vrf: "vrft"
    state: rendered

# Task output:
# ------------
# rendered:
# - router bgp 10
# - address-family ipv4
# - redistribute ospfv3 match external
# - network 1.1.1.0/24
# - network 1.5.1.0/24 route-map MAP01
# - exit
# - address-family ipv6
# - neighbor peer2 default-originate always
# - bgp additional-paths receive
# - exit
# - vrf vrft
# - address-family ipv6
# - redistribute isis level-2
# - route-target export 33:11
# - exit
# - exit

返回值

公共返回值已记录在 此处,以下是此模块特有的字段

描述

after

字典

模块执行后的结果配置。

返回:发生更改时

示例: "This output will always be in the same format as the module argspec.\n"

before

字典

模块执行之前的配置。

返回:当 *state* 为 mergedreplacedoverriddendeletedpurged

示例: "This output will always be in the same format as the module argspec.\n"

commands

列表 / 元素=字符串

推送到远程设备的命令集。

返回:当 *state* 为 mergedreplacedoverriddendeletedpurged

示例: ["router bgp 10", "address-family ipv4", "redistribute ospfv3 match external", "network 1.1.1.0/24"]

收集

字典

从远程设备收集的关于网络资源的结构化数据事实。

返回:stategathered

示例: "This output will always be in the same format as the module argspec.\n"

解析

字典

根据模块参数规范,将running_config选项中提供的设备原生配置解析成结构化数据。

返回:stateparsed

示例: "This output will always be in the same format as the module argspec.\n"

渲染

列表 / 元素=字符串

以设备原生格式(离线)渲染任务中提供的配置。

返回:staterendered

示例: ["router bgp 10", "address-family ipv4", "redistribute ospfv3 match external", "network 1.1.1.0/24"]

作者

  • Gomathi Selvi Srinivasan (@GomathiselviS)