Breaking news from around the world
Get the Bing + MSN extension
Now Available in Community - MBAS 2019 Presentation Videos
Catch the most popular sessions on demand and learn how Dynamics 365, Power BI, PowerApps, Microsoft Flow, and Excel are powering major transformations around the globe. | View Gallery
2019 release wave 2 Discover the latest updates to Dynamics 365Release overview guides and videos Release Plan | Early Access Availability
Ace your Dynamics 365 deployment with packaged services delivered by expert consultants. | Explore service offerings
Connect with the ISV success team on the latest roadmap, developer tool for AppSource certification, and ISV community engagements | ISV self-service portal
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Program | Finance TechTalks | Customer Engagement TechTalks | Talent TechTalks | Upcoming TechTalks
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.
Thanks in advance.
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.
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.
- 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)
- 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.
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)
Thanks Nikolaos, i'll be very aware of these factors whilst manipulating the DB.
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?
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.
When I tried to run this form it was empty. I checked AOT in forms and this particular form was missing.
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.
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.
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.
Hi, First of all thank you for your feedback. Yesterday I was overhead with this an other issues.
Yes, you right SQL Server Management :) :) :)
I checked kernel. They are the same. I found a folder in my partner desktop user (Who handled this issues in the past). That folder contains a LedgerCalendar Hotfix for Ax2012R3 (KB3146578). I applied yesterday night late. this morning the form was there. Now I have some other errors. Probably around "compuilation", .net cil compilation or cache. I am on it. I don't understand why I need to reinstall this hotfix. Thank you again. I'll back with the results.
Assuming that x++ hotfix is in Prod, it should be copied along the database to the Test.
Like I said, you should not attempt to fix it by installing new things in Test.
When you copy the model database from Prod, it contains the compiled code and CIL. No need for x++ compile, CIL generation or db sync.
So there's still something not right in the database copying process.
Yes hotfix was in prod.
I will repeat the operation. Just to be clear: I have Threee Databses in PRODUCTION. AX2012R3 (I guess is business), AX2012R3_model and AX2012R3baseline. I only need to copy the first two. Full backup. And after backup review Those tables to delete reference to PROD AOS. No compilation is required, no hotfix is required. I gonna try again. Thank you :)
Finally I reapeat de restore. I did the same but also I copied baseline. This time AX run as expected. Now I am checking configuration if I forgot any refernce to producction.
Thank you for your help. I appreciated a lot.
Business Applications communities