Skip to main content

OPNBI Server Migration for Windows

This contains set of instructions to migrate whole OPNBI from one server machine to some others server machine with all data.

Use case: Server migration is required case when OPNBI is running on one server machine and client wants to shift OPNBI to some other server machine or client wants to create one development server on some other server machine with all existing data of the existing server. So here are the steps to migrate OPNBI from one server to another server with whole data.

Prerequisites: in order to get started, there are some prerequisites we have to take care of as below,

Same Database should be installed at the server in which we are moving OPNBI. If OPNBI is installed with MySQL or PostgreSQL in existing server, same database with same credential should be installed.

Database schema should be same as in current server

There should be enough space on Server at the same location OPNBI in installed currently. It is best practice to move OPNBI on the same location as in current Server.

  1. Take backup of database [MySQL or PostgreSQL] where OPNBI is installed.

CLICK ON BELOW LINK TO FIND STEPS HOW TO PERFORM BACKUP AND RESTORE WITH MYSQL AND POSTGRESQL [PROVIDE WIKI LINK HERE]

  1. Move this dump file to new server and restore this script file into same schema which is created as per prerequisites.
  2. Once database is restored at the new server, copy whole OPNBI folder to new server but on the same location. For example, if OPNBI is working in C drive, then it should be pasted on the same location e.g C driver in new server.
  3. Once OPNBI folder is copied to new server on the same location, open config.json file located in your_location>OPNBI>repository>config folder with text editor
  4. In config.json file Search for “security” property and change "checked": true to "checked": false in case if external security is enabled. If "checked": false, no need to change it keep It false. The reason behind it is if external security is enabled and we are starting OPNBI, it will start fetching all users but as we have migrated to new server machine, the existing license file will not work. So we will enable this after license is updated.
  5. Now port number used in OPNBI login URL is used by current server, so we need to change the server port number for OPNBI copied in to new server. To do that open server.xml file in any test editor and find the line where existing port number is defined. For example [
    ]
  6. Change port number which is not occupied anywhere else in this property (port="port_number") and save it.
  7. Now start OPNBI by running startup.bat file from tomcat > bin folder and wait till it get start
  8. Once server is started, open OPNBI in browser by entering URL [with defined port number] and logged in with user having admin credentials, you will see a license request page on the screen [if license page does not appear automatically then go to administration section and open license page]
  9. Request for license from this page and update license as soon as you received new license
  10. Once the license is updated, you can enable security property to "checked": true (file path is mentioned in step 5) if you are using SSO. Leave this step if you are not using SSO.
  11. Make the above changes, save it and restart the tomcat server and refresh external security from OPNBI_Configuration settings from the admin section of OPNBI.

NOTE: This will work if OPNBI is copied on the same location and with the same credential of DB. If your destination location is different, user need to perform certain changes in order to make it work. Please refer below steps and apply changes accordingly.

Check the data source, schema[database], username & password from context.xml (Find context.xml in your files, path: tomcat - 8080\webapps\OPNBI\META-INF) Check the username and password of your data source, if needed change it. Check data source name from resource and change it as required.

Example:

• Username: The username of the database. • Password: The password of database. • Bhaumik: Schema[database] name.

Change path in files as follows: Path of logs, repository and other settings needs to be updated as we are migrating OPNBI in different location. Check existing path in below files and update new path in mentioned location.

Change new path in all the “. PROPERTIES files” Location: OPNBI\apache-tomcat-8.5.61\webapps\OPNBI\WEB-INF\classes

Docusaurus Slash Introduction

If you are facing difficulty in starting migrated server, please contact us at support@OPNBIhub.com.