32.8 Migrating the Data from an External Sybase SQL Anywhere to an MS SQL Database

ZENworks 11 SP2 allows you migrate the data from an external Sybase database to an MS SQL database installed on a device that does not have the ZENworks 11 SP2 installed.

IMPORTANT:Do not perform this scenario on a device that has ZENworks Reporting Server installed.

Review the following to migrate the database:

32.8.1 Preparing to Move the Data

Before migrating the data from the Sybase database to the MS SQL database, do the following:

  • Make sure that the license state of ZENworks 11 SP2 is Active. The product must be installed and running either in the licensed version or the evaluation version.

  • Save all the reports, rights.xml, and ownership.xml by using the zman report-save (rpsv) (destination folder)command. The XML files contain rights and ownership details of all the reports.

  • Make sure that the Primary Server to which the Sybase database is configured has been upgraded to ZENworks 11 SP2.

  • Make sure that the MS SQL database is installed on a device that does not have ZENworks 11 SP2 installed.

  • (Conditional) If you want to create a new database on MS SQL Server, and migrate the Sybase data into the new database, you must be aware of the database administrator credentials.

  • (Conditional) If you want to migrate the data to an existing database that resides on the MS SQL server in your network, the newly created user must be assigned the db_owner database role and you must procure the database credentials of the newly created user from the database administrator.

  • Manually stop the ZENworks services running on all the ZENworks Servers in the Management Zone.

    • On Windows: Do the following:

      1. Execute the following command at the server prompt:

        novell-zenworks-configure -c Start

      2. Enter the number next to the Stop action.

    • On Linux: Do the following:

      1. Execute the following command at the server prompt:

        /opt/novell/zenworks/bin/novell-zenworks-configure -c Start

      2. Enter the number next to the Stop action.

  • Make sure that the Novell ZENworks Embedded Datastore service on the Primary Server is running.

    • On Windows: Do the following:

      1. From the Windows desktop Start menu, click Settings > Control Panel.

      2. Double-click Administrative Tools > Services.

      3. Ensure that the status of the Novell ZENworks Embedded Datastore service is Started.

    • On Linux: At the console prompt, enter /etc/init.d/sybase-asa status.

  • (Optional) The status of database migration is logged into the novell-zenworks-configure.log file. By default, only the messages of the type Info and Severe are logged. If you want other message types (such as Finer, Finest, and Warning) to also be logged into the file, do the following in the novell-zenworks-configure.properties file:

    1. Set the value of Logger.logLevel to the appropriate message type.

      For example, if you want messages of the type Finest to be logged:

       #Logger.logLevel   = FINEST
      
    2. Uncomment the line by removing the “#” as follows:

      Logger.logLevel   = FINEST
      

    The novell-zenworks-configure.properties file is located in %ZENWORKS_HOME%\conf\ on Windows and in /etc/opt/novell/zenworks/ on Linux.

32.8.2 Migrating the Data from the External Sybase Database to an MS SQL Database

Migrating the Data from the External Sybase Database to an MS SQL Database

  1. Make sure that all the tasks listed in Section 32.8.1, Preparing to Move the Data are completed.

  2. Run the database migration utility.

    • On the Windows Primary Server: At the command prompt, go to ZENworks_installation_path\bin\, then enter the following command:

      novell-zenworks-configure.bat -c DBMigrateConfigureAction

    • On the Linux Primary Server: At the console prompt, go to /opt/novell/zenworks/bin, then enter the following command:

      novell-zenworks-configure -c DBMigrateConfigureAction

  3. Select the target database type as sql-server.

  4. Enter the IP address or host name of the MS SQL database server.

  5. Enter the port used by the MS SQL database server.

  6. (Optional) Enter the named instance for the MS SQL Server engine.

  7. Choose to create a new database or use an existing database that resides on the MS SQL server.

    If you choose to create a new database, continue with Step 8.

    If you choose to use an existing database, skip to Step 9.

  8. (Conditional) If you choose to create a new database in Step 7, perform the following tasks:

    1. Select the authentication type (Windows or SQL Server) to be used for the database administrator user.

    2. Enter the database server administrator username.

    3. Enter the database server administrator password.

    4. (Conditional) If you choose Windows authentication in Step 8.a, enter the database administrator’s domain name.

  9. Select the authentication type (Windows or SQL Server) to be used for the database access user.

  10. Enter the database access username.

  11. Enter the database access user password.

  12. (Conditional) If you choose Windows authentication in Step 9, enter the database access user’s domain name.

  13. Enter the database name of the database that resides on the MS SQL server to which you want to migrate the data. If you choose to create a new database in Step 7, the database is created on the MS SQL server with the name that you specify in this step.

  14. (Conditional) If you choose to create a new database in Step 7, enter the complete path where you want the database to be created.

    The database migration starts.

  15. When the database migration is complete, you can verify the novell-zenworks-configure.log file to see if the migration was successful. The log file is located in %ZENWORKS_HOME%\log\ on the Windows Primary Server and in /var/opt/novell/log/zenworks/ on the Linux Primary Server.

  16. After the database is successfully migrated, continue with Section 32.8.3, Post-Migration Tasks.

