Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This page takes you through the steps for upgrading from EMM 1.0.1 version to EMM 1.1.0. For more information on release versions, see the Release Matrix

Table of Contents
maxLevel3
minLevel3

Configuration changes

The following are some of the changes in EMM 1.1.0 configurations compared to EMM 1.0.1 that need to be taken into consideration.

...

The mdm-config.xml, which is in the <EMM_HOME>/repository/conf/ directory, has been renamed to emm-config.xml in EMM 1.1.0 together with the following tags:

EMM 1.0.1 TagEMM 1.1.0 Tag
<ios-enroll-url><iOSEnrollURL>
<ios-profile-url><iOSProfileURL>
<ios-checkin-url><iOSCheckinURL>
<ios-server-url><iOSServerURL>
<ios-device-property-post-url><TokenURL>

The following configurations in the mdm-config.xml file, which is in the <EMM_HOME>/repository/conf/ directory, have been removed in EMM 1.1.0 and these configurations need to be configured via the iOS Settings page in the EMM Console.

...

This page takes you through the steps for upgrading from EMM 1.0.1 version to EMM 1.1.0. For more information on release versions, see the Release Matrix

Table of Contents
maxLevel3
minLevel3

Configuration changes

The following are some of the changes in EMM 1.1.0 configurations compared to EMM 1.0.1 that need to be taken into consideration.

  • The mdm-config.xml, which is in the <EMM_HOME>/repository/conf/ directory, has been renamed to emm-config.xml in EMM 1.1.0 together with the following tags:

    EMM 1.0.1 TagEMM 1.1.0 Tag
    <ios-enroll-url><iOSEnrollURL>
    <ios-profile-url><iOSProfileURL>
    <ios-checkin-url><iOSCheckinURL>
    <ios-server-url><iOSServerURL>
    <ios-device-property-post-url><TokenURL>
  • The following configurations in the mdm-config.xml file, which is in the <EMM_HOME>/repository/conf/ directory, have been removed in EMM 1.1.0 and these configurations need to be configured via the iOS Settings page in the EMM Console.

    Code Block
    <!-- iOS APNS configurations -->
    <ios-apns-cert-path>[APNS-CERTIFICATE-PATH]</ios-mdm-apns-cert-path>
                  
    <ios-mdm-apns-cert-password>[MDM-APNS-PASSWORD]</ios-mdm-apns-cert-password>
                  
    <ios-mdm-apns-production-mode>true</ios-mdm-apns-production-mode>
       
    <!-- iOS MDM APNS         <!-- iOS mdm topic id -->
                  configurations -->
    <ios-mdm-apns-topiccert-id>path>[MDM-APNS-TOPICCERTIFICATE-IDPATH]</ios-mdm-apns-topic-id>

Preparing to upgrade

The following are the specific prerequisites you must complete before you upgrade from EMM 1.0.1 to EMM 1.1.0:

  • Before you upgrade to the latest version of WSO2 EMM, you create a staging database, which is essentially an empty database.

  • Stop all the Carbon servers connected to the database.

    Note

    Note that the upgrade should be done during a period when there is low traffic on the system.

Downtime

The downtime is limited to the time taken for switching databases when the staging database is promoted to the actual production status.

Upgrading the configurations

To migrate the configurations to the staging database:

...

Copy the data from the old database (EMM 1.0.1) to the staging database you created. This becomes the new database for your new version of WSO2 EMM.

...

...

  • cert-path>
    <ios-mdm-apns-cert-password>[MDM-APNS-PASSWORD]</ios-mdm-apns-cert-password>
    <ios-mdm-apns-production-mode>true</ios-mdm-apns-production-mode>
     
    <!-- iOS mdm topic id -->
    <ios-mdm-topic-id>[MDM-TOPIC-ID]</ios-mdm-topic-id>
  • The following configuration that was in the <EMM-1.0.1_HOME>\repository\deployment\server\jaggeryapps\mdm\config\config.json file has been added to the 
    <EMM-1.1.0_HOME>/repository/conf/emm-config.xml file using the <DeviceMonitorFrequency> tag.

     "monitor_interval" : "$(monitoring_frequency)"
     

Preparing to upgrade

The following are the specific prerequisites you must complete before you upgrade from EMM 1.0.1 to EMM 1.1.0:

  • Before you upgrade to the latest version of WSO2 EMM, you create a staging database, which is essentially an empty database.

  • Stop all the Carbon servers connected to the database.

    Note

    Note that the upgrade should be done during a period when there is low traffic on the system.

Downtime

The downtime is limited to the time taken for switching databases when the staging database is promoted to the actual production status.

Upgrading the configurations

