Menu Close
Settings Close

Language and Page Formatting Options

Red Hat Training

A Red Hat training course is available for Red Hat OpenStack Platform

Chapter 7. Additional Procedures for Non-Director Environments

The follow sections outline some additional procedures for Red Hat OpenStack Platform environments not managed with director. These steps accommodate changes within the OpenStack Platform ecosystem and are best performed after an upgrade to Red Hat OpenStack Platform 10.

7.1. Upgrading OpenStack Telemetry API to a WSGI Service

This step upgrades the OpenStack Telemetry (ceilometer) API to run as a Web Server Gateway Interface (WSGI) applet under httpd instead of a standalone service. This process disables the standalone openstack-ceilometer-api service and installs the necessary configuration to enable the WSGI applet.

  1. Disable the OpenStack Telemetry service. This step varies based on whether you use highly available controller nodes or not.

    • For environments without high availability:

      $ sudo systemctl stop openstack-ceilometer-api
    • For environments with high availability:

      $ sudo pcs resource disable openstack-ceilometer-api
  2. On each controller, copy the OpenStack Telemetry service WSGI applet (/lib/python2.7/site-packages/ceilometer/api/app.wsgi) to a new directory in /var/www/cgi-bin/. For example:

    $ sudo mkdir /var/www/cgi-bin/ceilometer
    $ cp /lib/python2.7/site-packages/ceilometer/api/app.wsgi /var/www/cgi-bin/ceilometer/app
  3. On each controller, create a virtual host configuration file (10-ceilometer_wsgi.conf) for the OpenStack Telemetry service. Save this file in /etc/httpd/conf.d/. The contents of the virtual host file should resemble the following:

    Listen 8777
    
    <VirtualHost *:8777>
      DocumentRoot "/var/www/cgi-bin/ceilometer"
    
      <Directory "/var/www/cgi-bin/ceilometer">
        Options Indexes FollowSymLinks MultiViews
        AllowOverride None
        Require all granted
      </Directory>
    
      ErrorLog "/var/log/httpd/ceilometer_wsgi_error.log"
      ServerSignature Off
      CustomLog "/var/log/httpd/ceilometer_wsgi_access.log" combined
    
      SetEnvIf X-Forwarded-Proto https HTTPS=1
      WSGIApplicationGroup %{GLOBAL}
      WSGIDaemonProcess ceilometer group=ceilometer processes=1 threads=4 user=ceilometer
      WSGIProcessGroup ceilometer
      WSGIScriptAlias / "/var/www/cgi-bin/ceilometer/app"
    </VirtualHost>
  4. Restart the httpd service. This step varies based on whether you use highly available controller nodes or not.

    • For environments without high availability:

      $ sudo systemctl restart httpd
    • For environments with high availability:

      $ sudo pcs resource restart httpd

7.2. Migrating the OpenStack Telemetry Alarming Database

As a part of the upgrade, aodh-dbsync tool creates a new MariaDB database. However, the previous database used MongoDB. This procedure migrates the past OpenStack Telemetry Alarming (aodh) service’s database from MongoDB to MariaDB. Perform this step after upgrading your environment.

Edit the /etc/aodh/aodh.conf configuration file and change the database connection to a MariaDB database. For example:

[database]
connection = mysql+pymysql://username:password@host/aodh?charset=utf8

Run the following command to perform the migration:

$ sudo /usr/bin/aodh-data-migration \
  --nosql-conn `crudini --get /etc/ceilometer/ceilometer.conf database connection` \
  --sql-conn `crudini --get /etc/aodh/aodh.conf database connection`

This command migrates data from MongoDB (through --nosql-conn) to MariaDB (through --sql-conn).