LKBEN10765: How to Change the Location of the MTA Database


Symptom

How to Change the Location of the MTA Database

Cause

How to Change the Location of the MTA Database

Solution

  1. Stop the Microsoft Exchange MTA Stacks service. To do so, at the command prompt type the following command: net stop msexchangemta.
  2. Edit the following value to reflect the new location for the MTA Database Path (no change is required if you are not relocating the MTA Database Path):

    HKEY_Local_Machine\System\CurrentControlSet\Services\MSExchangeMTA\Parameters\MTA Database Path

  3. Edit the following value to reflect the new location for the MTA Run Directory (no change is required if you are not relocating the MTA Run Directory):

    HKEY_Local_Machine\System\CurrentControlSet\Services\MSExchangeMTA\Parameters\MTA Run Directory

  4. Explore the new path and make the new directory structure. You may omit the Mtacheck.out folder in the MTA Database Path because it makes this directory and runs later in this procedure.

    Important Explore the installation drive and make a backup copy of the exchsrvr\mtadata directory.
  5. Explore the original exchsrvr\mtadata directory.
  6. On the View menu, click Details, and again on the View menu, point to Arrange Icons, and then click by Type. Select and then move all of the *.dat files to the new MTA Database path. Change the security for the directory to match that of the original directory.
  7. Select all of the other files, and then move them to the new MTA Run Directory. Change the security of the directory to match that of the original directory.
  8. Delete the original exchsrvr\mtadata directory.
  9. At a command prompt, go to the exchsrvr\bin directory.
  10. Within the exchsrvr\bin directory, run mtacheck; the task should report "Database clean, no errors detected." You may have to run mtacheck again to receive this successful report message.
  11. Start the Microsoft Exchange MTA Stacks service. To do so, at the command prompt type the following command: net start msexchangemta.

Disclaimer:

The information provided in this document is intended for your information only. Lubby makes no claims to the validity of this information. Use of this information is at own risk!

About the Author

Author: Wim Peeters - Keskon GmbH & Co. KG

Wim Peeters is electronics engineer with an additional master in IT and over 30 years of experience, including time spent in support, development, consulting, training and database administration. Wim has worked with SQL Server since version 6.5. He has developed in C/C++, Java and C# on Windows and Linux. He writes knowledge base articles to solve IT problems and publishes them on the Lubby Knowledge Platform.