To migrate the configurations to the staging database:

  1. Copy the data from the old database (EMM 1.0.1) to the staging database you created. This becomes the new database for your new version of WSO2 EMM.

  2. Download EMM 1.1.0 and connect it to your staging database.
  3. Configure the following files for the new production server. 
    • Go to the <EMM_HOME>/repository/conf/datasources/ directory
    , as follows:
    Code Block
    <iOSEnrollURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/scep</iOSEnrollURL>
    <iOSProfileURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/profile</iOSProfileURL>
    <iOSCheckinURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/checkin</iOSCheckinURL>
    <iOSServerURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/server</iOSServerURL>
    <TokenURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/api/devices/iostokenregister</TokenURL> 
  4. Perform any configurations required for the server (e.g., external user stores, clustering, caching, mounting etc.). 

    Note

    Note that configurations should not be copied directly between servers. 

  5. Start the server.

Going into production

When going into production, it is not recommended to use the H2 database. The following are instructions on how to configure MySQL databases:

...

Log in to the MySQL client as the root user
mysql -u root -p

You will be prompted to enter the password. In most systems, the default root password is blank. Press Enter without typing anything, if you have not changed the default root password.

...

Create the WSO2_EMM_DB as follows:

  1. In the MySQL prompt, create the database.
    create database WSO2_EMM_DB;

  2. Give authorization for the database to the admin user as follows. Thereafter, exit the MySQL Console.
    GRANT ALL ON WSO2_EMM_DB.* TO admin@localhost IDENTIFIED BY "<MYSQL ADMIN PASSWORD>";

  3. Run the MySQL scripts as follows:
    mysql -u admin -p -DWSO2_EMM_DB < <PRODUCT_HOME>/dbscripts/emm/mysql.sql;

  4. Download the MySQL connector for Java, from http://dev.mysql.com/downloads/connector/j/ and copy the JAR file downloaded to the <PRODUCT_HOME>/repository/components/lib/ directory.

  5. Update the following configuration (i.e., username, password, and more) in the master-datasources.xml file, which is in the <PRODUCT_HOME>/repository/confg/datasources/ directory.

    Code Block
    <datasource>
           <name>WSO2_EMM_DB</name>
                <description>The datasource used for EMM</description>
                <jndiConfig>
                    <name>jdbc/WSO2EMMDB</name>
                </jndiConfig>
          <definition type="RDBMS">
               <configuration>
                    <url>jdbc:mysql://localhost:3306/WSO2EMM_DB</url>
                    <username>[MySQL username]</username>
                    <password>[MySQL password]</password>
                    <driverClassName>com.mysql.jdbc.Driver</driverClassName>
                    <maxActive>50</maxActive>
                    <maxWait>60000</maxWait>
                    <testOnBorrow>true</testOnBorrow>
                    <validationQuery>SELECT 1</validationQuery>
                    <validationInterval>30000</validationInterval>
               </configuration>
          </definition>
    </datasource>

...

  1. Run the attached mysql_migration.sql script in to the EMM MySQL DB.
  2. Navigate to the <EMM_HOME>/repository/deployment/server/jaggeryapps/publisher/upload/ directory in the WSO2 EMM 1.0.1 pack and copy the content in that folder to the same location in the WSO2 EMM 1.1.0 pack.
  3. Update the EMM server domain and port in the following emm-config.xml file, which is in the <EMM_HOME>/repository/conf/ directory, as follows:

    Code Block
    <iOSEnrollURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/scep</iOSEnrollURL>
    <iOSProfileURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/profile</iOSProfileURL>
    <iOSCheckinURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/checkin</iOSCheckinURL>
    <iOSServerURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/server</iOSServerURL>
    <TokenURL>[EMM-SERVER-DOMAIN]:[PORT]/emm/api/devices/iostokenregister</TokenURL> 
  4. Perform any configurations required for the server (e.g., external user stores, clustering, caching, mounting etc.). 

    Note

    Note that configurations should not be copied directly between servers. 

  5. Start the server.

How to migrate from H2 to MySQL

