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

iosxr_facts does not display the correct hostname for IOS-XR 64-bit #103

Closed
yowzer81 opened this issue Feb 9, 2021 · 1 comment
Closed
Assignees
Milestone

Comments

@yowzer81
Copy link

yowzer81 commented Feb 9, 2021

SUMMARY

iosxr_facts module doesn't capture the correct router hostname but instead shows as System. This only happens to IOS-XR running with 64-bit architecture

ISSUE TYPE
  • Bug Report
COMPONENT NAME

iosxr_facts

ANSIBLE VERSION
ansible 2.10.5
  config file = None
  configured module search path = ['/home/simon/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/local/lib/python3.6/dist-packages/ansible
  executable location = /usr/local/bin/ansible
  python version = 3.6.9 (default, Oct  8 2020, 12:12:24) [GCC 8.4.0]
CONFIGURATION

OS / ENVIRONMENT

Tested with Cisco NCS-5500 (7.2.1) and Cisco ASR9000 (7.1.2)

STEPS TO REPRODUCE

Sample router configuration.

RP/0/RSP0/CPU0:TEST-ROUTER#show run hostname
Tue Feb 9 15:33:25.729 AEST
hostname TEST-ROUTER

- name: IOS XR Pre Checks Playbook
  hosts: "{{ hosts_to_run }}"
  gather_facts: no
  serial: 1
  connection: network_cli

  tasks:
  - name: Get timestamp from the system
    shell: "date +%y%m%d_%H%M%S"
    register: tstamp

  - name: Gather router information
    iosxr_facts:
      gather_subset: 
        - "!interfaces"
EXPECTED RESULTS

Should expect "ansible_net_hostname": "TEST-ROUTER"

ACTUAL RESULTS

"ansible_net_hostname": "System"


@ashwini-mhatre
Copy link
Contributor

ashwini-mhatre commented Mar 26, 2021

#117 is merged so closing this issue

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

2 participants