Export a copy of the standard user acceptance testing (UAT) database
https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/database/dbmovement-scenario-exportuat
Import the database:
- Keep a copy of the existing AxDB database, so that you can revert to it later if you must.
- Import the new database under a new name, such as AxDB_fromProd.
Open a Command Prompt window, and run the following commands from the sqlpackage .NET Core folder.
Download sqlpackage .NET Core for Windows from Get sqlpackage .NET Core for Windows.
SqlPackage.exe /a:import /sf:D:\Exportedbacpac\my.bacpac /tsn:localhost /tdn:<target database name> /p:CommandTimeout=1200
Update the database
Turn on change tracking
Start to use the new database
To switch environments and use the new database, first stop the following services:
- World Wide Web Publishing Service
- Microsoft Dynamics 365 Unified Operations: Batch Management Service
- Management Reporter 2012 Process Service
After these services have been stopped, rename the AxDB database AxDB_orig, rename your newly imported database AxDB, and then restart the three services.
To switch back to the original database, reverse this process. In other words, stop the services, rename the databases, and then restart the services.
Post steps for Commerce environments
If you are using Commerce channels, when importing a database to a developer environment, which was originally exported from a self-service sandbox, the following additional steps must be performed on the destination developer environment. Without completing these steps, Commerce channels will not function.
- To restore Commerce channels functionality, apply the latest Microsoft service update or quality update, which will create the channel database.
- To restore any previously deployed channel database extensions, re-apply the corresponding Retail self-service deployable package.
Reprovision the target environment
o run the Environment re-provisioning tool on the destination environment, run the following steps:
- In your project's Asset Library, in the Software deployable packages section, select Import.
- From the list of shared assets, select the Environment Reprovisioning Tool.
- On the Environment details page for your destination environment, select Maintain > Apply updates.
- Select the Environment Reprovisioning tool that you uploaded earlier, and then select Apply to apply the package.
- Monitor the progress of the package deployment.
Comments
Post a Comment