Backing Up the Microsoft Dynamics CRM System
To recover from any scenario, you must back up all needed information and store a copy off site. A backup plan should be created and rehearsed for all Microsoft Dynamics CRM components and services to make sure that, if a disk or other failure occurs, the maximum amount of data is recoverable.
In This Topic
Backup requirements summary
Selecting a backup type
Backing up Windows Server
Backing up Active Directory
Backing up SQL Server, including Reporting Services
Backing up Microsoft Dynamics CRM Server 2011
Exporting and importing customizations and solutions
Backup requirements summary
Backup requirements vary according to the servers involved. The following table is a summary of what to back up for Microsoft Dynamics CRM.
| Server | What to back up for Microsoft Dynamics CRM | Comments |
|---|---|---|
Domain controller |
Full System State |
None. |
Exchange Server |
Backup not required by Microsoft Dynamics CRM. |
Backup may be required for Exchange Server. |
SQL Server |
MSCRM_CONFIG OrganizationName_MSCRM master msdb ReportServer ReportServertempdb |
The OrganizationName_MSCRM and ReportServer databases should have full database backups and transaction log backups. For databases that are rarely updated, such as msdb, you may select only full database backup. Backups of the master and msdb databases are not required by Microsoft Dynamics CRM but should be part of an overall backup strategy. |
SharePoint |
Backup recommended if SharePoint integration is enabled. |
If you have enabled SharePoint integration, we recommend that you back up the SharePoint databases. For more information, see the SharePoint documentation. |
Microsoft Dynamics CRM Server 2011 |
web.config (Default location: c:\Program Files\Microsoft Dynamics CRM\CRMWeb) Windows registry: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSCRM |
The web.config file is required only if the file has been changed from the default settings. Windows registry subkey. |
Selecting a backup type
Windows Server 2008 supports external and internal hard disks, optical media drives, and removable media drives. To perform a scheduled backup, as a best practice, use an external hard disk that supports either USB 2.0 or IEEE 1394.
In Windows Server 2008, you can perform three types of backup:
System state backup, which includes all the files that are required to recover Active Directory.
Critical-volumes backup, which includes all the volumes that contain system state files.
Full server backup, which includes all volumes on the server.
Backing up Windows Server
Windows Server has a backup tool that lets you back up important company data to disk or removable media. The scheduling capability found in the Backup and Restore Wizard provides data backup for the server itself and workstations in the small business network. The data backed up includes security information, file and share permissions, and registry data. For data security, only a member of the Administrators or Backup Operators group can perform a backup. Individual files and directories on the server can be restored by using the Backup and Restore Wizard.
Backing up Active Directory
The Backup and Restore Wizard can back up System State data, which includes Active Directory, system startup files, the Component Services Class Registration database, the registry, and SysVol. Possible backup locations for System State data include floppy disks, hard disks, removable media, recordable compact discs, and tapes.
Although we recommend that you back up Active Directory, the only way to avoid data loss is to have multiple Active Directory domain controllers. Then, if a domain controller fails, the other domain controllers will have a complete copy of the directory. With a backup, you have data only as recent as your last backup.
Active Directory is a transacted database system that uses log files that support roll-back semantics to make sure that transactions are committed to the database. The files associated with Active Directory are as follows:
Ntds.dit. The database.
Edbxxxxx.log. Transaction logs.
Edb.chk. Checkpoint file.
Res1.log and Res2.log. Reserved log files.
Ntds.dit grows as the database fills up. However, the logs are of fixed size (10 MB). Any change made to the database is also appended to the current log file, and its disk image is always kept up to date.
Edb.log is the current log file. When a change is made to the database, it is written to the Edb.log file. When the Edb.log file is full of transactions, it is renamed to Edbxxxxx.log. (It starts at 00001 and continues to increment by using hexadecimal notation.) Because Active Directory uses circular logging, old log files are deleted as soon as they have been written to the database. At any point in time, you will have the Edb.log file and maybe one or more Edbxxxxx.log files.
The Edb.chk file stores the database checkpoint, which identifies the point where the database engine has to replay the logs, generally at the time of recovery or initialization.
Res1.log and Res2.log are "placeholders," designed to reserve (in this case) the last 20 MB of disk space. This gives the log files sufficient room for a graceful shutdown if all other disk space is consumed.
For more information, see:
Backup and Recovery (Windows Server 2008)
Administering Active Directory Backup and Recovery (Windows Server 2008)
Backing Up and Restoring Data for Windows Server 2003
Server Clusters: Storage Best Practices for Windows 2000 and Windows Server 2003
How to use the backup feature to back up and restore data in Windows Server 2003
Backing up SQL Server, including Reporting Services
The Backup and Restore Wizard in Windows Server 2008 uses Volume Shadow Copy Services (VSS) to back up Microsoft SQL Server databases. An alternative solution that can be used while SQL Server runs is the built-in backup. Use SQL Server Management Studio to create a backup of the SQL Server databases. Then, you can run a backup job from the Backup and Restore Wizard to include database backups that Reporting Services created. You would schedule the backup routing in Reporting Services to run first, followed by a backup job run in the Backup and Restore Wizard. For more information about SQL Server backups, see SQL Server Books Online.
Microsoft Dynamics CRM creates at least two Microsoft Dynamics CRM-specific databases on SQL Server. In addition, Microsoft Dynamics CRM requires the default master and msdb SQL Server databases for database services and the default report server SQL Server databases for Reporting Services. The databases that make up a Microsoft Dynamics CRM system on SQL Server are as follows:
OrganizationName_MSCRM
MSCRM_CONFIG
ReportServer
ReportServertempdb
master
msdb
Note
Your Microsoft Dynamics CRM deployment may include more than one OrganizationName_MSCRM database.
The SQL Server backup plan should address each of these databases to make sure that Microsoft Dynamics CRM could recover if one, or all, databases fail. If your organization already has SQL Server or another database application, your database administrator may have a database backup strategy. However, if this is the first database application in your organization, you can create and maintain scheduled jobs to perform the necessary backups by using the Maintenance Plan Wizard in SQL Server Management Studio. To start the Maintenance Plan Wizard, in Reporting Services, expand the server, expand the Management folder, right-click the Maintenance Plans folder, and then click Maintenance Plan Wizard.
Your backup plan for the Microsoft Dynamics CRM databases provides you a backup set that includes a full database backup and some number of transaction log backups, depending on the Microsoft Dynamics CRM installation and the frequency with which you determine whether you must have backups. For more information about backup and restore strategies, see SQL Server Books Online.
For databases that are updated infrequently, such as the msdb database, you might perform only full database backups. The OrganizationName_MSCRM, MSCRM_CONFIG, and ReportServer databases should have both full database and transaction-log backups.
Databases on which transaction log backups will be performed must have the Full recovery model database property set. You can set this property through SQL Server Management Studio. For more information about how to set database properties, see SQL Server Books Online.
Schedule full database backups frequently enough to reduce the number of restores after a failure. For example, if one day's data loss is acceptable, you can back up the transaction log one time per day, and back up the database one time per week. If only one hour's maximum data loss is acceptable, you can back up the transaction log one time per hour. To reduce the number of restores, back up the database one time per day.
To create a database maintenance plan for scheduled backups, run the Maintenance Plan Wizard from SQL Server Management Studio. Select the option to back up the database as part of the maintenance plan for a full database backup. Select the option to back up the transaction log as part of the maintenance plan for a transaction log backup.
Your computer that is running SQL Server should also be designed with a level of fault-tolerance that is correct for a database server. This includes a RAID-5 disk array for your databases and a RAID-1 (mirror) for your transaction logs. With the correct level of hardware fault-tolerance, restoring from backup should be a very uncommon occurrence.
For information about the other options available in these maintenance plans, such as where to store the backups, see the Maintenance Plan Wizard topics in SQL Server Books Online.
For more information about how to back up and restore SQL Server databases, see:
Backing Up and Restoring Databases in the SQL Server
Optimizing Backup and Restore Performance in SQL Server
Backing up Microsoft Dynamics CRM Server 2011
Backing up and restoring the Microsoft Dynamics CRM Server 2011 basically involves the following data:
Microsoft Dynamics CRM Server 2011 database files (explained previously)
Microsoft Dynamics CRM Server 2011 program files
Microsoft Dynamics CRM website files
Important
- For information about how to back up solutions and customizations that have been implemented outside of the Microsoft Dynamics CRM application, contact your solution vendor.
- We recommend that you keep a record of your current Microsoft Dynamics CRM update rollup level. Therefore, if failure recovery is required, the appropriate Microsoft Update can be reapplied.
By default, all Microsoft Dynamics CRM program files are located in the following folder:
C:\Program Files\Microsoft CRM\
By default, the Microsoft Dynamics CRM website files are located in the following folder:
C:\Program Files\Microsoft CRM\CRMWeb
Exporting and importing customizations and solutions
The Solutions feature can be used to export all unmanaged solution customizations such as modified forms, views, and mappings. Later, the solution customization can be imported to the same organization or a different organization. For example, you can export a solution from an on-premises deployment of Microsoft Dynamics CRM 2011 and then import it into a Microsoft Dynamics CRM Online organization.
The Solutions feature is located in the Customizations area of the Settings area in the Microsoft Dynamics CRM web application navigation pane. It is a good practice to export your customizations before you make changes so that they may be imported back if there is unexpected behavior. For more information, see Transportable customizations and How to Import or Export a Solution.
See Also
Concepts
Operating Microsoft Dynamics CRM
Failure Recovery