Hide Forgot
Description of problem: ----------------------- In generated inventory file groups that contain controllers/computes are defined as: [Controller:children] controller-0 controller-1 controller-2 ... [Compute:children] compute-0 compute-1 Though other groups reference them like: ---------------------------------------- [aodh_evaluator:children] controller Which leads to next error when running minor updates: ----------------------------------------------------- ansible-playbook -b -i rhbz-hosts tmpconfig-latest/tripleo-VM7Mr1-config/update_steps_playbook.yaml --limit Compute ERROR! Attempted to read "rhbz-hosts" as YAML: Syntax Error while loading YAML. The error appears to have been in '/home/stack/rhbz-hosts': line 1, column 16, but may be elsewhere in the file depending on the exact syntax problem. The offending line appears to be: [aodh_evaluator:vars] ^ here Attempted to read "rhbz-hosts" as ini file: rhbz-hosts:5: Section [aodh_evaluator:children] includes undefined group: controller Version-Release number of selected component (if applicable): ------------------------------------------------------------- openstack-tripleo-validations-7.2.1-0.20170807182119.1f60b6f.el7ost.noarch openstack-tripleo-heat-templates-7.0.0-0.20170805163048.el7ost.noarch Steps to Reproduce: 1. Generate list of hosts: /usr/bin/tripleo-ansible-inventory --static-inventory some-hosts 2. Try to ping computes/controllers ansible -b -i some-hosts Controller -m ping -vv Expected results: ----------------- Correct hostgroups names are dumped to file
Running tripleo-ansible-inventory doesn't seem to work at all with --static-inventory option: (undercloud) [stack@puma01 ~]$ /usr/bin/tripleo-ansible-inventory --static-inventory hello Error creating inventory: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>500 Internal Server Error</title> </head><body> <h1>Internal Server Error</h1> <p>The server encountered an internal error or misconfiguration and was unable to complete your request.</p> <p>Please contact the server administrator at [no address given] to inform them of the time this error occurred, and the actions you performed just before this error.</p> <p>More information about this error may be available in the server error log.</p> </body></html> Tested with openstack-tripleo-validations-7.4.2-0.20171016115241.c2c9bf2.el7ost.noarch
(In reply to Ana Krivokapic from comment #1) > Running tripleo-ansible-inventory doesn't seem to work at all with > --static-inventory option: > > (undercloud) [stack@puma01 ~]$ /usr/bin/tripleo-ansible-inventory > --static-inventory hello > Error creating inventory: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> > <html><head> > <title>500 Internal Server Error</title> > </head><body> > <h1>Internal Server Error</h1> > <p>The server encountered an internal error or > misconfiguration and was unable to complete > your request.</p> > <p>Please contact the server administrator at > [no address given] to inform them of the time this error occurred, > and the actions you performed just before this error.</p> > <p>More information about this error may be available > in the server error log.</p> > </body></html> > > Tested with > openstack-tripleo-validations-7.4.2-0.20171016115241.c2c9bf2.el7ost.noarch I just tested static inventory creation with the same version/release and didn't encounter the error. My guess would be that the HTTP 500 originates from one of the APIs not being available during testing, rather than being a problem with the inventory itself (although this condition should probably be catched and displayed in a more helpful way). However, I could create the static inventory, and the resulting file contained the correct hostgroup names (uppercase first letters) on all hosts. The ping test mentioned in the report worked as expected.
Retested this and it works well.
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-2017:3462