Unknown macro: {next_previous_link3}
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 7 Current »

This guide takes you through the steps for upgrading product versions from BRS 2.0.0 to BRS 2.1.0. For more information on release versions, see the Release Matrix.

Preparing to upgrade

 Before starting the upgrading process, the following prerequisites must be followed on the database.

  • A separate staging database should run as the production database server. As a result, once the upgrading process is completed, the database server should have the configurations required for a production server.
  • Take backups of the database and system prior to migrating the database. The system backup can be taken by copying the Carbon server home folder.
  • Shut down all the Carbon servers connected to the database before running the migration scripts.
  • Since a separate database (staging database) is used for the migration instead of the actual production database, the data that is collected in the actual production system while the upgrading is in progress should later be added to the migrated database using a script. 
  • The database administrator should collect the data portion that is added to the production database, while the upgrading is in progress. Generally, the WSO2 support team will provide help in these types of situations.
  • If any files/folders are changing in the product pack to which you are upgrading, you need to make a backup of the relevant files/folders prior to changes.

    New product (e.g., IS 4.5.0) must not be connected to the old database (e.g., IS 4.0.0) without executing the migration script provided in the old database.

Limitations

The following are the limitations of upgrading:

  • This upgrading process can only be done for some database types. For example, if you are using MySQL currently and you need to migrate to Oracle in the new version, these scripts will not work.
  • You cannot rollback the upgrading process. It is impossible to restore a backup of the previous server and retry the upgrading progress.

Downtime

The downtime is limited to the time taken for switching databases when the migrating environment is connected to the production.

Upgrade Procedure

  1. Stop the current BRS 2.0.0 server.

  2. Select the relevant script for the upgrade from here on the production database. The script you use will depend on the type of database you are using, for instance, if your database is MySQL you need to run the execute mysql-migration.sql command in MySQL (you would use Oracle or MSSQL to run the script if that is the database you are using). Running this script will ensure that the database is upgraded with the additional tables and schemas which are required for BRS 2.1.0.

    There are three migration scripts available: migration-service-provider.sqlmigration-identity.sql and migration.sql. However, for all Carbon products except WSO2 IS, only the migration.sql script is required to be executed.

  3. Once you run the migration script on the production database, copy the data from your production database to the staging database you created when preparing to upgrade. This becomes the new database for your new version of BRS.
  4. Download WSO2 Business Rules Server 2.1.0 from http://wso2.com/products/business-rules-server/.
  5. To connect the new product version to the upgraded (staging) database, configure the following files:  
    1. Configure <PRODUCT_HOME>/repository/conf/datasources/master-datasources.xml. See here for more information on how to do this for your database.
    2. Go to the <PRODUCT _HOME>/repository/conf directory and update the datasource references in user-mgt.xml and registry.xml to match the updated configurations in the master-datasources.xml file which you made in the above step. The following are sample configurations if the datasource is jdbc/WSO2CarbonDB.

      registry.xml
      <dbConfig name="wso2registry">
          <dataSource>jdbc/WSO2CarbonDB</dataSource>
      </dbConfig>
      
      user.mgt.xml
      <UserManager>
        <Realm>
        <Configuration>
        ...
        <Property name="dataSource">jdbc/WSO2CarbonDB</Property>
        </Configuration>
        ...
        </Realm>
      </UserManager>
      api.manager.xml
      <DataSourceName>jdbc/WSO2CarbonDB</DataSourceName>

Recommended checkpoints

The databases should contain the newly added tables, which are namely as follows:

  • UM_DOMAIN

  • UM_SYSTEM_USER

  • UM_SYSTEM_ROLE

  • UM_SYSTEM_USER_ROLE

Going into production

Recommended tests

The following are the recommended tests to run on the staging system: 

  • Create multiple user stores and try adding users to different user stores.
  • Create multiple tenants and add different user stores to the different tenants. Thereafter, add users to the various user stores.
  • The staging database should be used as the new production database with the new Carbon server. The staging server should have the configurations equivalent to the production server. Map the production domain to the staging environment, once the staging environment is running smoothly. This migration should be done during a period when there is low traffic on the system.

Once the above tests are run successfully, it is safe to consider that the migration is ready for production. However, it is always advised to carryout testings on features that are being used in production.



  • No labels