#
service cloudstack-management stop
#
service cloudstack-usage stop
#
mysqldump -u root -p cloud > cloudstack-backup.sql
#
mysql -u cloud -p -e "select id,name,path from cloud.storage_pool where pool_type='Filesystem'"
#
mysql -u cloud -p -e 'update cloud.storage_pool set path="/var/lib/libvirt/images" where path="/var/lib/libvirt/images/"';
/etc/apt/sources.list.d/cloudstack.list
on any systems that have CloudStack packages installed.
deb http://cloudstack.apt-get.eu/ubuntu precise 4.0
deb http://cloudstack.apt-get.eu/ubuntu precise 4.2
$ sudo apt-get update
cloudstack-management
package. This will pull in any other dependencies you need.
$ sudo apt-get install cloudstack-management
cloudstack-agent
package:
$ sudo apt-get install cloudstack-agent
cloudstack-agent
, APT will copy your agent.properties
, log4j-cloud.xml
, and environment.properties
from /etc/cloud/agent
to /etc/cloudstack/agent
.
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloudstack-agent stop
killall jsvc
service cloudstack-agent start
service cloudstack-management stop
java -classpath /usr/share/cloudstack-common/lib/jasypt-1.9.0.jar org.jasypt.intf.cli.JasyptPBEStringEncryptionCLI encrypt.sh input="_your_vCenter_password_" password="`cat /etc/cloudstack/management/key`" verbose=false
mysql -u <username> -p<password>
select * from cloud.cluster_details;
update cloud.cluster_details set value = '_ciphertext_from_step_1_' where id = _id_from_step_2_;
select * from cloud.cluster_details;
select * from cloud.vmware_data_center;
update cloud.vmware_data_center set password = '_ciphertext_from_step_1_' where id = _id_from_step_5_;
select * from cloud.vmware_data_center;
service cloudstack-management start
# service cloud-agent stop
# yum update cloudstack-agent
# service cloudstack-agent start
/etc/yum.repos.d/cloudstack.repo
on any systems that have CloudStack packages installed.
[apache-cloudstack] name=Apache CloudStack baseurl=http://cloudstack.apt-get.eu/rhel/4.0/ enabled=1 gpgcheck=0
cloudstack-management
package by upgrading the older cloudstack-management
package.
$ sudo yum upgrade cloudstack-management
cloud-agent
package, similarly installing the new version as cloudstack-agent
.
$ sudo yum upgrade cloudstack-agent
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloudstack-agent stop
killall jsvc
service cloudstack-agent start
# service cloudstack-management start
# nohup cloudstack-sysvmadm -d IP address -u cloud -p -a > sysvm.log 2>&1 &
# tail -f sysvm.log
sysvm.log
will look something like this:
Stopping and starting 1 secondary storage vm(s)... Done stopping and starting secondary storage vm(s) Stopping and starting 1 console proxy vm(s)... Done stopping and starting console proxy vm(s). Stopping and starting 4 running routing vm(s)... Done restarting router(s).
vhd-utils
to /usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver
.
Hypervisor
|
Description
|
---|---|
XenServer
|
Name: systemvm-xenserver-4.2
Description: systemvm-xenserver-4.2
URL:http://download.cloud.com/templates/4.2/systemvmtemplate-2013-07-12-master-xen.vhd.bz2
Zone: Choose the zone where this hypervisor is used
Hypervisor: XenServer
Format: VHD
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
KVM
|
Name: systemvm-kvm-4.2
Description: systemvm-kvm-4.2
URL: http://download.cloud.com/templates/4.2/systemvmtemplate-2013-06-12-master-kvm.qcow2.bz2
Zone: Choose the zone where this hypervisor is used
Hypervisor: KVM
Format: QCOW2
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
VMware
|
Name: systemvm-vmware-4.2
Description: systemvm-vmware-4.2
URL: http://download.cloud.com/templates/4.2/systemvmtemplate-4.2-vh7.ova
Zone: Choose the zone where this hypervisor is used
Hypervisor: VMware
Format: OVA
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
/etc/yum.repos.d/cloudstack.repo
on any systems that have CloudStack packages installed.
[upgrade] name=rhel63 baseurl=url-of-your-rhel6.3-repo enabled=1 gpgcheck=0 [apache CloudStack] name= Apache CloudStack baseurl= http://cloudstack.apt-get.eu/rhel/4.0/ enabled=1 gpgcheck=0
# yum upgrade
# service cloud-usage stop
# service cloud-management stop
#
mysqldump
-u root -pmysql_password
cloud >cloud-backup.dmp
#
mysqldump
-u root -pmysql_password
cloud_usage >cloud-usage-backup.dmp
/etc/apt/sources.list.d/cloudstack.list
on any systems that have CloudStack packages installed.
deb http://cloudstack.apt-get.eu/ubuntu precise 4.0
deb http://cloudstack.apt-get.eu/ubuntu precise 4.2
$ sudo apt-get update
cloudstack-management
package. This will pull in any other dependencies you need.
$ sudo apt-get install cloudstack-management
cloudstack-agent
package:
$ sudo apt-get install cloudstack-agent
cloudstack-agent
, APT will copy your agent.properties
, log4j-cloud.xml
, and environment.properties
from /etc/cloud/agent
to /etc/cloudstack/agent
.
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloud-agent stop
killall jsvc
service cloudstack-agent start
log4j-cloud.xml
was simply copied over, so the logs will continue to be added to /var/log/cloud/agent/agent.log
. There's nothing wrong with this, but if you prefer to be consistent, you can change this by copying over the sample configuration file:
cd /etc/cloudstack/agent mv log4j-cloud.xml.dpkg-dist log4j-cloud.xml service cloudstack-agent restart
sudo dpkg --purge cloud-agent
/etc/yum.repos.d/cloudstack.repo
on any systems that have CloudStack packages installed.
[apache-cloudstack] name=Apache CloudStack baseurl=http://cloudstack.apt-get.eu/rhel/4.0/ enabled=1 gpgcheck=0
cloudstack-management
package by upgrading the older cloud-client
package.
$ sudo yum upgrade cloud-client
cloud-agent
package, similarly installing the new version as cloudstack-agent
.
$ sudo yum upgrade cloud-agent
cloudstack-agent
, the RPM will copy your agent.properties
, log4j-cloud.xml
, and environment.properties
from /etc/cloud/agent
to /etc/cloudstack/agent
.
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloud-agent stop
killall jsvc
service cloudstack-agent start
/etc/cloud/management/components.xml
the changes will be preserved in the upgrade. However, you need to do the following steps to place these changes in a new version of the file which is compatible with version 4.2.0.
/etc/cloud/management/components.xml
. For example:
# mv /etc/cloud/management/components.xml /etc/cloud/management/components.xml-backup
/etc/cloud/management/components.xml.rpmnew
to create a new /etc/cloud/management/components.xml
:
# cp -ap /etc/cloud/management/components.xml.rpmnew /etc/cloud/management/components.xml
components.xml
.
# vi /etc/cloudstack/management/components.xml
<!-- Security adapters --> <bean id="userAuthenticators" class="com.cloud.utils.component.AdapterList"> <property name="Adapters"> <list> <ref bean="PlainTextUserAuthenticator"/> <ref bean="MD5UserAuthenticator"/> <ref bean="LDAPUserAuthenticator"/> </list> </property> </bean>
# service cloudstack-management start
# service cloudstack-usage start
# service cloud-agent stop
# yum update cloud-*
# apt-get update
# apt-get upgrade cloud-*
/etc/cloudstack/agent/agent.properties
to change the resource parameter from "com.cloud.agent.resource.computing.LibvirtComputingResource" to "com.cloud.hypervisor.kvm.resource.LibvirtComputingResource".
# cloudstack-agent-upgrade
# mkdir /etc/libvirt/hooks # cp /usr/share/cloudstack-agent/lib/libvirtqemuhook /etc/libvirt/hooks/qemu # chmod +x /etc/libvirt/hooks/qemu
# service libvirtd restart
# service cloudstack-agent start
cloudstack-sysvmadm
script to stop, then start, all Secondary Storage VMs, Console Proxy VMs, and virtual routers. Run the script once on each management server. Substitute your own IP address of the MySQL instance, the MySQL user to connect as, and the password to use for that user. In addition to those parameters, provide the -c
and -r
arguments. For example:
# nohup cloudstack-sysvmadm -d 192.168.1.5 -u cloud -p password -c -r > sysvm.log 2>&1 &
# tail -f sysvm.log
/opt/xensource/bin/cloud-clean-vlan.sh
/opt/xensource/bin/cloud-prepare-upgrade.sh
xe patch-upload file-name=XS602E003.xsupdate
# xe vm-list
# xe vm-migrate live=true host=host-name
vm=VM-name
/opt/xensource/bin/make_migratable.sh b6cf79c8-02ee-050b-922f-49583d9f1a14
.
# xe host-list
xe
patch-apply host-uuid=host-uuid
uuid=hotfix-uuid
Copy from here...
|
...to here
|
---|---|
/usr/lib64/cloud/common/scripts/vm/hypervisor/xenserver/xenserver60/NFSSR.py
|
/opt/xensource/sm/NFSSR.py
|
/usr/lib64/cloud/common/scripts/vm/hypervisor/xenserver/setupxenserver.sh
|
/opt/xensource/bin/setupxenserver.sh
|
/usr/lib64/cloud/common/scripts/vm/hypervisor/xenserver/make_migratable.sh
|
/opt/xensource/bin/make_migratable.sh
|
# tar xf xenserver-cloud-supp.tgz
# xe-install-supplemental-pack xenserver-cloud-supp.iso
# xe-switch-network-backend bridge
/opt/xensource/bin/setupxenserver.sh
for pbd in `xe pbd-list currently-attached=false| grep ^uuid | awk '{print $NF}'`; do xe pbd-plug uuid=$pbd ;
Hypervisor
|
Description
|
---|---|
XenServer
|
Name: systemvm-xenserver-4.2
Description: systemvm-xenserver-4.2
URL:http://download.cloud.com/templates/4.2/systemvmtemplate-2013-07-12-master-xen.vhd.bz2
Zone: Choose the zone where this hypervisor is used
Hypervisor: XenServer
Format: VHD
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
KVM
|
Name: systemvm-kvm-4.2
Description: systemvm-kvm-4.2
URL: http://download.cloud.com/templates/4.2/systemvmtemplate-2013-06-12-master-kvm.qcow2.bz2
Zone: Choose the zone where this hypervisor is used
Hypervisor: KVM
Format: QCOW2
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
VMware
|
Name: systemvm-vmware-4.2
Description: systemvm-vmware-4.2
URL: http://download.cloud.com/templates/4.2/systemvmtemplate-4.2-vh7.ova
Zone: Choose the zone where this hypervisor is used
Hypervisor: VMware
Format: OVA
OS Type: Debian GNU/Linux 7.0 (32-bit) (or the highest Debian release number available in the dropdown)
Extractable: no
Password Enabled: no
Public: no
Featured: no
|
/etc/yum.repos.d/cloudstack.repo
on any systems that have CloudStack packages installed.
[upgrade] name=rhel63 baseurl=url-of-your-rhel6.3-repo enabled=1 gpgcheck=0 [apache CloudStack] name= Apache CloudStack baseurl= http://cloudstack.apt-get.eu/rhel/4.0/ enabled=1 gpgcheck=0
# yum upgrade
# service cloud-usage stop
# service cloud-management stop
#
mysqldump
-u root -pmysql_password
cloud >cloud-backup.dmp
#
mysqldump
-u root -pmysql_password
cloud_usage >cloud-usage-backup.dmp
/etc/apt/sources.list.d/cloudstack.list
on any systems that have CloudStack packages installed.
deb http://cloudstack.apt-get.eu/ubuntu precise 4.0
deb http://cloudstack.apt-get.eu/ubuntu precise 4.2
$ sudo apt-get update
cloudstack-management
package. This will pull in any other dependencies you need.
$ sudo apt-get install cloudstack-management
cloudstack-agent
package:
$ sudo apt-get install cloudstack-agent
cloudstack-agent
, APT will copy your agent.properties
, log4j-cloud.xml
, and environment.properties
from /etc/cloud/agent
to /etc/cloudstack/agent
.
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloud-agent stop
killall jsvc
service cloudstack-agent start
log4j-cloud.xml
was simply copied over, so the logs will continue to be added to /var/log/cloud/agent/agent.log
. There's nothing wrong with this, but if you prefer to be consistent, you can change this by copying over the sample configuration file:
cd /etc/cloudstack/agent mv log4j-cloud.xml.dpkg-dist log4j-cloud.xml service cloudstack-agent restart
sudo dpkg --purge cloud-agent
/etc/yum.repos.d/cloudstack.repo
on any systems that have CloudStack packages installed.
[apache-cloudstack] name=Apache CloudStack baseurl=http://cloudstack.apt-get.eu/rhel/4.0/ enabled=1 gpgcheck=0
cloudstack-management
package by upgrading the older cloud-client
package.
$ sudo yum upgrade cloud-client
cloud-agent
package, similarly installing the new version as cloudstack-agent
.
$ sudo yum upgrade cloud-agent
cloudstack-agent
, the RPM will copy your agent.properties
, log4j-cloud.xml
, and environment.properties
from /etc/cloud/agent
to /etc/cloudstack/agent
.
/etc/cloudstack/agent/environment.properties
has a line that reads:
paths.script=/usr/share/cloudstack-common
service cloud-agent stop
killall jsvc
service cloudstack-agent start
warning: /etc/cloud/management/components.xml created as /etc/cloud/management/components.xml.rpmnew
/etc/cloud/management/components.xml
file. For example:
#
mv
/etc/cloud/management/components.xml
/etc/cloud/management/components.xml-backup
/etc/cloud/management/components.xml.rpmnew
to create a new /etc/cloud/management/components.xml
:
#
cp
-ap/etc/cloud/management/components.xml.rpmnew
/etc/cloud/management/components.xml
#
vi
/etc/cloudstack/management/components.xml
<!-- Security adapters --> <bean id="userAuthenticators" class="com.cloud.utils.component.AdapterList"> <property name="Adapters"> <list> <ref bean="PlainTextUserAuthenticator"/> <ref bean="MD5UserAuthenticator"/> <ref bean="LDAPUserAuthenticator"/> </list> </property> </bean>
/etc/cloud/management/db.properties
file in your previous-version CloudStack installation, the changes will be preserved in the upgrade. However, you need to do the following steps to place these changes in a new version of the file which is compatible with version 4.0.0-incubating.
/etc/cloud/management/db.properties
. For example:
#
mv
/etc/cloud/management/db.properties
/etc/cloud/management/db.properties-backup
/etc/cloud/management/db.properties.rpmnew
to create a new /etc/cloud/management/db.properties
:
#
cp
-ap/etc/cloud/management/db.properties.rpmnew
etc/cloud/management/db.properties
#
vi
/etc/cloudstack/management/db.properties
#
cloudstack-setup-encryption
-eencryption_type
-mmanagement_server_key
-kdatabase_key
# service cloudstack-management start
# service cloudstack-usage start
# service cloud-agent stop
#
yum
update cloud-*
#
apt-get
update#
apt-get
upgrade cloud-*
agent.properties
file to the new agent.properties
file by using the following command
sed
-i 's/com.cloud.agent.resource.computing.LibvirtComputingResource/com.cloud.hypervisor.kvm.resource.LibvirtComputingResource/g'/etc/cloudstack/agent/agent.properties
# cloudstack-agent-upgrade
# mkdir /etc/libvirt/hooks # cp /usr/share/cloudstack-agent/lib/libvirtqemuhook /etc/libvirt/hooks/qemu # chmod +x /etc/libvirt/hooks/qemu
# service libvirtd restart
# service cloudstack-agent start
#
nohup cloudstack-sysvmadm
-d192.168.1.5
-u cloud -ppassword
-c -r > sysvm.log 2>&1 &#
tail
-fsysvm.log
#
tail
-fsysvm.log
Stopping and starting 1 secondary storage vm(s)... Done stopping and starting secondary storage vm(s) Stopping and starting 1 console proxy vm(s)... Done stopping and starting console proxy vm(s). Stopping and starting 4 running routing vm(s)... Done restarting router(s).
#
ssh
-iprivate-key-path
link-local-ip
-p 3922 # cat /etc/cloudstack-release
Cloudstack Release 4.0.0-incubating Mon Oct 9 15:10:04 PST 2012
#
ssh
-iprivate-key-path
private-ip
-p 3922#
cat
/etc/cloudstack-release
Cloudstack Release 4.0.0-incubating Mon Oct 9 15:10:04 PST 2012
/opt/xensource/bin/cloud-clean-vlan.sh
/opt/xensource/bin/cloud-prepare-upgrade.sh
xe patch-upload file-name=XS602E003.xsupdate
# xe vm-list
#
xe
vm-migrate live=true host=host-name
vm=VM-name
/opt/xensource/bin/make_migratable.sh b6cf79c8-02ee-050b-922f-49583d9f1a14
.
# xe host-list
xe patch-apply host-uuid=host-uuid
uuid=hotfix-uuid
Copy from here...
|
...to here
|
---|---|
/usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver/xenserver60/NFSSR.py
|
/opt/xensource/sm/NFSSR.py
|
/usr/share/cloudstack-common/scripts/vm/hypervisor/xenserver/setupxenserver.sh
|
/opt/xensource/bin/setupxenserver.sh
|
/usr/lib64/cloudstack-common/scripts/vm/hypervisor/xenserver/make_migratable.sh
|
/opt/xensource/bin/make_migratable.sh
|
# tar xf xenserver-cloud-supp.tgz
# xe-install-supplemental-pack xenserver-cloud-supp.iso
# xe-switch-network-backend bridge
/opt/xensource/bin/setupxenserver.sh
for pbd in `xe pbd-list currently-attached=false| grep ^uuid | awk '{print $NF}'`; do xe pbd-plug uuid=$pbd ;