[WARNING]: Could not match supplied host pattern, ignoring: unprovisioned PLAY [Deploy initial device configuration] ************************************* TASK [Set variables that cannot be set with VARS] ****************************** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Find device readiness script] ******************************************** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Wait for device to become ready] ***************************************** skipping: [dut] skipping: [h1] skipping: [h2] included: /home/pipi/net101/tools/netsim/ansible/tasks/readiness-check/eos-clab.yml for r2 TASK [Wait for cEOS SSH daemon to start] *************************************** ok: [r2] TASK [Normalize config on bridge-like devices] ********************************* included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-module.yml for dut, r2, h1, h2 TASK [Figure out whether to deploy the module normalize on current device] ***** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Find configuration template for normalize] ******************************* ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [fail] ******************************************************************** skipping: [dut] skipping: [r2] skipping: [h1] skipping: [h2] TASK [Print deployed configuration when running in verbose mode] *************** skipping: [dut] skipping: [h1] skipping: [h2] ok: [r2] => msg: |- normalize configuration for r2 ========================================= ! interface Ethernet1 no switchport mac-address 52dc.cafe.0201 ! interface Ethernet2 no switchport mac-address 52dc.cafe.0202 ! interface Ethernet3 no switchport mac-address 52dc.cafe.0203 TASK [Find configuration deployment deploy_script for normalize] *************** skipping: [dut] skipping: [h1] skipping: [h2] ok: [r2] TASK [Deploy normalize configuration] ****************************************** skipping: [dut] skipping: [h1] skipping: [h2] included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/eos.yml for r2 TASK [eos_config: deploying normalize from /home/pipi/net101/tools/netsim/ansible/templates/normalize/eos.j2] *** [WARNING]: To ensure idempotency and correct diff the input configuration lines should be similar to how they appear if present in the running configuration on device including the indentation changed: [r2] TASK [Deploy initial configuration] ******************************************** included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-module.yml for dut, r2, h1, h2 TASK [Figure out whether to deploy the module initial on current device] ******* ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Find configuration template for initial] ********************************* ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [fail] ******************************************************************** skipping: [dut] skipping: [r2] skipping: [h1] skipping: [h2] TASK [Print deployed configuration when running in verbose mode] *************** ok: [h1] => msg: |- initial configuration for h1 ========================================= #!/bin/bash # # This script contains the 'ip' commands needed to set up container # interfaces and route table. It's executed within the container # network namespace on the container host. # # /etc/hosts file is generated as a clab bind. # set -e ### One-Shot configuration (non-Ubuntu VM or container) # # Disable IPv4 and IPv6 forwarding # sysctl -w net.ipv4.ip_forward=0 sysctl -w net.ipv6.conf.all.forwarding=0 # # Interface addressing, create any bond devices # ip link set dev eth1 up set +e ip addr del 172.16.33.3/24 dev eth1 2>/dev/null set -e ip addr add 172.16.33.3/24 dev eth1 sysctl -w net.ipv6.conf.eth1.disable_ipv6=0 set +e ip -6 addr del 2001:db8:cafe:33::3/64 dev eth1 2>/dev/null set -e ip -6 addr add 2001:db8:cafe:33::3/64 dev eth1 ip link set dev eth1 mtu 1500 # # Add static routes (usually IPv4 routes pointing to the first usable gateway) # echo Removing existing IPv4 routes while ip route del 172.16.44.0/24 2>/dev/null; do : ; done # set +e echo Removing existing IPv6 routes while ip route del 2001:db8:cafe:44::/64 2>/dev/null; do : ; done # echo Adding direct static routes ip route add 172.16.44.0/24 via 172.16.33.42 dev eth1 protocol static ip route add 2001:db8:cafe:44::/64 via 2001:db8:cafe:33::2a dev eth1 protocol static # # Print the final routing table ip route ok: [h2] => msg: |- initial configuration for h2 ========================================= #!/bin/bash # # This script contains the 'ip' commands needed to set up container # interfaces and route table. It's executed within the container # network namespace on the container host. # # /etc/hosts file is generated as a clab bind. # set -e ### One-Shot configuration (non-Ubuntu VM or container) # # Disable IPv4 and IPv6 forwarding # sysctl -w net.ipv4.ip_forward=0 sysctl -w net.ipv6.conf.all.forwarding=0 # # Interface addressing, create any bond devices # ip link set dev eth1 up set +e ip addr del 172.16.44.4/24 dev eth1 2>/dev/null set -e ip addr add 172.16.44.4/24 dev eth1 sysctl -w net.ipv6.conf.eth1.disable_ipv6=0 set +e ip -6 addr del 2001:db8:cafe:44::4/64 dev eth1 2>/dev/null set -e ip -6 addr add 2001:db8:cafe:44::4/64 dev eth1 ip link set dev eth1 mtu 1500 # # Add static routes (usually IPv4 routes pointing to the first usable gateway) # echo Removing existing IPv4 routes while ip route del 172.16.33.0/24 2>/dev/null; do : ; done # set +e echo Removing existing IPv6 routes while ip route del 2001:db8:cafe:33::/64 2>/dev/null; do : ; done # echo Adding direct static routes ip route add 172.16.33.0/24 via 172.16.44.1 dev eth1 protocol static ip route add 2001:db8:cafe:33::/64 via 2001:db8:cafe:44::1 dev eth1 protocol static # # Print the final routing table ip route ok: [dut] => msg: |- initial configuration for dut ========================================= - set: system: hostname: dut config: snippet: system-mtu: file: /etc/network/ifupdown2/policy.d/mtu.json content: | { "address": { "defaults": { "mtu": "1500" } } } interface: eth0: ip: vrf: mgmt address: dhcp: {} type: eth swp1: type: swp link: state: up : {} description: "dut -> r2" swp2: type: swp link: state: up : {} description: "dut -> [r2,h2]" ip: address: 172.16.44.1/24: {} 2001:db8:cafe:44::1/64: {} ipv6: forward: on neighbor-discovery: enable: on router-advertisement: enable: on interval: 5000 vlan1000: type: svi link: state: up : {} description: "VLAN access (1000) -> [r2,h1]" ip: address: 172.16.33.1/24: {} 2001:db8:cafe:33::1/64: {} ipv6: forward: on neighbor-discovery: enable: on router-advertisement: enable: on interval: 5000 - set: interface: lo: type: loopback ip: address: 10.0.0.1/32: {} ipv6: enable: off ok: [r2] => msg: |- initial configuration for r2 ========================================= hostname r2 ! logging monitor debugging aaa authorization exec default local ! lldp run ip routing ipv6 unicast-routing ! ! ip host dut 10.0.0.1 172.16.44.1 172.16.33.1 ip host h1 172.16.33.3 ip host h2 172.16.44.4 ipv6 host dut 2001:db8:cafe:44::1 ipv6 host h1 2001:db8:cafe:33::3 ipv6 host h2 2001:db8:cafe:44::4 ! interface Management0 no lldp transmit no lldp receive ! interface Loopback0 ip address 10.0.0.2/32 ! interface Ethernet1 no switchport description r2 -> dut ! mac-address 52dc.cafe.0201 no shutdown ! interface Ethernet2 no switchport description r2 -> [dut,h2] ip address 172.16.44.2/24 ipv6 nd ra interval 5 ipv6 address 2001:db8:cafe:44::2/64 ! mac-address 52dc.cafe.0202 no shutdown ! interface Ethernet3 no switchport description [Access VLAN access] r2 -> h1 ! mac-address 52dc.cafe.0203 no shutdown ! interface Vlan1000 description VLAN access (1000) -> [dut,h1] ip address 172.16.33.2/24 ipv6 nd ra interval 5 ipv6 address 2001:db8:cafe:33::2/64 ! TASK [Find configuration deployment deploy_script for initial] ***************** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Deploy initial configuration] ******************************************** included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/cumulus_nvue.yml for dut included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/eos.yml for r2 included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/linux-clab.yml for h1, h2 TASK [set_fact] **************************************************************** ok: [dut] TASK [copy the cumulus nvue YAML initial config file to switch (generated from /home/pipi/net101/tools/netsim/ansible/templates/initial/cumulus_nvue.j2)] *** changed: [dut] TASK [Wait for nvued to start] ************************************************* ok: [dut] TASK [set_fact] **************************************************************** ok: [dut] TASK [execute on cumulus: 'nv config patch' for initial config] **************** changed: [dut] TASK [execute on cumulus: 'nv config apply -y' for initial config] ************* changed: [dut] TASK [eos_config: deploying initial from /home/pipi/net101/tools/netsim/ansible/templates/initial/eos.j2] *** changed: [r2] TASK [Define script filename and determine whether to execute in netns] ******** ok: [h1] ok: [h2] TASK [Create a temporary file for the rendered script] ************************* changed: [h1 -> localhost] changed: [h2 -> localhost] TASK [Create container setup script from /home/pipi/net101/tools/netsim/ansible/templates/initial/linux-clab.j2] *** changed: [h2 -> localhost] changed: [h1 -> localhost] TASK [Copy script into running container at /tmp/config-h1_initial.sh] ********* skipping: [h1] skipping: [h2] TASK [Execute /tmp/config-h1_initial.sh to deploy initial config based on /home/pipi/net101/tools/netsim/ansible/templates/initial/linux-clab.j2] *** skipping: [h1] skipping: [h2] TASK [Container configuration for initial based on /home/pipi/net101/tools/netsim/ansible/templates/initial/linux-clab.j2 executed in netns] *** changed: [h1 -> localhost] changed: [h2 -> localhost] TASK [Remove temporary file /tmp/h1_initial-93flxfuz.sh] *********************** changed: [h1 -> localhost] changed: [h2 -> localhost] PLAY [Deploy module-specific configurations] *********************************** TASK [Set variables that cannot be set with VARS] ****************************** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Deploy individual configuration modules] ********************************* included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-module.yml for dut, h1, h2, r2 => (item=routing) included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-module.yml for dut, h1, h2, r2 => (item=vlan) included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-module.yml for dut, h1, h2, r2 => (item=gateway) TASK [Figure out whether to deploy the module routing on current device] ******* ok: [dut] ok: [h2] ok: [h1] ok: [r2] TASK [Find configuration template for routing] ********************************* skipping: [dut] skipping: [r2] ok: [h1] ok: [h2] TASK [fail] ******************************************************************** skipping: [dut] skipping: [h1] skipping: [h2] skipping: [r2] TASK [Print deployed configuration when running in verbose mode] *************** skipping: [dut] skipping: [r2] ok: [h1] => msg: |- routing configuration for h1 ========================================= #!/bin/bash # echo "Static routes are configured as part of the initial configuration template" echo # ip route ok: [h2] => msg: |- routing configuration for h2 ========================================= #!/bin/bash # echo "Static routes are configured as part of the initial configuration template" echo # ip route TASK [Find configuration deployment deploy_script for routing] ***************** skipping: [dut] skipping: [r2] ok: [h1] ok: [h2] TASK [Deploy routing configuration] ******************************************** skipping: [dut] skipping: [r2] included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/linux-clab.yml for h1, h2 TASK [Define script filename and determine whether to execute in netns] ******** ok: [h1] ok: [h2] TASK [Create a temporary file for the rendered script] ************************* changed: [h1 -> localhost] changed: [h2 -> localhost] TASK [Create container setup script from /home/pipi/net101/tools/netsim/ansible/templates/routing/linux.j2] *** changed: [h1 -> localhost] changed: [h2 -> localhost] TASK [Copy script into running container at /tmp/config-h1_routing.sh] ********* changed: [h2 -> localhost] changed: [h1 -> localhost] TASK [Execute /tmp/config-h1_routing.sh to deploy routing config based on /home/pipi/net101/tools/netsim/ansible/templates/routing/linux.j2] *** changed: [h1] changed: [h2] TASK [Container configuration for routing based on /home/pipi/net101/tools/netsim/ansible/templates/routing/linux.j2 executed in netns] *** skipping: [h1] skipping: [h2] TASK [Remove temporary file /tmp/h1_routing-6f4hcwip.sh] *********************** changed: [h1 -> localhost] changed: [h2 -> localhost] TASK [Figure out whether to deploy the module vlan on current device] ********** ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Find configuration template for vlan] ************************************ skipping: [h1] skipping: [h2] ok: [dut] ok: [r2] TASK [fail] ******************************************************************** skipping: [dut] skipping: [h1] skipping: [h2] skipping: [r2] TASK [Print deployed configuration when running in verbose mode] *************** skipping: [h1] skipping: [h2] ok: [dut] => msg: |- vlan configuration for dut ========================================= - set: bridge: domain: br_default: mac-address: "08:4f:c2:a9:00:01" # The default 'auto' setting picks the same MAC for multiple instances! untagged: 1 vlan: '1000': {} interface: swp1: bridge: domain: br_default: vlan: '1000': {} ok: [r2] => msg: |- vlan configuration for r2 ========================================= vlan 1000 name access ! ! interface Ethernet1 switchport switchport mode trunk switchport trunk allowed vlan 1000 ! interface Ethernet3 switchport switchport access vlan 1000 ! interface Vlan1000 TASK [Find configuration deployment deploy_script for vlan] ******************** skipping: [h1] skipping: [h2] ok: [dut] ok: [r2] TASK [Deploy vlan configuration] *********************************************** skipping: [h1] skipping: [h2] included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/cumulus_nvue.yml for dut included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/eos.yml for r2 TASK [set_fact] **************************************************************** ok: [dut] TASK [copy the cumulus nvue YAML vlan config file to switch (generated from /home/pipi/net101/tools/netsim/ansible/templates/vlan/cumulus_nvue.j2)] *** changed: [dut] TASK [Wait for nvued to start] ************************************************* skipping: [dut] TASK [set_fact] **************************************************************** ok: [dut] TASK [execute on cumulus: 'nv config patch' for vlan config] ******************* changed: [dut] TASK [execute on cumulus: 'nv config apply -y' for vlan config] **************** changed: [dut] TASK [eos_config: deploying vlan from /home/pipi/net101/tools/netsim/ansible/templates/vlan/eos.j2] *** changed: [r2] TASK [Figure out whether to deploy the module gateway on current device] ******* ok: [dut] ok: [h1] ok: [h2] ok: [r2] TASK [Find configuration template for gateway] ********************************* skipping: [h1] skipping: [h2] ok: [dut] ok: [r2] TASK [fail] ******************************************************************** skipping: [h1] skipping: [dut] skipping: [h2] skipping: [r2] TASK [Print deployed configuration when running in verbose mode] *************** skipping: [h1] skipping: [h2] ok: [dut] => msg: |- gateway configuration for dut ========================================= - set: router: vrrp: enable: on - set: interface: vlan1000: ip: vrrp: enable: on virtual-router: '217': address: fe80::200:5eff:fe00:2d9: {} - set: interface: vlan1000: ip: vrrp: virtual-router: '217': address: 172.16.33.42: {} 2001:db8:cafe:33::2a: {} preempt: on priority: 30 ok: [r2] => msg: |- gateway configuration for r2 ========================================= no ip icmp redirect ! interface Vlan1000 vrrp 217 ipv4 version 3 vrrp 217 ipv4 checksum pseudo-header exclude vrrp 217 ipv4 172.16.33.42 vrrp 217 ipv6 2001:db8:cafe:33::2a vrrp 217 priority-level 20 vrrp 217 preempt TASK [Find configuration deployment deploy_script for gateway] ***************** skipping: [h1] skipping: [h2] ok: [dut] ok: [r2] TASK [Deploy gateway configuration] ******************************************** skipping: [h1] skipping: [h2] included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/cumulus_nvue.yml for dut included: /home/pipi/net101/tools/netsim/ansible/tasks/deploy-config/eos.yml for r2 TASK [set_fact] **************************************************************** ok: [dut] TASK [copy the cumulus nvue YAML gateway config file to switch (generated from /home/pipi/net101/tools/netsim/ansible/templates/gateway/cumulus_nvue.j2)] *** changed: [dut] TASK [Wait for nvued to start] ************************************************* skipping: [dut] TASK [set_fact] **************************************************************** ok: [dut] TASK [execute on cumulus: 'nv config patch' for gateway config] **************** changed: [dut] TASK [execute on cumulus: 'nv config apply -y' for gateway config] ************* changed: [dut] TASK [eos_config: deploying gateway from /home/pipi/net101/tools/netsim/ansible/templates/gateway/eos.j2] *** changed: [r2] PLAY [Deploy custom deployment templates] ************************************** skipping: no hosts matched PLAY RECAP ********************************************************************* dut : ok=42 changed=9 unreachable=0 failed=0 skipped=15 rescued=0 ignored=0 h1 : ok=33 changed=9 unreachable=0 failed=0 skipped=20 rescued=0 ignored=0 h2 : ok=33 changed=9 unreachable=0 failed=0 skipped=20 rescued=0 ignored=0 r2 : ok=35 changed=4 unreachable=0 failed=0 skipped=9 rescued=0 ignored=0 This lab tests IPv4/6 VRRP configuration on an access VLAN. It checks whether the device-under-test (DUT) forwards traffic sent to the VRRP IP/MAC address, whether it has correct VRRP priority, and whether the preemption mechanism works.