How to Configure MS SQL Server Database for the Central Server

1. Prerequisites for the migration process

In the Microsoft SQL Server used for migration, make sure that the following conditions are satisfied:

  • Hardware Requirements for the MSSQL Server
  • The SQL Server browser must be up and running
  • Microsoft SQL Server access must be delegated to a user with db_creator and db_owner permissions at the database level
  • For databases using the Full or Bulk-Logged recovery model, back up the transaction logs regularly to avoid data loss and prevent the transaction log from filling up. Learn more.
  • The supported SQL version of Central Server is mentioned in this system requirement page.
  • If you are using a Failover server, additional steps are required. Please check here

2. Migrate the Central Server Database to MSSQL

This section explains how to migrate the Central Server database from PostgreSQL (PGSQL) to Microsoft SQL Server (MSSQL). Follow these steps carefully to ensure a smooth migration:

  1. Stop the Central Server: Stop the Central Server service. 
    Open services.msc -> Right click on "ManageEngine UEMS - Server" -> Stop
  2. Run the Migration Script:
    • Navigate to <UEMS_CentralServer>/bin and run the changeDBServer.bat script. This launches the Database Setup Wizard.
    • Example: C:\Program Files\UEMS_CentralServer\bin\changeDBServer.bat
  3. Select SQL Server:
    • Choose SQL Server as the database type.
    • Enter the hostname where SQL Server is installed.
    • Select the appropriate instance from the list.
  4. Authentication:
    • Select either Windows Authentication or SQL Server Authentication and provide the necessary credentials.

sql database

Windows Authentication

sql database

SQL Server Authentication
  1. Test Connection:
    • Click the Test button to verify the connection. A pop-up message will confirm the connection is established.
    sql database
  2. Complete Configuration:
    • Click Save to complete the SQL Server configuration.
    • A confirmation message will indicate successful SQL Server setup and data migration.
    sql database
  3. Note: Migration duration depends on the amount of data and machine performance. Please wait until completion.
  4. Additional Steps for Failover Server:
    • Stop both the Primary and Secondary Servers.
    • Copy the database_params.conf and Server.starttime files from the conf folder.
    • Move them to the corresponding location on the Secondary (failover) server.
    • Start the Primary Server first, followed by the Secondary Server.

Once migration is complete, you can begin using the Central Server with the new configuration.

To configure SQL Server Always On functionality, refer to: SQL Server Always On

Frequently Asked Questions (FAQ)

How to find the Port Number?
What should you do if there is a change in SQL server machine name/IP
What should you do if the database migration fails midway?
What if the migration is stuck at 99%?
What happens if "Enable Data Migration" is not selected?
What to do if you see "Cannot Establish a Connection"?
Can I migrate the database while the product is running?