Description of problem: The validation fails with Error Message: Could not open the ini file: '/etc/ironic-inspector/inspector.conf' Version-Release number of selected component (if applicable): openstack-tripleo-validations-9.3.1-0.20181008110747.4064fb7.el7ost.noarch How reproducible: 100% Steps to Reproduce: 1. Install OSP14 from 2018-10-19.1 2. Go to GUI and run the validation "DHCP on the Introspection Network" Actual results: The validation fails with Error Message: Could not open the ini file: '/etc/ironic-inspector/inspector.conf' Expected results: The validation should fails/passes with clear message Additional info: I think that happen because the "Ironic" is in the container for now.
*** This bug has been marked as a duplicate of bug 1635335 ***
The validator fails with a permission denied error. Task 'Look up the introspection interface' failed: Host: undercloud Message: Could not open the ini file: '/var/lib/config-data/ironic_inspector/etc/ironic-inspector/inspector.conf' Failure! The validation failed for all hosts: * undercloud When I try manually, I have to use 'sudo' to access this file. Also, I think the correct path to the file should be a bit different (with "puppet-generated" in it because that's what's actually mounted inside the containers - but check me on that): /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/inspector.conf
Yes Udi, you're right! my mistake.
Checked on relevant version: [stack@undercloud-0 ~]$ rpm -q openstack-tripleo-validations openstack-tripleo-validations-9.3.1-0.20181008110752.4064fb7.el7ost.noarch Still fails with error: Task 'Look up the introspection interface' failed: Host: undercloud Message: Could not open the ini file: '/var/lib/config-data/ironic_inspector/puppet-generated/etc/ironic-inspector/inspector.conf' Failure! The validation failed for all hosts: * undercloud **** I think you have a mistake in path **** the inspector.conf file is not there, I ran the find command: [stack@undercloud-0 ~]$ sudo find / -name inspector.conf /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/inspector.conf /var/lib/config-data/ironic_inspector/etc/ironic-inspector/inspector.conf
Hey Gael, after retest with your changes it seems that the path to inspector file still wrong, please change it to "/var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/inspector.conf". After changing the path to correct, the validator passes from CLI: (undercloud) [stack@undercloud-0 ~]$ ansible-playbook -i /usr/bin/tripleo-ansible-inventory /usr/share/openstack-tripleo-validations/validations/dhcp-introspection.yaml PLAY [undercloud] ************************************************************************************************************************************************************************************************* TASK [Gathering Facts] ******************************************************************************************************************************************************************************************** ok: [undercloud] TASK [Look up the introspection interface] ************************************************************************************************************************************************************************ ok: [undercloud] TASK [Look up the introspection interface from the deprecated option] ********************************************************************************************************************************************* ok: [undercloud] TASK [Look for rogue DHCP servers] ******************************************************************************************************************************************************************************** ok: [undercloud] PLAY RECAP ******************************************************************************************************************************************************************************************************** undercloud : ok=4 changed=0 unreachable=0 failed=0 ***But it still fails with same error*** Task 'Look up the introspection interface' failed: Host: undercloud Message: Could not open the ini file: '/var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/inspector.conf' Failure! The validation failed for all hosts: * undercloud I think it is because permission, You can see that the file exist, but has permission: (undercloud) [stack@undercloud-0 ~]$ sudo ls -la /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/ | grep inspector.conf -rw-r-----. 1 42461 42461 40006 Nov 27 09:01 inspector.conf (undercloud) [stack@undercloud-0 ~]$ ls -la /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/ | grep inspector.conf ls: cannot open directory /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/: Permission denied (undercloud) [stack@undercloud-0 ~]$ sudo ls -la /var/lib/config-data/puppet-generated/ironic_inspector/etc/ironic-inspector/ | grep inspector.conf -rw-r-----. 1 42461 42461 40006 Nov 27 09:01 inspector.conf
In the inventory, the undercloud is known as 'localhost' and the validation is trying to read the ironic_inspector configuration file in the mistral_executor container instead of the undercloud host. It works if we run the validation through ansible-playbook on the undercloud host, but not from mistral. I've proposed a patch on tripleo-heat-templates to add a bind-mount of /var/lib/config-data/puppet-generated to the mistral_executor container.
Verified. [stack@undercloud-0 ~]$ rpm -q openstack-tripleo-validations openstack-tripleo-validations-9.3.1-0.20181008110756.4064fb7.el7ost.noarch
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHEA-2019:0045