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)

Refresh STAGE with PROD Data

(0) ShareShare
ReportReport
Posted on by 333

Hi Guys,

I need to refresh our STAGE with PROD data so we can debug and fix issues that pop up in PROD.

I am aware of the procedure for recreating the staging environment from the production environment as described in the Deploying CUSTOMIZATIONS ACROSS MICROSOFT DYNAMICS ENVIRONMENTS guide.  But i am confused where the SQL DB backup and restore comes into play?  I have SQL scripts from our outside vendor to run  that will refresh data on our environments. When can that be completed? Can it be done before or after the model export and upload?

Here are the steps i am going to take but do not know where the SQL DB restore should be placed.

  1. Drain users, reject new clients - STAGE
  2. close active sessions - STAGE
  3. stop all aos instances - STAGE
  4. Export model to backup model - STAGE
  5. Export Model Store - PROD
  6. Import model store - STAGE
  7. Import backup model - STAGE
  8. Start AOS - STAGE
  9. compile - STAGE
  10. Synchronize DB - STAGE
  11. set AOS to accept new clients - STAGE

*This post is locked for comments

I have the same question (0)
  • ScorpioDax Profile Picture
    333 on at

    HI Crispin


    For step 7 i agree but it does show that here in the guide.

    2018_2D00_03_2D00_09_5F00_12_2D00_13_2D00_31.jpg

    for step 11 i have a SQL script that will extract all the settings from PROD and then i will restore the DB and run against the restored DB. 

  • Suggested answer
    Rachit Profile Picture
    4,015 User Group Leader on at

    Do you want to restore data or data + code from PROD to Stage?

    Some conceptual information --> If you do only model store import then you are basically only restoring code from PROD.

    If you restore SQL DB Backup then it contains Code+ data. Depending on your AX2012 version, your code and modelstore can reside in same or different databases. Assuming you are working on AX2012 FP version then the code and modelstore reside in same database.  From AX2012 R2 and above MS splitted these databases. 

    What you want to achieve should decide the strategy.

    Restore only DATA from prod --> Summary of steps will be to  take backup of your Staging code in form of model store, restore PROD DB and then import your model store backup. This way your data is restored from PROD and Staging code is also preserved. 

    Restore DATA + CODE --> In this case you can do a full SQL DB restore from PROD to Staging. 

    You will need to run other scripts to update your system configuration/SSRS /EP etc settings to Staging. 

    Hope this helps

  • ScorpioDax Profile Picture
    333 on at

    Hi Rachit,

    I would like to restore the DATA + CODE , i have some SQL scripts that i can use to extract all the settings from STAGE.  We have AX 2012 RTM

  • ScorpioDax Profile Picture
    333 on at

    When you say delete critial parameters do you mean run the SQL scripts to populate the settings?

  • ScorpioDax Profile Picture
    333 on at

    Got it.  

    Are there any steps i will need to be aware of when backing up and restoring the DBs?  I am creating a list for our DBA to follow.  That would be awesome.

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