Do the following procedures to move ScanMail database(s) from one SQL Server to another SQL Server. The first scenario above will be used to demonstrate this task.
- Stop the following services:
- ScanMail for Microsoft Exchange Remote Configuration Server
- ScanMail for Microsoft Exchange Master Service
- ScanMail for Microsoft Exchange System Watcher
- Move the ScanMail databases by using SQL Server Management Studio:
If you don’t install SQL Server Management Studio, use Transact-SQL to finish this task. Check the following Microsoft articles for detailed information on how to move a database using Detach and Attach in MSDN:
- Detach the SMEX database from the source SQL Server:
- Copy the SMEX database files from source SQL Server to target SQL Server. The folder is usually C:\Program Files\Microsoft SQL Server\MSSQL**.***\MSSQL\DATA. Make sure to copy the Primary Data file as well as the Transaction Log files:
- Attach the SMEX database to the target SQL Server:
If you don’t install SQL Server Management Studio, use Transact-SQL to finish this task. Check the following Microsoft articles for detailed information on how to move a database using Detach and Attach in MSDN:
- Go to the ScanMail server and modify the SMEX database profiles located: \%SCANMAIL_INSTALL_PATH%\config
dbcfg_DatabaseInstance.txt
dbcfg_IsSeperateSQLServer.txt
dbcfg_ConfDBName
dbcfg_LogDBName
dbcfg_ReportDBName
dbcfg_ServerName.txt
dbcfg_SQLUserId.txt
dbcfg_SQLPassword.txt
dbcfg_SecurityString.txt
Take note of the following:
- The dbcfg_DatabaseInstance.txt should be the remote SQL instance where you attached the ScanMail database(s) in the Step 2.
- The value in dbcfg_IsSeperateSQLServer.txt should be 1.
- “Dbcfg_ConfDBName”, "dbcfg_LogDBName" and "dbcfg_ReportDBName" should be the ScanMail database name, if you choose not to change the GUID (not necessary to change it).
- Dbcfg_ServerName.txt should match the ScanMail server name, if you prefer not to change the GUID (not necessary to change it).
- If you select SQL Server authentication to connect to SQL Server during ScanMail installation, make sure that the SQL account and password are stored in "dbcfg_SQLUserId.txt" and dbcfg_SQLPassword.txt" separately. To generate the encrypted password for "dbcfg_SQLPassword.txt":
- Go to the \%SCANMAIL_INSTALL_PATH%\SMEX folder via the Command prompt.
- Type toolChangeRemoteDBPWD.exe –p %SCANMAIL_INSTALL_PATH%\config\ -c Current SQL Password
- You may type toolChangeRemoteDBPWD.exe /? for usage info.
- Verify that the new dbcfg_SQLPassword.txt file generated the encrypted password.
- If you select Windows authentication to connect to SQL Server during ScanMail installation, make sure the ScanMail service account has DBO privileges on ScanMail’s databases in the new SQL Servers.
- Make sure dbcfg_SecurityString.txt uses the following string: Integrated Security=SSPI;Persist Security Info=FALSE;
- Start the following services:
- ScanMail for Microsoft Exchange Remote Configuration Server
- ScanMail for Microsoft Exchange Master Service
- ScanMail for Microsoft Exchange System Watcher
- Once the procedure above is implemented, log on to the ScanMail console and verify all the configuration. Check as well for any error on the console.