Migrating Connections DB from Oracle to DB2 part 1

For those of you that follow me on twitter, you will have noticed that I have posted a number of tweets relating to a fun project I am working on.

I have been working with a customer to move them from Connections 5 to Connections 5.5 – Not a massive issue – EXCEPT they are currently using Oracle for the Connections DB and they can not upgrade it to the version required by 5.5 for quite some time, as most of their business systems require the version of Oracle currently running.

This has been a pain .. like you wouldn’t believe .. what should be a simple process has turned into the project from hell!! BUT I am not one to throw the towel in so we have persevered. I must say I was not overly enthused by some of the issues and mistakes that have been made on our side and IBMs but we do have light at the end of the tunnel.

I am going to work through a series of Blog posts to help anyone else who needs to do this ..

Migrating Connections DB from Oracle to DB2

Overview

  1. Open a PMR – you will need specific help from IBM as this is an unsupported action – they will help you though. Be VERY specific and clear in exactly what you are trying to achieve as it can lead to confussion.
    • State the version of the DB you are moving from – in this case Oracle 11.2 on AIX
    • State the version of the DB are moving too – DB2 10.1 on Windows
    • State why you are doing this – as this is important for justifying the support time to help. In our case the customer is a current Connections 5 and Docs user, we have a requirement to upgrade Connections to  V5.5 to take advantage of the new features. As Connections 5.5 requires Oracle 12 and the customer can not update the underlying oracle system a move to DB2 is the best course of action. DB2 for Connections will be managed independantly from the rest of the applications.
    • Test the migrated Oracle data with DB2 and Connections 5 to ensure the system is working as expected.
    • Migrate the tested data to Connections 5.5
    • Then do it for real in live
  2. Make sure you have data to test – in our case there is a Connections 5 dev environment pointing to an oracle DB.
  3. Prepare a system to recieve the data – The Connections 5 dev system already had the correct version of DB2 installed as we were using IBM Docs and FEB (for Connections Surveys). We simply created the additional Connections 5 DBs on the dev machine ready to accept the data.
  4. Become familiar with the DBT – The Database Transfer Tool is the only way to get the data out of one system and into another. There are files to prepare and commands to comprise. Have a good text editor, with tabs, you will need it – notepad isn’t going to cut it.
  5. Get good BACKUPS – Backup the clean Connections 5 DBs before attempting to migrate you may need to roll it back, also ensure you back up any existing DBs you have (such as CONCORD for Docs or FEB for Surveys).
  6. Be preapred for multiple attempts – There is a lot of trail and error and fixing issues and trying again. This is not a one time deal.
  7. Logs and SQL queries – There will be a lot of looking at logs and running SQL queries, editing the create db scripts and running again. If you aren’t comfortable with that find someone to help you as you will be by the time we are done.

Things to note

I assumed that becuase I already have a DEV version 5 Connections system I could use that. Create new DBs, migrate the data, switch the datasources to the new database and we should be good – NO – THAT DOESN’T WORK!!

When Connections is installed and you select the type of DB that you are installing against, that is hardcoded somewhere in a config that we couldn’t find .. we WASTED SO MUCH TIME trying to get that sorted and eventually had to give up and reinstall.

If you have an existing system – BACK IT UP, blow it away and reinstall. Don’t waste time and effort trying to fix it .. files will not work.

 

Step 1 – Open a PMR

You MUST do this. IBM will help you even though they do not officially support moving DB types and OS’s. It is much easier if you are staying on the same OS or same DB type, but moving both isn’t fun. This should theoretically be a once only deal – once moved from Oracle AIX to Windows DB2 there will be no going back.

As I stated in the overview be VERY specific and explain exactly what you are trying to achieve. Give IBM the exact DB versions with fixes so they can give you new versions of any DB create scripts they need. In my case Files, Wikis and Blogs needed significant changes to the database create scripts. IBM also sent additional scripts for the fixup post migration so ensure you have those. Back up the original connections.sql folder under the V5 wizards directory (connections.sql.backup in my case) and add any changes to connections.sql.

 

Step 2 – Test data

Make sure you have data to test with. Initially I used the Connections 5 DEV system to test but have since moved on to live data, but the test data has to be from a working system so you can compare.

You must have access to read and write to the DBs as this is required to actually migrate the data. Back up the file system to copy the shared data over.

There may also be differences in data between your live and dev systems so be prepared to edit scripts again and keep copies of all the scripts and workings out you have done.. it will help you document it (yes I said the D word .. Write it all down, you will thank me for it later).

 

Check out Part 2 where we will actually prepare the system and write everything we need to actually get on and do the data migration.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.