[Openstack-operators] [openstack-ansible] configuration file override

Budai Laszlo laszlo.budai at gmail.com
Mon Aug 20 15:11:03 UTC 2018


Hello Jean-Philippe,

thank you for your answer.
for the version I have this:

root at ansible-ws1:~# openstack-ansible --version
Variable files: "-e @/etc/openstack_deploy/user_secrets.yml -e @/etc/openstack_deploy/user_variables.yml "
ansible-playbook 2.4.4.0
   config file = /root/.ansible.cfg
   configured module search path = ['/etc/ansible/roles/plugins/library']
   ansible python module location = /opt/ansible-runtime/lib/python3.5/site-packages/ansible
   executable location = /opt/ansible-runtime/bin/ansible-playbook
   python version = 3.5.2 (default, Nov 23 2017, 16:37:01) [GCC 5.4.0 20160609]

EXIT NOTICE [Playbook execution success] **************************************
===============================================================================
root at ansible-ws1:~#

I'm trying to install the queens release of openstack.

My problem is that the servers that I'm using have their name defined as dcx-cy-blz (datacenter - chassis - blade). After installing openstack these names are reflected as the names of the hosts in nova.
We would like to have our compute nodes referenced as compute1, compute2 ....
We found that the "host" parameter of the nova.conf can be used for this. We've set an override for this in the user variables:

nova_nova_conf_overrides:
   DEFAULT:
     host: "{{ inventory_hostname }}.ourdomain"

The result was that the name in nova became OK, but when nova-compute was trying to start instances it was failing as interfaces were not created in the ovs br-int. It turned out that we need the same host setting for neutron as well ...

so I decided to add a similar entry for the neutron.conf as well, but then in the neutron,conf on the neutron-server we had a name of the form "network1_neutron_server_container-HASH.ourdomain". And the neutron server was complaining that this is not a valid hostname (I suppose due to the underscores that appears in the name ... ).

So right now I'm looking for a way to set that host parameter in the neutron.conf and nova.conf only on the compute nodes.

Thank you,
Laszlo

On 20.08.2018 17:28, jean-philippe at evrard.me wrote:
>> In this example the override is part of a compute host definition and there it is in the host_vars section (compute_hosts -> 900089-compute001 -> host_vars -> override). Is it possible to apply such an override for all the compute hosts by not using the hostname? For instance something like:
>>
>> " compute_hosts:
>>         nova_nova_conf_overrides:
>>           DEFAULT:
>>             remove_unused_original_minimum_age_seconds: 43200
>> "
> 
> You can set nova_nova_conf_overrides: into a file named /etc/openstack_deploy/user_variables.yml and it will apply on all your nodes.
> 
> If you want to be more surgical, you'd have to give more details about your OpenStack-Ansible version and what you're trying to achieve.
> 
> Regards,
> Jean-Philippe Evrard (evrardjp)
> 
> 




More information about the OpenStack-operators mailing list