Friday, 18 May 2012

Moving CRM Organization from one environment to another

Hi Friends,

This is a step-by-step process to successfully moving your CRM Organization from one invironment to another. This also includes errors that are likely to occur:


1. Bakup your Organization_MSCRM database on old environment - In sql right click the database - Tasks - BackUp

2. Install a clean CRM on your new environment with a Temporary organisation - this will be ditched later

2. Restore the Database backed-up in step 1 on the new environment - In Sql right click the Database folder -  Restore Database - In database enter the original name of the database you backedup in step one, select from file - click ... to browse to the .bak file you got from step 1

3. Now Open Deployment Manager - on Organization folder - right click- Import. Click Yes to confirm the pop up

4. Enter the database server name of the new environment

5. Select the Database you restored (you moved from the old environment)

(Are you on the same domain or NOT)

if you are on the same domain, continue and make sure the users are mapped properly - If not the same then map them manually - BEST thing is to only map the setup administrator users only - the rest can be done later

6. Click next to create - this takes some time depending on the size of your database

 Should you get the error :

An error occurs when importing an organization in Microsoft Dynamics CRM 4.0 “ExecuteNonQuery requires an open and available Connection. The connection's current state is closed.”

Solution: follow these steps  and come back and try again from step 3.

7. The Organization has been imported.

8. Open Crm :

Should you get the error :

"ExecuteNonQuery requires the command to have a transaction when the connection assigned to the command is in a pending local transaction. The Transaction property of the command has not been initialized"

one or both of the two fixes might help:

 Go to SQL

 8.1 Setup default organization for all users by runing the two sql queries

Use MSCRM_CONFIG

SELECT Id, UniqueName FROM Organization

Copy the Guid of the organization you just imported [newOrgGuid]

Use MSCRM_CONFIG

UPDATE SystemUser
SET DefaultOrganizationId = [newOrgGuid]



__________________

try Step 8 again:

Should you get the error :

"ExecuteNonQuery requires the command to have a transaction when the connection assigned to the command is in a pending local transaction. The Transaction property of the command has not been initialized"

then Go to SQL still

Go to Security

go to NETWORK\SERVICE

GOTO UserMapping

Select the new Organization Database

Make sure NETWORK\SERVICE is the db_owner



Continue with step 8.

If issues are still found share with me!







2 comments:

  1. which error are you getting? jst a pointer with moving your crm. licence is important, make sure you restore enterprise on enterprise. not enterprise to standard.

    ReplyDelete