From 380c7c6979e78fd4f15616b015a342d7960af986 Mon Sep 17 00:00:00 2001 From: Alvaro Lopez Garcia Date: Mon, 21 Jan 2013 16:04:37 +0100 Subject: [PATCH] Added upgrade process from Essex to Folsom. It covers Keystone, Glance, Nova and nova-volume to Cinder upgrade, but lacks nova-network to Quantum. Patchset does minor style and spelling fixes. Making sure that the style fixes get in too by testing the merge. Sorry about the lack of "git add" on my part with the file rename. bug #1043032 DocImpact Change-Id: I57b351a83ab00eb13871e7780e320c09e31482d9 --- .../bk_openstackinstallguide.xml | 18 +- .../ch_upgrading_from_essex.xml | 439 ++++++++++++++++++ 2 files changed, 456 insertions(+), 1 deletion(-) create mode 100644 doc/src/docbkx/openstack-install/ch_upgrading_from_essex.xml diff --git a/doc/src/docbkx/openstack-install/bk_openstackinstallguide.xml b/doc/src/docbkx/openstack-install/bk_openstackinstallguide.xml index 00485cb4220..93f1517099b 100644 --- a/doc/src/docbkx/openstack-install/bk_openstackinstallguide.xml +++ b/doc/src/docbkx/openstack-install/bk_openstackinstallguide.xml @@ -28,7 +28,7 @@ Grizzly, Compute 2013.1, Network 2013.1, Object Storage 1.7.6 OpenStack - 2013-01-16 + 2013-02-12 Copyright details are filled in by the template. @@ -53,6 +53,20 @@ as well as sample configuration files. + + 2013-02-12 + + + + Adds chapter about Essex to Folsom + upgrade for Compute and related + services (excludes OpenStack Object + Storage (Swift) and OpenStack + Networking (Quantum). + + + + 2013-01-16 @@ -351,6 +365,8 @@ + + diff --git a/doc/src/docbkx/openstack-install/ch_upgrading_from_essex.xml b/doc/src/docbkx/openstack-install/ch_upgrading_from_essex.xml new file mode 100644 index 00000000000..4528c9f987e --- /dev/null +++ b/doc/src/docbkx/openstack-install/ch_upgrading_from_essex.xml @@ -0,0 +1,439 @@ + + + OpenStack Folsom upgrade + This chapter will lead you through the Essex to Folsom upgrade + process. If you are running an earlier version, you should upgrade to Essex + before continuing. + + As a preliminary step, you should check the release + notes: + + + Folsom release notes, 2012.2. + + + + 2012.2.1. + + + + 2012.2.2. + + + 2012.2.3. + + + + The upgrade process will be done in the following steps: + + + Upgrade the OpenStack Identity service (Keystone). + + + Upgrade the OpenStack Image service (Glance). + + + Upgrade all OpenStack Compute (Nova) services. + + + Optional: Upgrade nova-volume to OpenStack Block Storage (Cinder). Please note that nova-volume will be deprecated in the + following release. + + + Optional: Upgrade nova-network to OpenStack Networking (Quantum). Please note that nova-network will be deprecated in + the following release. + + + +
+ Identity service (Keystone) upgrade + + + + Stop the services: + $ sudo service keystone stop +$ ps aux | grep keystone + + + + + + Create a backup of your configuration files and of your database contents: + $ sudo cp -a /etc/keystone $HOME/keystone_conf.bkp +$ mysqldump -u KEYSTONE_USER -pKEYSTONE_PASSWORD KEYSTONE_DB > $HOME/keystone_db_backup.sql + + + + + + Upgrade the packages to the latest 2012.2 version, using your distribution package manager. + + + + + + Apply the database upgrade. + $ sudo keystone-manage db_sync + + + + + + Start the keystone service: + $ sudo service keystone restart + + + + + + Check that everything is running fine: + $ keystone user-list ++---------------------------------------------------------+---------------------------------------------------------+---------+--------------------------+ +| id | name | enabled | email | ++---------------------------------------------------------+---------------------------------------------------------+---------+--------------------------+ +(...) + + + + +
+ +
+ Image service (Glance) upgrade + + + + Stop the services: + $ sudo service glance-api stop +$ sudo service glance-registry stop +$ ps aux | grep glance + + + + + + Create a backup of your configuration files and of your database contents: + $ sudo cp -a /etc/glance $HOME/glance_conf.bkp +$ mysqldump -u GLANCE_USER -pGLANCE_PASSWORD GLANCE_DB > $HOME/glance_db_backup.sql + + + + + + Upgrade the packages to the latest 2012.2 version, using your distribution package manager. + + + + + + Change the configuration files according to the Release Notes. + + + + You have to + add the sql connection parameters to your API configuration file, or disable the + new v2 API setting the enable_v2_api to false: + sql_connection = sqlite:///glance.sqlite # You should set this to your actual configuration +sql_idle_timeout = 3600 + + + + Also, the auth_token middleware configuration has been moved from the paste + configuration to the server configuration. Unless you have made modifications to your paste + config it is recommended to accept the distributed glance-api-paste.ini and + glance-registry-paste.ini files and then add the auth_token + configuration at the bottom of your glance-api.conf and glance-registry.conf, + adapting it to your actual configuration: + + [keystone_authtoken] +auth_host = 127.0.0.1 +auth_port = 35357 +auth_protocol = http +admin_tenant_name = %SERVICE_TENANT_NAME% +admin_user = %SERVICE_USER% +admin_password = %SERVICE_PASSWORD% + + + + + + + + Apply the database upgrade. + $ sudo glance-manage db_sync + + + + + + Start the glance services: + $ sudo service glance-api restart +$ sudo service glance-registry restart + + + + + + Check that everything is running fine: + $ glance index +ID Name Disk Format Container Format Size +------------------------------------ ------------------------------ -------------------- -------------------- -------------- +(...) + + + + + +
+ +
+ Compute service (Nova) upgrade + We will perform an upgrade of all the nova packages to the Folsom version. However, in this section + we do not cover the upgrade to OpenStack Networking (Quantum) and OpenStack Block Storage (Cinder) of the respective and deprecated nova-network and + nova-volume packages, as this will be covered in another section. + + + + + + Stop all the nova services. + + + + + + Create a backup of your configuration files and of your database contents: + $ sudo cp -a /etc/nova $HOME/nova_conf.bkp +$ mysqldump -u NOVA_USER -pNOVA_PASSWORD NOVA_DB > $HOME/nova_db_backup.sql + + + + + + Upgrade the configuration files according to the + Release Notes. + You have to take into account the following: + + + + + IMPORTANT: If you are backing your instances with shared storage, make sure to disable image + cache BEFORE upgrading to Folsom: + image_cache_manager_interval = 0 + There is a serious issue when using cache manager and shared storage, for more details please check this + this bug report + + + + + Change the nova.conf file to the new configuration format. + In Essex the configuration was based on the old --option-name + format, but in Folsom it has been changed to the INI config format, + with options specified as key=value pairs. Because of this change, + boolean options have to be explicitly set to true/false (such as + verbose=true). The following code: + --debug +--verbose +--state_path=/var/lib/nova +--nouse_cow_images + Will transform into this. + [DEFAULT] +debug=true +verbose=true +state_path=/var/lib/nova +use_cow_images=false + Check the compute options reference card + to check if all your flags are recognized. + + + + + Check new the rootwrap configuration changes. + + + + + If you are using Libvirt: + + + The connection_type flag has been deprecated in favor of the + compute_driver flag, so connection_type=libvirt + should be replaced with compute_driver=libvirt.LibvirtDriver + and connection_type=xenapi should be replaced + with compute_driver=xenapi.XenAPIDriver. + + + + + The libvirt.xml and cpuinfo.xml templates have been removed in favor of a + new config API. + + + + + + + + + + + Upgrade all the packages to the latest 2012.2 version, using your distribution package manager. + Note that we are not migrating nova-network and nova-volume to OpenStack Networking (Quantum) and OpenStack Block Storage (Cinder) in this + step, but just upgrade those packages to Folsom. + + + + + Upgrade the nova api paste. It is recommended to accept the new nova/api-paste.ini + file from the package, and then check it against a backed file for any local modifications. + + + + + Upgrade the nova/policy.json file. Unless you have made local changes you should accept + the new file provided with the package. + + + + + Apply the DB upgrade. + +$ sudo nova-manage db sync + + + + + + Restart all the services. + + + + + Check that everything is working fine: + $ sudo nova-manage service list +(...) + +$ nova list ++--------------------------------------+---------------+---------+-------------------------------------+ +| ID | Name | Status | Networks | ++--------------------------------------+---------------+---------+-------------------------------------+ +(...) + + + + + +
+ +
+ Upgrade nova-volume to OpenStack Block Storage (Cinder) + We assume that all the services (including nova-volume) are migrated to Folsom. + + + + Install Folsom version of OpenStack Block Storage (Cinder). + + + + + Create a cinder user in Keystone as an admin in service tenant. + + + + + Edit /etc/cinder/api-paste.ini to reflect the + admin_user, admin_tenant_name, and admin_password + that you created in the previous step. + + + + + Create Cinder database and database user. + + + + + Check the SQL connection in /etc/cinder/cinder.conf. + + + + + Create initial Cinder database: + $ sudo cinder-manage db sync + + + + + Copy volume tables using the following command: + $ sudo cinder-manage migrate import_db --src=$NOVA_SQL_CONN --dest=$CINDER_SQL_CONN + + + + Do not include the database names in --src or --dest; + cinder-manage assumes your source database is named "nova" + and that your destination database is named "cinder", and appends these + to the strings you supply. + + + + + + Copy iSCSI target configuration + $ sudo cinder-manage migrate copy_ptgt_files --src=/var/lib/nova-volume/volumes --dest=/var/lib/cinder/volumes + + + + + Set the correct volume api class in your nova.conf configuration file. + volume_api_class=nova.volume.cinder.API + + + + + Remove the osapi_volume from the enabled_apis in your /etc/nova/nova.conf. If you do + not have such a configuration option, set it explicitly to the following (as it is included by default): + enabled_apis=ec2,osapi_compute,metadata + + + + + Disable and stop the nova-volume service. + $ sudo echo "manual" > /etc/init/nova-volume.override +$ sudo service nova-volume stop + + + + + Restart the nova-api service + $ sudo service nova-api restart + + + + + Start cinder service: + $ sudo service cinder-api restart + + + + + Ensure that /etc/tgt/conf.d/cinder.conf exists and has an + include line that matches volumes_dir option in cinder.conf. + In the default case this is include /var/lib/cinder/volumes/*, if you edit + this file restart the tgtd service. + + + + +
+ +
+ Upgrade nova-network to OpenStack Networking (Quantum) + This process has not yet been documented. + +
+
+