Use information in this topic to:
-
Switch from the built-in database to an alternate database.
A CloudBees CD/RO enterprise license is required to configure an alternate database. -
Switch from the current alternate database to a different alternate database.
For information about supported alternate databases, refer to Database requirements.
To change to the built-in database, refer to Switch from an alternate database to the built-in database.
The export and import commands are used to do perform the major tasks when migrating data from one database to the other. These are CloudBees CD/RO API commands to export/import database contents into an XML file.
CloudBees CD/RO supports Oracle JDBC connections using the SID or service name:
|
Switching databases
Disable server activities
Before you perform an export, ensure that the CloudBees CD/RO server is inactive — meaning that it cannot accept jobs — by completing the following actions on the server:
-
Disable any active polling triggers and all project schedules.
-
From the main menu, navigate to
. -
In the Enabled column, disable any active triggers.
-
From the main menu, navigate to
. -
Select Electric Cloud from the Projects tab.
-
Select the Schedules tab and disable all schedules, including any polling triggers.
-
-
Make sure all jobs are stopped.
-
From the main menu, navigate to the Platform Home Page.
-
Select the Jobs tab.
-
Review the jobs list and take action to stop all jobs.
-
-
Disable all resources so that no new job steps can run.
-
From the main menu, navigate to the Resources list.
-
Disable each resource by clearing its state from the Enabled column.
-
A quiescent database ensures a complete XML database file is exported.
Move the data
-
Export your data from the existing database. This command can be run from any location with an
ectool
binary in/opt/cloudbees/sda/bin
by default, but the file is stored on the CloudBees CD/RO server file system.ectool export <filename> --compress 1 --withAcls true --withNotifiers true
If you don’t run the above command on the CloudBees CD/RO server, you must specify the server hostname: ectool --server <server_host> login <username> ENTER_PASSWORD_HERE ectool --server <server_host> export --compress 1 --withAcls true --withNotifiers true
If CloudBees CD/RO is installed in a Kubernetes cluster, you must log in to a container in the flow-server
pod to run theectool export
command. You can also run theectool export
command in a job step. If you run the command in a job step, you do not have to specify the server or sign in. -
Set the database configuration using the web interface or
ectool
. For more information, refer to Configure CloudBees CD/RO to use an alternate database. -
Restart the CloudBees CD/RO server:
ectool shutdownServer --restart 1
-
Import your data to the new database:
ectool import <filename> --force 1
-
Reverse steps taken in Disable server activities to enable server activities.