openstack-ansible (OSAD), is a deployment method that uses Ansible to lay down OpenStack inside LXC containers. It makes deploying large OpenStack deployments easier. Deploying most components of OpenStack inside LXC containers also makes upgrading as easy as downloading the new playbooks and running.

Here are some tips on managing the cluster once you’re up and runnning. Since the inventory includes all your hosts and containers, you can use Ansible to manage OpenStack and system administration tasks.

To use the inventory file automatically, cd to /opt/os-ansible-deployment/rpc_deployment.

Physical host groups

Container host groups

Using Ansible ad-hoc and patterns for hosts you can see how you can manage both OpenStack and various other tasks you might need to perform on a cluster of hosts/containers.

You can also combine host groups with “:”, for example, pulling last 10 lines for the neutron containers log files.

Looking for an instance UUID on all compute hosts.

LCX tips

Sometimes you will want to restart an LXC container.

You might also want to blow away everything and start over without rekicking your OS. These are the steps I go through that should clear everything out.

If you want a new inventory file to be generated, remove these files and rerun the playbooks.

Rebuilding specific LXC container

In openstack-ansible there are many tags you can use to run specific parts of the playbooks. You can also use –limit to limit playbooks to specific hosts or containers. For example, I needed to delete the glance container. Instead of running the full playbooks (you can, they are idempotent), we will limit it to the glance container.

It’s recommended to run 3 x infrastructure hosts for a proper Galera and RabbitMQ clusters. So normally you would have 3 x glance containers too. In the above scenario you could do this in production and it should load balance between your 3 x glance containers. That 503 I received above was from HAProxy because I only have one infrastructure node.

Hope this helps!