Description of problem: In mageia 8 ansible facts are not complete : ansible_distribution variables are missing. On Mageia 7, and other distributions, if I ask the facts with "ansible host_mga7 -m setup -a 'filter=ansible_distribution*' , I receive fields like : "ansible_distribution": "Mageia", "ansible_distribution_file_parsed": true, "ansible_distribution_file_path": "/etc/redhat-release", "ansible_distribution_file_variety": "RedHat", "ansible_distribution_major_version": "7", "ansible_distribution_release": "Official", "ansible_distribution_version": "7", this fact variable are used in ansible doc, for example in https://docs.ansible.com/ansible/latest/collections/ansible/builtin/constructed_inventory.html and https://docs.ansible.com/ansible/latest/user_guide/playbooks_vars_facts.html but, if I ask on localhost with "ansible localhost -m setup -a 'filter=ansible_distribution*'", it works ! Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. ansible host_mga8 -m setup -a 'filter=ansible_distribution*' 2. ansible host_mga7 -m setup -a 'filter=ansible_distribution*' 3.
Thank you for the report. It is not clear in what circumstances this works or does not. My interpretation (guess) is that if you use it for a remote host, the ansible_distribution data is missing; but is present if you run it for the local machine. Where do the 'host_mga*' IDs come from? Excuse me asking; ansible is not something I use & can try. Please confirm or correct this judgement.
Status: NEW => NEEDINFOSource RPM: (none) => ansible-2.9.18-1.mga8.src.rpmCC: (none) => lewyssmith
CC: (none) => ouaurelien
I had some more tests : the problem only occurs when the ansible command - is launched on mageia 7 - ask a facts on mageia 8 computer all others ways are ok : mageia 7 => mageia 7 is ok mageia 8 => mageia 8 is ok mageia 8 => mageia 7 is ok mageia 7 => centos 7 is ok for the tests, put ip adresses in a "myhosts" file, then from a mageia7 computer (ssh config should be ok) : ansible ip_mga8 -i myhosts -m setup -a 'filter=ansible_distribution*' It is not clear for me if the problem is on mageia 7 or 8 ? if it is a python2 / python 3 problem ? or an ansible problem ?
Thank you for these precisions. Ansible is commited by different people, so assigning this bug globally.
Assignee: bugsquad => pkg-bugsSummary: ansible_distribution variables are missing in mageia 8 => ansible_distribution variables are missing in mageia 8 interrogated from Mageia 7 (but not other combinations)Status: NEEDINFO => NEWStatus comment: (none) => Unsure whether the problem is M7 or M8CC: lewyssmith => (none)
I had today a new test : I have build a backport of ansible from mageia 8 on mageia 7. so I have upgraded on mageia 7 from ansible-2.7.18-1 to ansible-2.9.18-1 and now the output is ok : ansible lxtest3 -m setup -a 'filter=ansible_distribution*' [WARNING]: Platform linux on host lxtest3 is using the discovered Python interpreter at /usr/bin/python, but future installation of another Python interpreter could change this. See https://docs.ansible.com/ansible/2.9/reference_appendices/interpreter_discovery.html for more information. lxtest3 | SUCCESS => { "ansible_facts": { "ansible_distribution": "Mageia", "ansible_distribution_file_parsed": true, "ansible_distribution_file_path": "/etc/redhat-release", "ansible_distribution_file_variety": "RedHat", "ansible_distribution_major_version": "8", "ansible_distribution_release": "mga8", "ansible_distribution_version": "8", "discovered_interpreter_python": "/usr/bin/python" }, "changed": false } so my guess is this is a problem on M7