diff --git a/geant/gap_ansible/CHANGELOG.md b/geant/gap_ansible/CHANGELOG.md index 22a15167abdfeb054ab55e423aba02bae8e1ffd8..df19443b53c0473382822ec683441b50c3c6b02a 100644 --- a/geant/gap_ansible/CHANGELOG.md +++ b/geant/gap_ansible/CHANGELOG.md @@ -1,4 +1,7 @@ # GAP Ansible changelog +1.0.77: +- `iptrunk_migration`: if trunk is `Leased`, update the target BFD address (LO of the new node) after migration and check the BFD status. +- `iptrunk_checks`: added LLDP check - simpple `show lldp neighbors`. 1.0.76: - fixes in `iptrunk_migration` role (BFD, min-links, corrected interface descriptions) 1.0.75: diff --git a/geant/gap_ansible/roles/iptrunk_checks/tasks/check_lldp.yaml b/geant/gap_ansible/roles/iptrunk_checks/tasks/check_lldp.yaml new file mode 100644 index 0000000000000000000000000000000000000000..1e3b32b16fdcdf7740f186dc954a83ba2b166676 --- /dev/null +++ b/geant/gap_ansible/roles/iptrunk_checks/tasks/check_lldp.yaml @@ -0,0 +1,31 @@ +- name: Juniper LLDP check + when: local_side.iptrunk_side_node.vendor == "juniper" + block: + - name: Get LLDP neighbors + junipernetworks.junos.junos_command: + commands: + - show lldp neighbors + register: response + + - name: Show LLDP neighbors + ansible.builtin.debug: + msg: "{{ response.stdout_lines[0] }}" + +- name: Nokia BFD check + when: local_side.iptrunk_side_node.vendor == "nokia" + block: + - name: Get LLDP neighbors + ansible.netcommon.netconf_rpc: + rpc: action + xmlns: "urn:ietf:params:xml:ns:yang:1" + content: | + <global-operations xmlns="urn:nokia.com:sros:ns:yang:sr:oper-global"> + <md-cli-raw-command> + <md-cli-input-line>show system lldp neighbor</md-cli-input-line> + </md-cli-raw-command> + </global-operations> + display: json + register: out + - name: Show LLDP neighbors + ansible.builtin.debug: + msg: "{{out.output['rpc-reply']['nokiaoper:results']['nokiaoper:md-cli-output-block'].split('\n')}}" diff --git a/geant/gap_ansible/roles/iptrunk_checks/tasks/main.yml b/geant/gap_ansible/roles/iptrunk_checks/tasks/main.yml index ec17edd49f493126be41b2bc72d71be0dd2046fb..3a56c87f877258dcf0e2b8625cee297c2c1e4cc7 100644 --- a/geant/gap_ansible/roles/iptrunk_checks/tasks/main.yml +++ b/geant/gap_ansible/roles/iptrunk_checks/tasks/main.yml @@ -85,6 +85,10 @@ ansible.builtin.include_tasks: check_bfd.yaml when: check == "bfd" +- name: Check LLDP + ansible.builtin.include_tasks: check_lldp.yaml + when: check == "lldp" + - name: Set the optical checks results directory name when: check == "optical_pre" or check == "optical_post" ansible.builtin.set_fact: diff --git a/geant/gap_ansible/roles/iptrunk_checks/vars/main.yml b/geant/gap_ansible/roles/iptrunk_checks/vars/main.yml index 18a050f94a1f9e112424710e6e01c869274b5f3a..b7050df156e69d05f4e6bc509b8c3d05eeed4ef6 100644 --- a/geant/gap_ansible/roles/iptrunk_checks/vars/main.yml +++ b/geant/gap_ansible/roles/iptrunk_checks/vars/main.yml @@ -3,6 +3,7 @@ # checks: - bfd + - lldp - isis - ping - lacp