CloudStack系列 升级

CloudStack在实验室实践过程,升级部分。

Update System-VM templates

Database Preparation

Backup current database

Stop your management server or servers. Run this on all management server hosts:
If you are running a usage server or usage servers, stop those as well:

# service cloudstack-management stop
# service cloudstack-usage stop

Make a backup of your MySQL database. If you run into any issues or need to roll back the upgrade, this will assist in debugging or restoring your existing environment. You’ll be prompted for your password.

# mysqldump -u root -p cloud > cloud-backup_`date '+%Y-%m-%d'`.sql
# mysqldump -u root -p cloud_usage > cloud_usage-backup_`date '+%Y-%m-%d'`.sql

Management Server on CentOS/RHEL

If you are using CentOS or RHEL, follow this procedure to upgrade your packages. If not, skip to hypervisors section, then System-VMs and Virtual-Routers.

Note
Community Packages: This section assumes you’re using the community supplied packages for CloudStack. If you’ve created your own packages and yum repository, substitute your own URL for the ones used in these examples.

CloudStack RPM repository

The first order of business will be to change the yum repository for each system with CloudStack packages. This means all management servers, and any hosts that have the KVM agent.

(No changes should be necessary for hosts that are running VMware or Xen.)

Start by opening /etc/yum.repos.d/cloudstack.repo on any systems that have CloudStack packages installed.

This file should have content similar to the following:

[apache-cloudstack]
name=Apache CloudStack
baseurl=http://cloudstack.apt-get.eu/rhel/4.4/
enabled=1
gpgcheck=0

If you are using the community provided package repository, change the base url to http://packages.shapeblue.com/cloudstack/upstream/centos/4.5/ If you want to use the CentOS7 repository use the url http://packages.shapeblue.com/cloudstack/upstream/centos7/4.5/

Setup the GPG public key if you wish to enable gpgcheck=1:

wget http://packages.shapeblue.com/release.asc
rpm --import release.asc

If you’re using your own package repository, change this line to read as appropriate for your 4.5 repository.

Now that you have the repository configured, it’s time to upgrade the cloudstack-management.

CloudStack update

#
yum upgrade cloudstack-management
yum upgrade cloudstack-usage