When going into production, it is not recommended to use the H2 database. The following are instructions on how to migrate from H2 databases MySQL databases:

  1. Install MySQL.
    sudo apt-get install mysql-server mysql-client
  2. Set the MySQL root password.
  3. Start the MySQL service.
    sudo /etc/init.d/mysql start
  4. Log in to the MySQL client as the root user
    mysql -u root -p

    You will be prompted to enter the password. In most systems, the default root password is blank. Press Enter without typing anything, if you have not changed the default root password.

  5. Create the WSO2_EMM_DB as follows:

    1. In the MySQL prompt, create the database.
      create database WSO2_CARBONEMM_DB;

    2. Give authorization for the database to the admin user as follows. Thereafter, exit the MySQL Console.

      InfoAs the user named admin was created in step 5, we do not need to create a user again in this step

      Console.
      GRANT ALL ON WSO2_CARBONEMM_DB.* TO admin@localhost IDENTIFIED BY "<MYSQL ADMIN PASSWORD>";

    3. Run the MySQL scripts as follows:
      mysql -u admin -p -DWSO2_CARBON_DB < <PRODUCT_HOME>/dbscripts/mysql.sql;DWSO2_EMM_DB < <PRODUCT_HOME>/dbscripts/emm/mysql.sql;

    4. Download the MySQL connector for Java, from http://dev.mysql.com/downloads/connector/j/ and copy the JAR file downloaded to the <PRODUCT_HOME>/repository/components/lib/ directory.

    5. Update the following configuration (i.e., username, password, and more) in the the master-datasources.xml file, which is in the <PRODUCT_HOME>/repository/confg/datasources/ directory directory.

      Code Block
      <datasource>
             <name>WSO2_CARBONEMM_DB</name>
                  <description>The datasource used for registry and user manager</description>
       EMM</description>
                  <jndiConfig>
           <jndiConfig>           <name>jdbc/WSO2CarbonDB<WSO2EMMDB</name>
                  </jndiConfig>
            <definition type="RDBMS">
                 <configuration>
                      <url>jdbc:mysql://localhost:3306/WSO2_CARBONWSO2EMM_DB</url>
                      <username>[MySQL username]</username>
                      <password>[MySQL password]</password>
                      <driverClassName>com.mysql.jdbc.Driver</driverClassName>
                      <maxActive>50</maxActive>
                      <maxWait>60000</maxWait>
                      <testOnBorrow>true</testOnBorrow>
                      <validationQuery>SELECT 1</validationQuery>
                      <validationInterval>30000</validationInterval>
                 </configuration>
            </definition>
      </datasource>
  6. Create the WSO2_IDENTITYCARBON_DB as follows:

    1. In the MySQL prompt, create the database.
      create database WSO2_IDENTITYCARBON_DB;

    2. Give authorization for the database to the admin user as follows. Thereafter, exit the MySQL Console.

      Info

      As the user named admin was created in step 5, we do not need to create a user again in this step.

      GRANT ALL ON ON WSO2_IDENTITYCARBON_DB.* TO admin@localhost;

    3. Run the MySQL scripts as follows:
      mysql -u admin -p -DWSO2_IDENTITYCARBON_DB < < <PRODUCT_HOME>/dbscripts/identity/mysql.sql;

    4. Update the following configuration (i.e., username, password, and more) in the master-datasources.xml file, which is in the  the <PRODUCT_HOME>/repository/confg/datasources/ directory.

      Code Block
      <datasource>
           <name>WSO2_IDENTITYCARBON_DB</name>
            <description>The datasource used for registry and identityuser configurations<manager</description>
            <jndiConfig>
                <name>jdbc/WSO2IdentityDB<WSO2CarbonDB</name>
            </jndiConfig>
            <definition type="RDBMS">
                 <configuration>
                      <url>jdbc:mysql://localhost:3306/WSO2_IDENTITYCARBON_DB</url>
                      <username>[MySQL username]</username>
                      <password>[MySQL password]</password>
                      <driverClassName>com.mysql.jdbc.Driver</driverClassName>
                      <maxActive>50</maxActive>
                      <maxWait>60000</maxWait>
                      <testOnBorrow>true</testOnBorrow>
                      <validationQuery>SELECT 1</validationQuery>
                      <validationInterval>30000</validationInterval>
                 </configuration>
            </definition>
      </datasource>
  7. Create the WSO2AM_DB as follows:

    1. In the MySQL prompt, create the database.
      create database WSO2AM_DB;

    2. Give authorization for the database to the admin user as follows. Thereafter, exit the MySQL Console.

      Info

      As the user named admin was created in step 5, we do not need to create a user again in this step.

      GRANT ALL ON WSO2AM_DB.* TO admin@localhost;

    3. Run the MySQL scripts as follows:
      mysql -u admin -p -DWSO2AM_DB < <PRODUCT_HOME>/dbscripts/apimgt/mysql.sql;

    4. Update the following configuration (i.e., username, password, and more) in the master-datasources.xml file, which is in the  <PRODUCT_HOME>/repository/confg/datasources/ directory.

      Code Block
      <datasource>
           <name>WSO2AM_DB</name>
            <description>The datasource used for API manager database</description>
            <jndiConfig>
                <name>jdbc/WSO2AM_DB</name>
            </jndiConfig>
            <definition type="RDBMS">
                 <configuration>
      				<defaultAutoCommit>false</defaultAutoCommit>
                      <url>jdbc:mysql://localhost:3306/WSO2AM_DB</url>
                      <username>[MySQL username]</username>
                      <password>[MySQL password]</password>
                      <driverClassName>com.mysql.jdbc.Driver</driverClassName>
                      <maxActive>50</maxActive>
                      <maxWait>60000</maxWait>
                      <testOnBorrow>true</testOnBorrow>
                      <validationQuery>SELECT 1</validationQuery>
                      <validationInterval>30000</validationInterval>
                 </configuration>
            </definition>
      </datasource>

Going into production

Create tenants and test WSO2 EMM throughly. Once the tests are run successfully, it is safe to consider that the upgrade is ready for production. However, it is advised to test any features that are being used in production.