Resuming the Database Migration

If the migration of the database is stopped for any reason, the ZENworks migration utility allows you to resume the migration if the dbmigration.xml file has been created. The file is located in the %ZENWOKS_HOME%\bin directory on the Windows Primary Server, and in the /opt/ novell/zenworks/bin directory on the Linux Primary Server.

  1. Run the database migration utility.

    • On the Windows Primary Server: At the command prompt, go to ZENworks_installation_path\bin\, then enter the following command:

      novell-zenworks-configure.bat -c DBMigrateConfigureAction

    • On the Linux Primary Server: At the console prompt, go to /opt/novell/zenworks/bin, then enter the following command:

      novell-zenworks-configure -c DBMigrateConfigureAction

  2. Enter the target database type as sql database server.

  3. Enter the IP address or host name of the MS SQL database server.

    You must specify the IP address or host name of the MS SQL database server used while migrating the database. For example, if you had specified the IP address of the database server while migrating the database, then you must specify the same IP address while resuming the database migration. You cannot specify the host name of the database server.

  4. (Optional) Enter the named instance of the MS SQL Server engine.

  5. Choose to use an existing database.

  6. Enter the credentials of the database user depending on the authentication mode selected.

  7. Enter the database name.

  8. Choose to resume the database migration.

    The database migration starts.

  9. After the database is successfully migrated, continue with Section 32.8.3, Post-Migration Tasks.

32.8.3 Post-Migration Tasks

If there is only one server in the Management Zone, all ZENworks services are automatically started after the data is successfully migrated to an MS SQL Server database.

If there are multiple servers in the Management Zone:

  1. On the device where you ran the migration utility, copy the following files to the appropriate directory on all the servers:

    • zdm.xml
    • dmaccounts.properties
    • dmmappings.properties

    The files are located in the %ZENWORKS_HOME%\conf\datamodel directory on Windows and in the /etc/opt/novell/zenworks/datamodel directory on Linux.

  2. Start all the ZENworks Services on all the ZENworks Servers in the Management Zone.

    • On Windows: Do the following

      1. Execute the following command at the server prompt:

        novell-zenworks-configure -c Start

      2. Enter the number next to the Start action.

    • On Linux: Do the following:

      1. Execute the following command at the server prompt:

        /opt/novell/zenworks/bin/novell-zenworks-configure -c Start

      2. Enter the number next to the Start action.

The ZENworks Server now points to the new database.

NOTE:Ensure not to delete the ZENworks Sybase database files if you want to revert to using ZENworks Sybase database at a later time.

Configuring a migrated MS SQL database on a device that has ZENworks Reporting Server installed

  1. Open the jdbc.sbo file from the following location:

    • On Windows: <zenworks_home>\share\boe\BusinessObjects Enterprise 12.0\win32_x86\dataAccess\connectionServer\jdbc

    • On Linux: /opt/novell/zenworks/share/boe/bobje/enterprise120/linux_x86/dataAccess/RDBMS/connectionServer/jdbc

  2. Locate the MS SQL Server 2008 database tag and add the following content below the JDBCDriver tag:

    • On Windows:

      <ClassPath>
      <Path[zenworks_home]\share\boe-publish\drivers\jdbc\mssql\sqljdbc.jar</Path>] 
      </ClassPath>
      
    • On Linux:

      <ClassPath>
      <Path>/opt/novell/zenworks/share/boe-publish/drivers/jdbc/mssql/sqljdbc.jar</Path> 
      </ClassPath>
      
  3. After you modify the jdbc.sbo file, restart the BusinessObjects Enterprise services.

  4. After the BusinessObjects Enterprise services have been restarted, run the following command:

    novell-zenworks-configure -c UpdateBOE

  5. Update BusinessObjects Enterprise from the <Zenworks_home>\bin folder.