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

cisco.ucs.ucs_vlan_to_group fails if group doesn't exist but creates the group any way #35

Open
davidstanaway opened this issue Oct 7, 2022 · 0 comments

Comments

@davidstanaway
Copy link

I don't see any module method to create the vlan group but found that the cisco.ucs.ucs_vlan_to_group does create the group and adds the vlan to it but reports the task as failed.

EG:

  • name: Configure VLAN groups A
    cisco.ucs.ucs_vlan_to_group:
    hostname: "{{ inventory_hostname }}"
    username: "{{ ucs_user }}"
    password: "{{ ucs_pass }}"
    vlangroup: "{{ prefix }}_A"
    vlanname: "{{prefix}}_VL{{ vlan }}"
    state: present
    delegate_to: localhost
    ignore_errors: yes
    loop: "{{ range(start|int, end|int+1, 1)|list }}"
    loop_control:
    loop_var: vlan

reports failed for the first vlan
and modified for subsequent vlans

TASK [Configure VLAN groups A] ********************************************************************************************************************************************************************
failed: [UCS-01 -> localhost] (item=3125) => {"ansible_loop_var": "vlan", "changed": true, "msg": "PRODVMS_A VLAN Group not configured in UCS", "vlan": 3125}
failed: [UCS-02 -> localhost] (item=3125) => {"ansible_loop_var": "vlan", "changed": true, "msg": "PRODVMS_A VLAN Group not configured in UCS", "vlan": 3125}
changed: [UCS-01 -> localhost] => (item=3126)
changed: [UCS-02 -> localhost] => (item=3126)
changed: [UCS-01 -> localhost] => (item=3127)
changed: [UCS-02 -> localhost] => (item=3127)
changed: [UCS-01 -> localhost] => (item=3128)
changed: [UCS-02 -> localhost] => (item=3128)
changed: [UCS-01 -> localhost] => (item=3129)
changed: [UCS-02 -> localhost] => (item=3129)
changed: [UCS-01 -> localhost] => (item=3130)
changed: [UCS-01 -> localhost] => (item=3131)
changed: [UCS-02 -> localhost] => (item=3130)
changed: [UCS-01 -> localhost] => (item=3132)
changed: [UCS-02 -> localhost] => (item=3131)
changed: [UCS-01 -> localhost] => (item=3133)
changed: [UCS-02 -> localhost] => (item=3132)
changed: [UCS-01 -> localhost] => (item=3134)
changed: [UCS-02 -> localhost] => (item=3133)
changed: [UCS-01 -> localhost] => (item=3135)
changed: [UCS-01 -> localhost] => (item=3136)
...ignoring
changed: [UCS-02 -> localhost] => (item=3134)
changed: [UCS-02 -> localhost] => (item=3135)
changed: [UCS-02 -> localhost] => (item=3136)
...ignoring

I'd love to remove the ignore_errors: yes

It seems we are missing task to create / remove VLAN Groups

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant