web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Full Copy of Production Environment to Test Environment AX 2012 R3

(0) ShareShare
ReportReport
Posted on by 34

Hello, I'am recently working for a company that utilizes Dynamics AX 2012 R3, there have been a lot of changes made and there hasnt been any " Test to Production standard". Meaning both environments are different, is there a way of simply replicating/copying the whole Production Environment (data and config) to Test environment??

I'm pretty new to Dynamics AX, but i think its just a matter of creating a Production Configuration file and passing it to Test, and backing up its Database and restoring it on the Test DB. Its the same domain, just different Virtual Machines.

Any solutions?

Thanks in advance. 

*This post is locked for comments

I have the same question (0)
  • Verified answer
    André Arnaud de Calavon Profile Picture
    301,030 Super User 2025 Season 2 on at

    Hi Tom,

    This is possible. You can stop the AOS services for the test environment and then restore the business and model databases (both) in the test SQL server. With some scripts or data manipulation, you can disable or change batch processes to prevent sending mails to external parties. Also make sure that in case there are file paths setup to pickup or send files, you may need to change these as otherwise e.g. vendor invoices will be "stolen" from the production environment.

    Eventually, you can change the user credentials if the test environment is running in another domain. Once you have checked everything, you can start the AOS again.

    Note that this procedure will delete pending customizations which are not moved to production. So, you might need to apply these customizations again on the test and start over testing.

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    In addition to Andre's message - if you use modelstore delivery from test/staging to prod, you can copy just the prod business database back to staging.But if you have not used modelstore delivery, you need to copy both databases (business db and model db) since there are object id values in the databases that must be in sync.

    Also, there might be a lot of entries in different tables, that you need to change during the db copy process. Otherwise your test system might start communicating with prod integrations. You should update these tables in SQL Server Management Studio after importing the db to test, before starting test AOS. The below list is not comprehensive.

    - SysClientSession

    - SysServerSession

    - SRSSConfig

    - AIFChannel

    - Batch (it makes sense to set all "Executing" batches to "Waiting", or all batches to "Withhold"

    - BatchJob (see above)

    - SysServerConfig (remove all records, insert test AOS names)

    - BatchServerGroup

    - BIConfiguration

    - EPWebSiteParameters

    - Any custom tables/fields that point to prod integration directories or third party web services

    In general you should maintain a T-SQL script for updating all this info, so that you can enhance the script when you find some things that you missed the last time.

  • Tom Corr Profile Picture
    34 on at

    Thank you André, I will have all of this in mind when applying the migration.

    Would i have to do the same procedure if in the future all i wanted to do is copy the security configuration from one environment to another?? (e.g Roles, Duties, priviliges)

    Regards

  • Tom Corr Profile Picture
    34 on at

    Thanks Nikolaos, i'll be very aware of these factors whilst manipulating the DB.

  • Roger M. Profile Picture
    302 on at

    Hi,

    I follow your steps and I had new test environment (I need it to check something apart of my current TEST env.). What I realized is Ledgercalendar is not available. I tried to import from PRODUCTION environtment and more errors about missing objects found. So, I wonder if after this process I need to compile the aplication? I guess we always restore business and model. Baseline is always untouchable. yes?

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    You should not need to compile anything if you copied the whole model database.

    What do you mean by "Ledger calendar not available" and "tried to import from PRODUCTION environment"?

    Baseline database has no impact here.

  • Roger M. Profile Picture
    302 on at

    When I tried to run this form it was empty. I checked AOT in forms and this particular form was missing.

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    Then something has gone / done wrong in the db copy. The model database contains all AOT objects. So you will have exactly the same objects in test than what you have in prod.

    You can't fix it by attempting to copy single missing objects.

    Start over by copying model and business database from prod to test. If you still have this issue please share exact steps that you did with us.

  • Roger M. Profile Picture
    302 on at

    Is there a particular way to make backup and copy. I did it from SQL Visual Studio. I stopped AOS. I made backup. I delete both Model and business and I restore from Files.

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    Yes, you can use SQL Server Management Studio (not Visual Studio).

    Make sure you take a Full backup.

    In the Test database, no need to delete anything instead Restore on top of existing databases (this should not make any difference, though).

    Also please make sure both environments have the same Kernel version.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans