Tuesday, April 21, 2015

AX2012 Export and Import Model

Speak as a beginner, even Microsoft prepares many great tools however deploying(or moving) AX environment still is quite complicated. There are many ways to do for an objective. Usually I start by check or make sure what scenario I want to do exactly, and then looking for the proper steps for it.

Useful resources
Deploying customizations across Microsoft Dynamics AX 2012 environments
Models, Layers, and the Model Store [AX 2012]
Model Store Deployment Best Practices

Moving model is a good choice when we are dealing with dev or test environment. Below it shows the simple steps to move a model from an environment to another one.


Export model
     -     At source environment
     -     Stop AOS
     -     Backup databases (transactions and model)
     -     Run command-prompt as administrator and go to the path which has ManagementUtilities as following example



     -     Export model by this command
           axutil export /model:"CUS model" /file:aaa.axmodel /s:machine01\AX2012R2_DEV /db:AX2012R2_DEV_model

           model name                 -> CUS model
           result file                     -> aaa.axmodel
           server name                -> machine01
           SQL server instance     -> AX2012R2_DEV
           model db                     -> AX2012R2_DEV_model



Import model
     -     Atarget environment
     -     Stop AOS
     -       Backup databases (transactions and model)
     -       Run command-prompt as administrator and go to the path which has ManagementUtilities
     -       Delete model by this command
           axutil delete  /model:"CUS model"  /s:machine02\AX2012R2_QA  /db:AX2012R2_QA_model



     -     Start AOS
     -     Sync db
     -     Stop AOS
     -     Import model by this command
           axutil import /file:aaa.axmodel /s:machine02\AX2012R2_QA /db:AX2012R2_QA_model



-          Start AOS
-          Launch AX client




Until the next post!

No comments:

Post a Comment