upgrade

The upgrade process consists of 3 steps:

Provisioning

The first step of an upgrade is to re-provision the install-server. The procedure is already documented on Upgrade guide page. During this process, the install-server will update: * Puppet modules * Serverspec tests and configuration * eDeploy roles * Ansible playbooks (see next section for details)

Ansible playbooks

Ansible playbooks manage the upgrade orchestration, so we don’t have to worry about doing the process manually.

The playbooks are generated by config-tools during the provisioning step. Each Puppet class is associated with a playbook snippet.

For example, to manage Ceilometer Collector upgrade, we run:

- name: restart ceilometer-collector
  service: name={{ ceilometer_collector }} state=restarted
  tags: 7

You can find more information on snippets in the openstack-yaml-infra page.

For each profile (ie. controller/compute/load-balancer/network/storage) defined in your infra.yaml file, config-tools will build Ansible playbooks according to the Puppet classes you are running on each node. In other words, Ansible playbooks will be generated for every deployment so you don’t ever have to worry about doing an upgrade manually.

As of version J.1.1.0, the association between Puppet classes and Ansible playbooks is still done manually. We are working on a tool inside eDeploy to associate Puppet resources with eDeploy roles. That way, we will know what is actually updated and what we need to execute during the upgrade.

Example: if in the previous eDeploy role we detect an upgrade in Ceilometer collector, we will associate the ceilometer-collector snippet with the node where cloud::telemetry::collector is run.

The goal here is to upgrade Spinal Stack in a continuous way with automatic orchestration thanks to config-tools, eDeploy, Ansible and Puppet.

eDeploy upgrade

eDeploy updates each node by copying the roles from the install-server using rsync. Currently, eDeploy repository contains metadatas to upgrade roles release after release. The most important file is the ‘exclude’ file. It contains all the files/directories that we want to exclude from the upgrade. Basically, we exclude all the data so we don’t loose it during the upgrade. Once the rsync process is done, we execute a script called ‘post’. This script is automatically generated during the build of the eDeploy roles. It contains all actions executed by packaging during the build (create users, directories, etc). Since this script is executed after an upgrade, you don’t have to worry about new packages in the role, all packaging scripts are automatically executed and your system will be ready to use the service.

Note

If SElinux is enabled, ‘setfiles’ command will be run to re-apply all SElinux file contexts so our system will be secured again after an upgrade.

Puppet

After a run of the Ansible playbooks, we run step 0 and step 5 of Puppet. This is the usual process, so Puppet will be run in a maximum of 5 times with serverspec testing that everything is configured correctly.

Sanity

After Upgrade job, you should run Sanity job to ensure OpenStack is up and running. During Sanity process, Tempest will check both API & CLI feature are still working. Javelin will check that resources created in a previous release are still alive (servers, networks, volumes, containers, etc).