ansible.snmp icon indicating copy to clipboard operation
ansible.snmp copied to clipboard

The error was: ansible.errors.AnsibleUndefinedVariable: 'snmp_agentadress_protocol' is undefined

Open dimaliv opened this issue 2 years ago • 3 comments

Playbook:

- hosts: host
  gather_facts: yes
  tasks:
    - name: snmp
      import_role: 
        name: sbaerlocher.snmp
      tags: [ configuration, packages ]
      vars:
        snmp_user: "{{ group_vars_snmp_secrets.snmp_user }}"
        snmp_password: "{{ group_vars_snmp_secrets.snmp_password }}"
        snmp_encryption: "{{ group_vars_snmp_secrets.snmp_encryption }}"`

Result:

An exception occurred during task execution. To see the full traceback, use -vvv. The error was: ansible.errors.AnsibleUndefinedVariable: 'snmp_agentadress_protocol' is undefined
fatal: [host]: FAILED! => {
    "changed": false
}

MSG:

AnsibleUndefinedVariable: 'snmp_agentadress_protocol' is undefined

dimaliv avatar May 05 '22 18:05 dimaliv

Same happens with me

hpza avatar May 17 '22 07:05 hpza

@hpza I should have checked before forking and opening a PR because #23 #30 and now #31 all reference/fix the same issue :)

tijko avatar Nov 04 '22 03:11 tijko

Yeah having the same issue . . . rolling back to 1.8.0 works.

ollylawrence avatar Jul 12 '23 14:07 ollylawrence