Migrating data from DB2 to PostgreSQL
If you previously used RICOH ProcessDirector with DB2 and are migrating to the PostgreSQL database configuration, you must migrate
your data from one database to the other after installing the update.
To migrate your data from DB2 to PostgreSQL:
- Log in to the primary computer using the RICOH ProcessDirector administrator account.
- Open a command prompt as an administrator.Even if you are logged on to your system as an administrator, you must start the command prompt by selecting Run as administrator from the right-click menu.
- Make sure that you can access both the DB2 and PostgrSQL databases.
- Open the DB2 command window by typing: db2cw.bat
- To check for DB2, type in the DB2 command window: db2 connect to aiwdb
- To check for PostgreSQL:
- Prepare a migration directory.
- Create a temporary directory for the migration. For example, %AIWDATA%\tmp\migrateDb2ToPostgresql.
- Navigate to %AIWPATH%\base\packages.
- Copy migrateDb2toPostgresql-version.zip to your temporary migration directory and unzip.
- Run the migration tool.
- Stop the RICOH ProcessDirector service.Note: If the service is already stopped, start and then stop the service to ensure PostgreSQL is running. See Starting and stopping the RICOH ProcessDirector service for more information.
- Open a command prompt as an administrator. Run ippdprofile and type the script name: migrateDb2ToPostgresql.pl.
The migration starts by restarting the activation to create tables in the PostgreSQL database. Activation status messages are displayed.When the activation is complete, the script runs the migration. As the migration script runs, you should see status messages such as: Migrating table <tablename>
- Note:
- Additional log messages are written to %AIWPATH%\logs\installer\react-logs.log and %AIWPATH%\logs\installer\migrateDb2ToPostgresql.log.
- If you see error messages during the migration, see Troubleshooting data migration errors.
- Stop the RICOH ProcessDirector service.
- Restart the RICOH ProcessDirector service to apply the changes.
See Starting and stopping the RICOH ProcessDirector service for more information.
- Log in to RICOH ProcessDirector. All objects and jobs should now appear on the Main page.
- After you verify everything, proceed with uninstalling the DB2 database.
- To uninstall DB2:
- Click the Windows Start button and type services to search for the Services App. Open the Services App, then find DB2 - DB2COPY1 – AIWINST-0 and check the status. If it is running, stop this service.
- Start a command prompt as an administrator. Even if you are logged on to your system as an administrator, you must start the command prompt by selecting Run as administrator from the right-click menu.
- To open the DB2 command window, type: db2cw.bat
- Enter these commands in the DB2 command window to delete the aiwinst instance:
- Click the Windows Start button and type Apps & features to find the installed apps. Look for the DB2 Server Edition - DB2COPY1 and uninstall it.
- Remove the following directories if they exist:
- Install_drive:\AIWINST
- %AIWDATA%\db2_logs
- Continue with Completing the upgrade process.