Migrate Databases to Planning Analytics as a Service
To start using existing planning models in Planning Analytics as a Service (PAaaS), you will need to migrate from another database. In addition to this, if there are Planning Analytics Workspace (PAW) Books in the source environment these will also need to be migrated separately. For the database migration, follow the appropriate steps based on the location of the source database:
- Planning Analytics as a Service
- Planning Analytics on Premise or Planning Analytics on Cloud
Contents:
Create a Database | Migrate from "as a Service" | Migrate from On-premise or "on Cloud" | Migrate PAW Books
Create a database
Before migrating, you will need to have a new database created in PAaaS. Please refer to this blog steps: https://ibm.biz/CS_PAaaS_PrepDev
When you name the database and you plan to migrate an existing database, the name should be the same as the database you are moving as this will reduce the need to edit any objects that reference the database.
Migrate from Planning Analytics as a Service
When migrating between PAaaS, follow these steps in Planning Analytics Workspace:
- Create a backup of your source database
* Login to Planning Analytics Workspace
* Click the Administration tile
* Click Databases
* Select your source database
* Click the Backup tab
* Click Create
* Enter a Backup name and click Create
* During the process, you will see two status messages
* The backup file will be in a .tgz format and denoted as a Manual type:
- Download the backup file
* Click the Action button (⋮) next to your backup and select Download
- Upload backup file to a new target database
* Similar to step 1, select your target database and goto the Backup tab
* Click the Upload button
* In the dialogue box, browse to and select or drag over your backup file
* Click Upload
- Restore backup file to a new target database
* Click the Action button (⋮) next to your uploaded file and select Restore
* In the dialogue box, confirm by clicking the checkbox and click Restore
* During the process, you will see two status messages:
Migrate from an Existing Database (on-premise or PAoC)
These steps are specifically for PA V11 databases currently located on-premise or on Planning Analytics on Cloud (PAoC). To determine if you have PAoC, your URL will look like one of the following:
- <myserver>.planning-analytics.cloud.ibm.com
- <myserver>.planning-analytics.ibmcloud.com
Before migrating, understand that some objects or functions will not be migrated. For example:
To migrate your v11 database to PAaaS, follow these steps:
- Install Gitbash: https://ibm.biz/CS_PAaaS_Gitbash
- Prepare your source database by having at least running SaveDataAll to commit all data to files.
For a complete list of preparation steps refer to: https://ibm.biz/CS_PAaaS_MigrationSteps
- Copy your PA database folders to a temporary location. For PAoC you will need to first zip up and download either using FTP or Drive Explorer in Planning Analytics Workspace: https://ibm.biz/CS_PAoC_Conf_FTP
For example, I have copied the SData database to C:\temp\SData
- In your temporary folder, you may need to update the tm1s.cfg file so it references the correct path in your temporary folder. This is accomplished by modifying the DataBaseDirectory configuration:
DataBaseDirectory=. <indicates the database is in the same folder as the tm1s.cfg>
DataBaseDirectory=data <indicates the database is in a sub folder called data relative to the location of tm1s.cfg>
- Download conversion utility from Planning Analytics Workspace (PAW)
* Login to PAW
* Click Administration
* Click Databases
* Click Download icon and choose Database Migration Utility
* A .zip file will be saved to your downloads folder
- Extract zip file to a temporary folder
For example, C:\Temp\migration_tool\
Inside the new folder are two more zip files - one for Linux and Windows. For this demo, extract the windows version:
For example: C:\Temp\migration_tool\migration_tool-windows"
- Run conversion using gitbash
* launch a gitbash session: Click windows, type gitbash and select Open
* In gitbash, change to the utility folder and run it with parameters to indicate the source database and migrated file. For example:
--input "C:\Temp\SData"
--output "file://localhost/c:/Temp/SData.tar.gz"
cd /c/Temp/migration_tool/migration_tool-windows
./migrate_tm1.sh --input "C:\Temp\SData" --output "file://localhost/c:/Temp/SData.tar.gz"
The .tar.gz file will be created and a detailed log will be created indicating any errors. Keep in mind that some errors are expected such as deprecated functions which can be ignored. Logs can be found in the migrate.log file.
- With the conversion completed, the next steps are done in Planning Analytics Workspace for the new, "as a Service" environment
* Go to Administration, Databases, and click the database you wish to import into. i.e. SData
* Stop the database if it is currently running:
* Click the Backup tab, and click the Upload button
* In the dialogue box, choose the newly created .tar.gz file. i.e. SData.tar.gz
* Once the upload is completed, click the menu to the right of the file and choose Restore
* During the restore process, the database will show a status as below:
* Once complete, it will show as this:
- With the migration complete, you may now verify objects and data in Planning Analytics Workspace. In addition to this, you may need to migrate some functionality that no longer exists. i.e. ExecuteProcess will need to be replaced with ExecuteHttpRequest.
Migrate Planning Analytics Workspace Books
Once your database has been migrated, you may also need to copy PAW Books. To do so, refer to the following links for Lifecycle Management: