2018-03-06

Copy database from a OneBox environment to another OneBox Environment

Categories: tech

This document is a check-list I have compiled on moving a database from one OneBox environment to another. Microsoft does not have a document for this scenario so I have compiled information from multiple blog posts.

  1. Create a Backup copy of the Source database

  2. Move the Database to the destination environment and restore it there

  3. Stop the AX Services

  • World wide web publishing service (on all AOS computers)
  • Microsoft Dynamics 365 for Finance and Operations Batch Management Service (on non-private AOS computers only)
  • Management Reporter 2012 Process Service (on business intelligence [BI] computers only)
4. Rename the OLD database to AxDB_ORIG_TodaysDate and rename the newly restored database to AxDB.
  1. Start the services that was stopped in Step 3 above

  2. Sync the Database using either Visual Studio or this command from an elevated command prompt:

K:<br />
cd K:\AosService\WebRoot\bi<br />
Microsoft.Dynamics.AX.Deployment.Setup.exe -bindir "K:\AosService\PackagesLocalDirectory" -metadatadir K:\AosService\PackagesLocalDirectory -sqluser axdbadmin –sqlserver localhost -sqldatabase AxDB -setupmode sync -syncmode fullall -isazuresql false -sqlpwd <sql password> >log.txt 2>&1

Note: K is the Service Volume

Verify that there are no errors in log.txt

  1. I the environment is running Retail you will need to run the Retail Reprovisioning tool in this document.

  2. Reset the Financial Reporting Database according to this document.

Links https://docs.microsoft.com/en-us/dynamics365/unified-operations/dev-itpro/analytics/reset-financial-reporting-datamart-after-restore http://blog.johanpersson.nu/?p=2684