Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replication Mode missing in Fabric Config with IPv6 Underlay #262

Open
marehler opened this issue Dec 19, 2024 · 5 comments · May be fixed by #268
Open

Replication Mode missing in Fabric Config with IPv6 Underlay #262

marehler opened this issue Dec 19, 2024 · 5 comments · May be fixed by #268
Assignees
Labels
bug Something isn't working

Comments

@marehler
Copy link

marehler commented Dec 19, 2024

Ansible Version

ansible [core 2.17.0]

Ansible Collection Versions

Collection                               Version
---------------------------------------- -------
ansible.netcommon                        5.3.0  
ansible.posix                            1.5.4  
ansible.utils                            2.11.0 
cisco.dcnm                               3.5.0  
cisco.nac_dc_vxlan                       0.3.0  
cisco.nxos                               5.3.0  
community.general                        8.5.0

Cisco NDFC Version

12.2.2

Cisco NX-OS Version

10.3(6)

Which role is this issue related to?

cisco.nac_dc_vxlan.dtc.create

Which section of the data model is this issue related to?

vxlan.underlay

Expected Behavior

"REPLICATION_MODE": "Ingress"

Actual Behavior

REPLICATION_MODE is missing in fabric config.

Ansible Playbook

---
# This is the main entry point playbook for calling the various roles in this collection.
- hosts: marehler_vnd3
  any_errors_fatal: true
  gather_facts: no

  roles:
    # -----------------------
    # DataCenter Roles
    #   Role: cisco.netascode_dc_vxlan.dtc manages NDFC workflows
    #
    - role: cisco.nac_dc_vxlan.dtc.create
    - role: cisco.nac_dc_vxlan.dtc.deploy
    - role: cisco.nac_dc_vxlan.dtc.remove

Steps to Reproduce

---
vxlan:
  underlay:
    general:
      enable_ipv6_underlay: true
      replication_mode: ingress

Relevant Debug Output

No response

RCA

In the dc_vxlan_fabric_replication.j2 template, there is a condition to include REPLICATION_MODE only if 'enable_ipv6_underlay' is false. This seems to assume that ingress replication was not supported with IPv6 underlay what is not true.

Proposed Fix

Remove the if condition in the template.

@marehler marehler added the bug Something isn't working label Dec 19, 2024
@mtarking mtarking mentioned this issue Dec 20, 2024
16 tasks
@mtarking mtarking self-assigned this Dec 20, 2024
@mtarking
Copy link
Collaborator

@marehler looking back at our pre-releases, this looks like it's been carried like this for a little bit, so good find and thanks for reporting it here as we've not had a lot of IPv6 adoption yet. I've implemented the fix as well as some fixes for better supporting an IPv6 underlay in general that relate to your other issue, #239.

@mtarking
Copy link
Collaborator

mtarking commented Jan 27, 2025

Hi @marehler this issue should be resolved in #268 if you want to pull that branch and test.

Initially with NDFC 12.2.1, only IR was supported by default which is what the collection supported.
Please see the release notes for 12.2.2 where NDFC 12.2.2 added support for selecting your mcast replication.
The above PR adds support for this now.

Thanks for reporting!

@marehler
Copy link
Author

@mtarking I've tried with branch issue-239_262, but it fails already in the validate role.

TASK [cisco.nac_dc_vxlan.validate : Check Roles] ****************************************************************************************************
skipping: [marehler_vnd3] => {"changed": false, "false_condition": "check_roles['save_previous']", "skip_reason": "Conditional result was False"}

TASK [cisco.nac_dc_vxlan.validate : Stat the Golden Service Model Data] *****************************************************************************
fatal: [marehler_vnd3 -> localhost]: FAILED! => {"msg": "The conditional check 'check_roles['save_previous']' failed. The error was: error while evaluating conditional (check_roles['save_previous']): 'dict object' has no attribute 'save_previous'\n\nThe error appears to be in '/Users/marehler/nac-vxlan/ansible-dc-vxlan-example/collections/ansible_collections/cisco/nac_dc_vxlan/roles/validate/tasks/manage_model_files_previous.yml': line 31, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n# Check if golden and extended service model data files exist from previous runs\n- name: Stat the Golden Service Model Data\n  ^ here\n"}

@marehler
Copy link
Author

And if I omit the validate role, it fails in the common role.

TASK [cisco.nac_dc_vxlan.common : Build VRFs Attach List From Template for loopback] ****************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: ansible.errors.AnsibleUndefinedVariable: 'dict object' has no attribute 'management_ipv4_address'
fatal: [marehler_vnd3 -> localhost]: FAILED! => {"changed": false, "msg": "AnsibleUndefinedVariable: 'dict object' has no attribute 'management_ipv4_address'"}

@marehler
Copy link
Author

marehler commented Feb 3, 2025

@mtarking I've tried again with the fix in ndfc_attach_vrfs_loopbacks.j2, however I am running into more issues. First, I got:

TASK [cisco.nac_dc_vxlan.common : Build Fabric Links] ***********************************************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: ansible.errors.AnsibleUndefinedVariable: 'dict object' has no attribute 'template'
fatal: [marehler_vnd3 -> localhost]: FAILED! => {"changed": false, "msg": "AnsibleUndefinedVariable: 'dict object' has no attribute 'template'"}

After I added 'template' variable to the fabric links I got a validation error:

Syntax error '/Users/marehler/nac-vxlan/ansible-dc-vxlan-example/host_vars/marehler_vnd3/topology_switches.yaml': vxlan.topology.fabric_links.0.template: Unexpected element

After updating the schema file I got another error:

Syntax error '/Users/marehler/nac-vxlan/ansible-dc-vxlan-example/host_vars/marehler_vnd3/global.yaml': vxlan.global.bgp_asn: '65020' is not a regex match.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants