📦
CHI-in-a-box
  • What is CHI-in-a-Box?
  • Before You Begin
    • Assumed Knowledge
    • Hosts and Services
    • Network Overview
    • CC-Ansible
    • The site configuration
      • inventory
      • defaults.yml
      • passwords.yml
      • certificates/
      • node_custom_config/ (optional)
      • post-deploy.yml (optional)
    • How Deployment Works
    • Security considerations
  • Setup Guides
    • Evaluation Site
      • Bring up the Control Plane
    • Production Baremetal
      • Baremetal QuickStart
      • Host Networking Configuration
    • Troubleshooting
      • Networking
    • Verification Checklist
    • Dev-in-a-Box
    • Edge-in-a-Box
  • Reference
    • Chameleon Identity Federation
    • Ironic Flat Networking
    • Ironic Multi-Tenant Networking
    • Glance Image Storage
    • Resource Reservation
      • Default Resource Properties
    • Monitoring
      • IPMI Metrics
      • SNMP Metrics
  • Example Deployments
    • ARM/x86 mixed architecture
    • Edge computing/container testbed
  • Operations
    • Hardware management
    • Certificate management
    • Chameleon tools
      • Hammers 🔨
        • maintenance_reservation
      • Disk image subscription
      • Usage reporting
    • Troubleshooting
      • Known issues
        • Neutron (networking)
        • Nova (KVM)
        • Ironic (bare metal)
      • Instance networking diagnostics
      • Security incident triage
      • Troublesome Hardware
    • Alert runbooks
      • Cron Job No Recent Success
      • Instance Failure
      • Image Cache Space
      • Ironic Node Error State
      • Jupyter Server Launch Failure
      • MySQL Host Down
      • MySQL Replication Error
      • Node Exporter Down
      • Node Network Bridge Down
      • Node Network Bridge Low Traffic
      • Nova Ironic Instance Launch Failure
      • OpenStack API Down
      • PeriodicTask No Recent Success
      • Portal Down
      • Precis Parsed Events Low
      • Provider Conflict
      • Runbook Template
    • User support guide
    • Upgrading to a new Release
  • Development
    • Developing OpenStack Services
    • Dev-in-a-box
Powered by GitBook
On this page
  • Train -> Xena
  • Backup
  • Clean up the controller nodes
  • Check out new chi-in-a-box
  • Get new containers, and deploy services
Edit on GitHub
  1. Operations

Upgrading to a new Release

PreviousUser support guideNextDeveloping OpenStack Services

Last updated 2 years ago

Train -> Xena

If you're running centos7, this will be annoying. This involves a major openstack version upgrade, python2->python3 upgrade, and host-os upgrade.

Backup

On the controller node, back up the following.

  • /etc/ansible

  • /etc/kolla

  • your mysql DB

mariadb

./cc-ansible mariadb_backup
docker run --rm -it \
  -v mariadb_backup:/mariadb_backup:ro \
  -v /tmp/backup:/backup \
  ubuntu:latest bash
  
# copy the latest backup from `/mariadb_backup to /backup`

On the Deploy node, back up the following:

  • your git checkout of chi-in-a-box

  • your site-config directory, especially including the vault_password

Clean up the controller nodes

Ubuntu 20.04

# Run these on your controller node, after making a backup.
mv /etc/ansible /etc/ansible.bak
mv /etc/kolla /etc/kolla.bak

Check out new chi-in-a-box

Once you've backed up your chi-in-a-box directory, run the following commands to get the latest code, and clean up leftover files.

# Run this in your chi-in-a-box directory, AFTER MAKING A BACKUP!
cd </path/to/chi-in-a-box>
git fetch
git checkout stable/xena
rm -rf venv
rm -rf .facts
./cc-ansible bootstrap-servers

Update passwords.yml

We need to set some new passwords that the new version requires. The kolla-mergepwd command will pull in values that are set in site-config.example, but missing from your passwords file.

# backup your passwords.yml file
cp $SITE_CONFIG/passwords.yml $SITE_CONFIG/passwords.yml.bak

$CHI_IN_A_BOX/venv/bin/ansible-vault decrypt \
  --vault-password-file $SITE_CONFIG/vault_password \
  $SITE_CONFIG/passwords.yml

# merge new passwords that are needed    
$CHI_IN_A_BOX/venv/bin/kolla-mergepwd \
  --old $SITE_CONFIG/passwords.yml \
  --new $CHI_IN_A_BOX/site-config.example/passwords.yml \
  --final $SITE_CONFIG/new_passwords.yml
 
# if the new file looks ok, run:
mv $SITE_CONFIG/new_passwords.yml $SITE_CONFIG/passwords.yml

$CHI_IN_A_BOX/venv/bin/ansible-vault encrypt \
  --vault-password-file $SITE_CONFIG/vault_password \
  $SITE_CONFIG/passwords.yml

# Finally, edit the resulting file to replace "null" with "".
# The empty values will be auto-populated.
cd $CHI_IN_A_BOX
./cc-ansible edit_passwords

each line that looks like: key: null should be modified to look like key:

Update inventory/hosts

# make a backup of your inventory
mv $SITE_CONFIG/inventory/hosts $SITE_CONFIG/inventory/hosts.bak

cp $CHI_IN_A_BOX/site-config.example/inventory/hosts \
   $SITE_CONFIG/inventory/hosts

# edit the groups at the top to put your controller node back
vim $SITE_CONFIG/inventory/hosts

Get new containers, and deploy services

cd $CHI_IN_A_BOX
# Recreate the virtualenv, now that we've updated inventory/hosts
./cc-ansible bootstrap-servers

# pull new containers
./cc-ansible pull

# deploy the updated containers
./cc-ansible deploy
https://docs.openstack.org/kolla-ansible/latest/admin/mariadb-backup-and-restore.html