Модуль cisco.nxos.nxos_vrf_global — модуль ресурсов для настройки определений VRF.
Примечание
Этот модуль входит в коллекцию cisco.nxos (версия 11.2.0).
Возможно, эта коллекция уже установлена, если вы используете пакет ansible. Она не входит в ansible-core. Чтобы проверить, установлена ли она, выполните ansible-galaxy collection list.
Чтобы установить её, используйте: ansible-galaxy collection install cisco.nxos.
Чтобы использовать её в плейбуке, укажите: cisco.nxos.nxos_vrf_global.
Добавлено в cisco.nxos 8.1.0
Краткое описание
- Этот модуль обеспечивает декларативное управление определениями VRF на Cisco NXOS.
Примечание
Этому модулю соответствует плагин действий.
Псевдонимы: vrf_global
Параметры
Параметр | Комментарии |
|---|---|
config dictionary | Список конфигураций устройства для VRF. |
|
vrfs list / elements=dictionary |
Список определений VRF. |
|
description string |
Описание VRF. |
|
ip dictionary |
Настройка функций IP для указанной VRF. |
|
auto_discard boolean |
Автоматический маршрут отбрасывания 0.0.0.0/0. Варианты:
|
|
domain_list list / elements=string |
Добавить список доменных имен. |
|
domain_name string |
Указать доменное имя по умолчанию. |
|
icmp_err dictionary |
Включить сообщения об ошибках ICMP. |
|
source_interface dictionary |
Настройка адреса источника для приложений. |
|
interface string |
Интерфейс источника для сообщений об ошибках ICMP. Варианты:
|
|
interface_value string |
Значение интерфейса источника для сообщений об ошибках ICMP. |
|
igmp dictionary |
Команды глобальной конфигурации IGMP |
|
ssm_translate list / elements=dictionary |
Преобразовывать отчеты IGMPv1/v2 в записи маршрутов (S,G). |
|
group string |
Адрес источника. |
|
source string |
Адрес группы. |
|
mroutes list / elements=dictionary |
Настройка многоадресных маршрутов. |
|
group string |
Адрес группы многоадресной рассылки. |
|
preference integer |
Значение предпочтения. |
|
source string |
Адрес источника. |
|
vrf string |
Имя VRF. |
|
multicast dictionary |
Настройка глобальных параметров многоадресной рассылки IP. |
|
group_range_prefix_list string |
Политика prefix-list для диапазона групп на границе многоадресной рассылки. |
|
multipath dictionary |
Настройка распределения нагрузки многоадресной рассылки ECMP. |
|
resilient boolean |
Настройка отказоустойчивого интерфейса RPF. Варианты:
|
|
splitting_type dictionary |
Настройка типа распределения нагрузки многоадресной рассылки. |
|
legacy boolean |
Настройка хеширования на основе источника и группы. Варианты:
|
|
nbm boolean |
Настройка управляемого NBM интерфейса RPF. Варианты:
|
|
none boolean |
Отключение распределения нагрузки многоадресной рассылки. Варианты:
|
|
sg_hash boolean |
Настройка хеширования на основе адресов источника и группы. Варианты:
|
|
sg_hash_next_hop boolean |
Настройка хеширования на основе адресов источника и группы, а также следующего перехода. Варианты:
|
|
rpf list / elements=dictionary |
Настройка проверки RPF. |
|
group_list_range string |
Диапазон групп для выбора RPF. |
|
vrf_name string |
VRF для поиска RPF. |
|
name_server dictionary |
Указать адрес сервера имен. |
|
address_list list / elements=string |
Настройка адреса сервера имен многоадресной рассылки. |
|
use_vrf dictionary |
Отображение информации для каждой VRF. |
|
source_address string |
Адрес источника для настройки сервера имен. |
|
vrf string |
Имя VRF. |
|
route list / elements=dictionary |
Настройка статических маршрутов. |
|
destination string |
Адрес следующего перехода. |
|
source string |
Префикс назначения. |
|
tags dictionary |
Тег маршрута. |
|
route_pref integer |
Предпочтение маршрута. |
|
tag_value integer |
Значение тега маршрута. |
|
track string |
Настройка объекта отслеживания. |
|
vrf string |
Добавить VRF к маршруту. |
|
ipv6 dictionary |
Настройка функций IPv6 для указанной VRF. |
|
mld_ssm_translate list / elements=dictionary |
Преобразовывать отчеты MLDv1/v2 в записи маршрутов (S,G). |
|
group string |
Адрес источника. |
|
icmp boolean |
Настройка параметров ICMP для MLD. Варианты:
|
|
source string |
Адрес группы. |
|
multicast dictionary |
Настройка глобальных параметров многоадресной рассылки IP для IPv6. |
|
group_range_prefix_list string |
Политика prefix-list для диапазона групп на границе многоадресной рассылки. |
|
multipath dictionary |
Настройка распределения нагрузки многоадресной рассылки ECMP. |
|
resilient boolean |
Настройка отказоустойчивого интерфейса RPF. Варианты:
|
|
splitting_type dictionary |
Настройка типа распределения нагрузки многоадресной рассылки. |
|
none boolean |
Отключение распределения нагрузки многоадресной рассылки. Варианты:
|
|
sg_hash boolean |
Настройка хеширования на основе адресов источника и группы. Варианты:
|
|
sg_hash_next_hop boolean |
Настройка хеширования на основе адресов источника и группы, а также следующего перехода. Варианты:
|
|
multicast dictionary |
Настройка параметров многоадресной рассылки IP. |
|
service_reflect list / elements=dictionary |
Настройка параметра отражения сервиса. |
|
map_to string |
Сопоставить с интерфейсом. |
|
service_interface string |
Настройка интерфейса сервиса. |
|
name string / required |
Имя VRF.. |
|
rd string |
Различитель маршрутов VPN |
|
vni dictionary |
Идентификатор виртуальной сети. |
|
layer_3 boolean |
Настройка VNI уровня 3. Варианты:
|
|
vni_number integer |
Номер VNI. |
running_config string | Этот параметр используется только при состоянии parsed. Значением этого параметра должен быть вывод, полученный от устройства NX-OS при выполнении команды show running-config | section ^vrf. Состояние parsed считывает конфигурацию из параметра |
state string | Состояние, в котором должна остаться конфигурация Состояния rendered, gathered и parsed не вносят никаких изменений на устройстве. Состояние rendered преобразует конфигурацию из параметра Состояние gathered получает текущую конфигурацию устройства и преобразует ее в структурированные данные в формате, соответствующем спецификации аргументов модуля ресурса; значение возвращается в ключе gathered результата. Состояние parsed считывает конфигурацию из параметра Варианты:
|
Примечания
Примечание
- Проверено на NX-OS 9.3.6.
- Этот модуль работает с подключениями
network_cliиhttpapi. См. https://docs.ansible.com/ansible/latest/network/user_guide/platform_nxos.html
Примеры
# Using merged
# Before state:
# -------------
#
# nxos#show running-config | section ^vrf
- name: Merge provided VRF configuration
cisco.nxos.vrf_global:
config:
vrfs:
- name: testvrf
description: this is description
ip:
auto_discard: true
domain_list:
- example.net
- example.com
domain_name: test.com
icmp_err:
source_interface:
interface: port-channel
interface_value: '1'
igmp:
ssm_translate:
- group: 232.0.0.0/8
source: 10.1.1.1
- group: 239.1.2.3/24
source: 192.168.1.1
mroutes:
- group: 192.168.1.0/24
source: 192.168.1.1
- group: 192.168.1.0/24
preference: 2
source: 192.168.1.2
vrf: temp1
multicast:
multipath:
resilient: true
splitting_type:
legacy: true
rpf:
- group_list_range: 238.1.0.0/24
vrf_name: temp1
- group_list_range: 239.1.0.0/24
vrf_name: temp1
name_server:
address_list:
- 192.168.0.1
- 192.168.0.2
- 192.168.1.1
- 192.169.1.3
use_vrf:
source_address: 192.168.0.1
vrf: temp1
route:
- destination: 192.0.2.22
source: 192.0.0.0/24
- destination: 192.0.2.22
source: 192.0.0.0/24
vrf: temp1
- destination: 192.0.2.22
source: 192.0.2.0/24
tags:
route_pref: 4
tag_value: 2
ipv6:
mld_ssm_translate:
- group: 'ff28::/16'
source: '2001:db8:0:abcd::2'
- group: 'ff30::/16'
source: '2001:db8:0:abcd::5'
multicast:
group_range_prefix_list: temp2
multipath:
resilient: true
splitting_type:
none: true
multicast:
service_reflect:
- map_to: Ethernet2/2
service_interface: Ethernet1/1
- map_to: Ethernet4/2
service_interface: Ethernet2/1
vni:
vni_number: 5
state: merged
# Task Output:
# ------------
# before: {}
# commands:
# - vrf context test1
# - description this is description
# - ip auto-discard
# - ip domain-name test.net
# - ip name-server 192.168.0.1 192.168.0.2 192.168.1.1 192.169.1.3
# - ip icmp-errors source-interface port-channel 1
# - ip multicast multipath resilient
# - ip multicast multipath legacy
# - ip name-server 192.168.0.1 use-vrf temp1
# - vni 5
# - ipv6 multicast group-range prefix-list temp2
# - ipv6 multicast multipath resilient
# - ipv6 multicast multipath none
# - ip domain-list test.org
# - ip domain-list example.com
# - ip domain-list example.net
# - ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# - ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# - ip mroute 192.168.1.0/24 192.168.1.1
# - ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# - ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# - ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# - ip route 192.0.0.0/24 192.0.2.22
# - ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# - ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# - multicast service-reflect interface Ethernet1/1 map interface Ethernet2/2
# - multicast service-reflect interface Ethernet2/1 map interface Ethernet4/2
# - ipv6 mld ssm-translate ff28::/16 2001:db8:0:abcd::2
# - ipv6 mld ssm-translate ff30::/16 2001:db8:0:abcd::5
# after:
# vrfs:
# - name: testvrf
# description: this is description
# ip:
# auto_discard: true
# domain_list:
# - example.net
# - example.com
# domain_name: test.com
# icmp_err:
# source_interface:
# interface: port-channel
# interface_value: '1'
# igmp:
# ssm_translate:
# - group: 232.0.0.0/8
# source: 10.1.1.1
# - group: 239.1.2.3/24
# source: 192.168.1.1
# mroutes:
# - group: 192.168.1.0/24
# source: 192.168.1.1
# - group: 192.168.1.0/24
# preference: 2
# source: 192.168.1.2
# vrf: temp1
# multicast:
# multipath:
# resilient: true
# splitting_type:
# legacy: true
# rpf:
# - group_list_range: 238.1.0.0/24
# vrf_name: temp1
# - group_list_range: 239.1.0.0/24
# vrf_name: temp1
# name_server:
# address_list:
# - 192.168.0.1
# - 192.168.0.2
# - 192.168.1.1
# - 192.169.1.3
# use_vrf:
# source_address: 192.168.0.1
# vrf: temp1
# route:
# - destination: 192.0.2.22
# source: 192.0.0.0/24
# - destination: 192.0.2.22
# source: 192.0.0.0/24
# vrf: temp1
# - destination: 192.0.2.22
# source: 192.0.2.0/24
# tags:
# route_pref: 4
# tag_value: 2
# ipv6:
# mld_ssm_translate:
# - group: ff28::/16
# source: 2001:db8:0:abcd::2
# - group: ff30::/16
# source: 2001:db8:0:abcd::5
# multicast:
# group_range_prefix_list: temp2
# multipath:
# resilient: true
# splitting_type:
# none: true
# multicast:
# service_reflect:
# - map_to: Ethernet2/2
# service_interface: Ethernet1/1
# - map_to: Ethernet4/2
# service_interface: Ethernet2/1
# vni:
# vni_number: 5
# After state:
# ------------
#
# nxos#show running-config | section ^vrf
# vrf context testvrf
# description this is description
# ip auto-discard
# ip domain-name test.net
# ip name-server 192.168.0.1 192.168.0.2 192.168.1.1 192.169.1.3
# ip icmp-errors source-interface port-channel 1
# ip multicast multipath resilient
# ip multicast multipath legacy
# ip name-server 192.168.0.1 use-vrf temp1
# vni 5
# ipv6 multicast group-range prefix-list temp2
# ipv6 multicast multipath resilient
# ipv6 multicast multipath none
# ip domain-list test.org
# ip domain-list example.com
# ip domain-list example.net
# ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# ip mroute 192.168.1.0/24 192.168.1.1
# ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# ip route 192.0.0.0/24 192.0.2.22
# ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# multicast service-reflect interface Ethernet1/1 map interface Ethernet2/2
# multicast service-reflect interface Ethernet2/1 map interface Ethernet4/2
# ipv6 mld ssm-translate ff28::/16 2001:db8:0:abcd::2
# ipv6 mld ssm-translate ff30::/16 2001:db8:0:abcd::5
# Using deleted
# Before state:
# -------------
#
# nxos#show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context test1
# description this is description
# ip domain-name test.net
# ip domain-list example.net
# ip domain-list example.com
# ip domain-list test.org
# vni 5
# ip auto-discard
# ip route 192.0.0.0/24 192.0.2.22
# ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# ip mroute 192.168.1.0/24 192.168.1.1
# ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# ip icmp-errors source-interface po1
# ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# ip multicast multipath legacy
# ip multicast multipath resilient
# ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# ip multicast group-range prefix-list temp2
- name: Delete VRF configuration
cisco.nxos.vrf_global:
config:
vrfs:
- name: test1
state: deleted
# Task Output:
# ------------
#
# before:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# description: this is description
# ip:
# domain_name: test.net
# domain_list:
# - test.org
# - example.net
# - example.com
# auto_discard: true
# route:
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# vrf: temp1
# - source: 192.0.2.0/24
# destination: 192.0.2.22
# tags:
# tag_value: 2
# route_pref: 4
# mroutes:
# - group: 192.168.1.0/24
# source: 192.168.1.1
# - group: 192.168.1.0/24
# source: 192.168.1.2
# preference: 2
# vrf: temp1
# icmp_err:
# source_interface:
# interface: port-channel
# interface_value: '1'
# igmp:
# ssm_translate:
# - group: 232.0.0.0/8
# source: 10.1.1.1
# - group: 239.1.2.3/24
# source: 192.168.1.1
# multicast:
# multipath:
# splitting_type:
# legacy: true
# resilient: true
# rpf:
# - vrf_name: temp1
# group_list_range: 238.1.0.0/24
# - vrf_name: temp1
# group_list_range: 239.1.0.0/24
# vni:
# vni_number: 5
# commands:
# - vrf context test1
# - no description this is description
# - no ip auto-discard
# - no ip domain-name test.net
# - no ip icmp-errors source-interface port-channel 1
# - no ip multicast multipath resilient
# - no ip multicast multipath legacy
# - no vni 5
# - no ip domain-list example.net
# - no ip domain-list test.org
# - no ip domain-list example.com
# - no ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# - no ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# - no ip mroute 192.168.1.0/24 192.168.1.1
# - no ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# - no ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# - no ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# - no ip route 192.0.0.0/24 192.0.2.22
# - no ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# - no ip route 192.0.2.0/24 192.0.2.22 tag 2 4
#
# after:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# Using deleted with empty config
# Before state:
# -------------
#
# nxos#show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context test1
# description this is description
# ip domain-name test.net
# ip domain-list example.net
# ip domain-list example.com
# ip domain-list test.org
# vni 5
- name: Delete VRF configuration
cisco.nxos.vrf_global:
config:
vrfs:
- name: test1
state: deleted
# Task Output:
# ------------
#
# before:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# description: this is description
# ip:
# domain_name: test.net
# domain_list:
# - test.org
# - example.net
# - example.com
# vni:
# vni_number: 5
# commands:
# - vrf context management
# - no ip name-server 192.168.255.1
# - no ip route 0.0.0.0/0 192.168.255.1
# - vrf context test1
# - no description this is description
# - no ip domain-name test.net
# - no vni 5
# - no ip domain-list example.net
# - no ip domain-list test.org
# - no ip domain-list example.com
# after:
# vrfs:
# - name: management
# - name: test1
# Using purged
# Before state:
# -------------
#
# nxos#show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context test1
# description this is description
# ip domain-name example.com
# ip domain-list example.net
# ip domain-list example.org
# vni 5
# ip auto-discard
# ip route 192.0.0.0/24 192.0.2.22
# ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# vrf context test2
# description test description
# ip auto-discard
# ip domain-name test.com
- name: Override VRF configuration
cisco.nxos.vrf_global:
config:
vrfs:
- name: test1
- name: test2
state: purged
# Task Output:
# ------------
#
# before:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# description: this is description
# ip:
# domain_name: example.com
# domain_list:
# - example.net
# - example.org
# auto_discard: true
# route:
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# vrf: temp1
# - source: 192.0.2.0/24
# destination: 192.0.2.22
# tags:
# tag_value: 2
# route_pref: 4
# vni:
# vni_number: 5
# - name: test2
# description: test description
# ip:
# auto_discard: true
# domain_name: test.com
#
# commands:
# - no vrf context test1
# - no vrf context test2
#
# after:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# Using overridden
# Before state:
# -------------
#
# nxos#show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context test1
# description this is description
# ip domain-name example.com
# ip domain-list example.net
# ip domain-list example.org
# vni 5
# ip auto-discard
# ip route 192.0.0.0/24 192.0.2.22
# ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# vrf context test2
# description test description
# ip auto-discard
# ip domain-name test.com
- name: Override VRF configuration
cisco.nxos.vrf_global:
config:
vrfs:
- name: management
ip:
name_server:
address_list:
- 192.168.255.1
route:
- source: 0.0.0.0/0
destination: 192.168.255.1
- name: test1
ip:
auto_discard: false
name_server:
address_list:
- 192.168.255.1
route:
- source: 192.0.0.0/24
destination: 192.0.2.22
state: overridden
# Task Output:
# ------------
#
# before:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# description: this is description
# ip:
# domain_name: example.com
# domain_list:
# - example.net
# - example.org
# auto_discard: true
# route:
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# vrf: temp1
# - source: 192.0.2.0/24
# destination: 192.0.2.22
# tags:
# tag_value: 2
# route_pref: 4
# vni:
# vni_number: 5
# - name: test2
# description: test description
# ip:
# auto_discard: true
# domain_name: test.com
#
# commands:
# - vrf context test1
# - no description this is description
# - no ip domain-name example.com
# - no ip domain-list example.net
# - no ip domain-list example.org
# - ip name-server 192.168.255.1
# - no ip auto-discard
# - no vni 5
# - no ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# - no ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# - vrf context test2
# - no description test description
# - no ip auto-discard
# - no ip domain-name test.com
#
# after:
# vrfs:
# - name: management
# ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 0.0.0.0/0
# destination: 192.168.255.1
# - name: test1
# ip:
# auto_discard: false
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - source: 192.0.0.0/24
# destination: 192.0.2.22
# Using replaced
# Before state:
# -------------
#
# nxos# show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context temp
# ip domain-name test.org
# ip domain-list example.net
# ip domain-list example.com
# ip domain-list test.org
# ip name-server 192.168.0.1 192.169.1.3
# ip name-server 192.168.0.1 use-vrf temp1
# multicast service-reflect interface Ethernet1/1 map interface Ethernet2/2
# multicast service-reflect interface Ethernet2/1 map interface Ethernet4/2
# description this is descrition
# vni 5
# ip auto-discard
# ip route 192.0.0.0/24 192.0.2.22
# ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# ip mroute 192.168.1.0/24 192.168.1.1
# ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# ip icmp-errors source-interface po1
# ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# ip multicast multipath legacy
# ip multicast multipath resilient
# ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# ip multicast group-range prefix-list temp2
# ipv6 multicast multipath none
# ipv6 multicast multipath resilient
# ipv6 multicast group-range prefix-list temp2
# ipv6 mld ssm-translate ff28::/16 2001:db8:0:abcd::2
# ipv6 mld ssm-translate ff30::/16 2001:db8:0:abcd::1
# ipv6 mld ssm-translate ff32::/16 2001:db8:0:abcd::2
# ipv6 mld ssm-translate ff32::/16 2001:db8:0:abcd::3
- name: Replaced state for VRF configuration
cisco.nxos.nxos_vrf_global:
config:
vrfs:
- ip:
name_server:
address_list:
- 192.168.255.1
route:
- destination: 192.168.255.1
source: 0.0.0.0/0
name: management
- name: temp
description: Test
ip:
auto_discard: true
domain_list:
- invalid.com
- example.com
domain_name: test.org
state: replaced
# Task Output:
# ------------
#
# before:
# vrfs:
# - ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - destination: 192.168.255.1
# source: 0.0.0.0/0
# name: management
# - description: this is descrition
# ip:
# auto_discard: true
# domain_list:
# - example.net
# - test.org
# - example.com
# domain_name: test.org
# icmp_err:
# source_interface:
# interface: port-channel
# interface_value: '1'
# igmp:
# ssm_translate:
# - group: 232.0.0.0/8
# source: 10.1.1.1
# - group: 239.1.2.3/24
# source: 192.168.1.1
# mroutes:
# - group: 192.168.1.0/24
# source: 192.168.1.1
# - group: 192.168.1.0/24
# preference: 2
# source: 192.168.1.2
# vrf: temp1
# multicast:
# multipath:
# resilient: true
# splitting_type:
# legacy: true
# rpf:
# - group_list_range: 238.1.0.0/24
# vrf_name: temp1
# - group_list_range: 239.1.0.0/24
# vrf_name: temp1
# name_server:
# address_list:
# - 192.168.0.1
# - 192.169.1.3
# use_vrf:
# source_address: 192.168.0.1
# vrf: temp1
# route:
# - destination: 192.0.2.22
# source: 192.0.0.0/24
# - destination: 192.0.2.22
# source: 192.0.0.0/24
# vrf: temp1
# - destination: 192.0.2.22
# source: 192.0.2.0/24
# tags:
# route_pref: 4
# tag_value: 2
# ipv6:
# mld_ssm_translate:
# - group: ff28::/16
# source: 2001:db8:0:abcd::2
# - group: ff30::/16
# source: 2001:db8:0:abcd::1
# - group: ff32::/16
# source: 2001:db8:0:abcd::2
# - group: ff32::/16
# source: 2001:db8:0:abcd::3
# multicast:
# group_range_prefix_list: temp2
# multipath:
# resilient: true
# splitting_type:
# none: true
# multicast:
# service_reflect:
# - map_to: Ethernet2/2
# service_interface: Ethernet1/1
# - map_to: Ethernet4/2
# service_interface: Ethernet2/1
# name: temp
# vni:
# vni_number: 5
#
# commands:
# - vrf context temp
# - description Test
# - no ip name-server 192.168.0.1 192.169.1.3
# - no ip icmp-errors source-interface port-channel 1
# - no ip multicast multipath resilient
# - no ip multicast multipath legacy
# - no ip name-server 192.168.0.1 use-vrf temp1
# - no vni 5
# - no ipv6 multicast group-range prefix-list temp2
# - no ipv6 multicast multipath resilient
# - no ipv6 multicast multipath none
# - ip domain-list invalid.com
# - no ip domain-list example.net
# - no ip domain-list test.org
# - no ip igmp ssm-translate 232.0.0.0/8 10.1.1.1
# - no ip igmp ssm-translate 239.1.2.3/24 192.168.1.1
# - no ip mroute 192.168.1.0/24 192.168.1.1
# - no ip mroute 192.168.1.0/24 192.168.1.2 2 vrf temp1
# - no ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# - no ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# - no ip route 192.0.0.0/24 192.0.2.22
# - no ip route 192.0.0.0/24 192.0.2.22 vrf temp1
# - no ip route 192.0.2.0/24 192.0.2.22 tag 2 4
# - no multicast service-reflect interface Ethernet1/1 map interface Ethernet2/2
# - no multicast service-reflect interface Ethernet2/1 map interface Ethernet4/2
# - no ipv6 mld ssm-translate ff28::/16 2001:db8:0:abcd::2
# - no ipv6 mld ssm-translate ff30::/16 2001:db8:0:abcd::1
# - no ipv6 mld ssm-translate ff32::/16 2001:db8:0:abcd::2
# - no ipv6 mld ssm-translate ff32::/16 2001:db8:0:abcd::3
#
# after:
# vrfs:
# - ip:
# name_server:
# address_list:
# - 192.168.255.1
# route:
# - destination: 192.168.255.1
# source: 0.0.0.0/0
# name: management
# - description: Test
# ip:
# auto_discard: true
# domain_list:
# - invalid.com
# - example.com
# domain_name: test.org
# multicast:
# rpf:
# - group_list_range: 238.1.0.0/24
# vrf_name: temp1
# - group_list_range: 239.1.0.0/24
# vrf_name: temp1
#
# After state:
# ------------
# router-ios#show running-config | section ^vrf
# vrf context management
# ip name-server 192.168.255.1
# ip route 0.0.0.0/0 192.168.255.1
# vrf context temp
# ip domain-name test.org
# ip domain-list example.com
# ip domain-list invalid.com
# description Test
# ip auto-discard
# ip multicast rpf select vrf temp1 group-list 238.1.0.0/24
# ip multicast rpf select vrf temp1 group-list 239.1.0.0/24
# ip multicast group-range prefix-list temp2
Возвращаемые значения
Общие возвращаемые значения описаны здесь; ниже перечислены поля, уникальные для этого модуля:
Ключ | Описание |
|---|---|
after dictionary | Конфигурация после выполнения модуля. Возвращается: если конфигурация была изменена Пример: |
before dictionary | Конфигурация до выполнения модуля. Возвращается: когда state равен Пример: |
commands list / elements=string | Набор команд, отправленных на удаленное устройство. Возвращается: когда state равен Пример: |
gathered dictionary | Факты о сетевом ресурсе, полученные с удаленного устройства в виде структурированных данных. Возвращается: когда state равен Пример: |
parsed dictionary | Собственная конфигурация устройства, переданная в параметре running_config и разобранная в структурированные данные в соответствии со спецификацией аргументов модуля. Возвращается: когда state равен Пример: |
rendered list / elements=string | Конфигурация, указанная в задаче, преобразованная в собственный формат устройства (в автономном режиме). Возвращается: когда state равен Пример: |
Ссылки на коллекцию
© 2012–2018 Michael DeHaan
© 2018–2025 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/projects/ansible/latest/collections/cisco/nxos/nxos_vrf_global_module.html