Salesforce Backup Validation Overview
The purpose of this guide is to supply best practices to validate a CapStorm backup of Salesforce. This process involves of four steps to be performed in the order listed below:
- Permissions verification – Verify that the Salesforce user credentials that are used for backups have access to read all desired Salesforce objects and fields. Objects include Salesforce standard and custom objects, including managed packages. If the analysis uncovers that permissions updates are needed, these permissions gaps are rectified, then backup updates are made to copy all data that was previously inaccessible.
- CopyStorm review – Verify that the application is set up to meet the business’ backup goals. The recommended settings are highlighted in this section, however, each organization may choose to customize the configuration(s). If the analysis uncovers that configuration updates are needed, these changes may need to be tested in a Sandbox environment prior to making Production updates.
- Backup validation – Verify that all desired records are in the backup. If the analysis uncovers that there are records not present in the backup, these gaps are addressed prior to performing the final backup validation.
- Restore testing {optional} – Verify the process to recover data from the backup. This optional step follows the steps outlined in a sample runbook, and this often serves as a template for a customized recovery plan.
Permissions Verification
The Salesforce user credentials provided to CopyStorm determine what objects and fields are available for backup. The goal of this step is determine if there are any gaps in the current backup caused by inadequate Salesforce permissions, and, if there are gaps, to update (1) the Salesforce permissions and (2) the backup data set to ensure that all records are copied.
There are two primary categories of Salesforce permissions: System Level Permissions and Object/Field Permissions.
System Level Permissions impact one or more objects, and these are granted to the Salesforce user directly on the profile or via permissions set. Object / Field permissions impact individual objects and these are granted via permissions set for most standard or custom objects. If the objects are a part of a managed package or are a part of Salesforce licensed features, Salesforce feature of managed package licenses may also need to be assigned to the user in addition to granting object level access.
The following minimum permissions are recommended:
- API Enabled
- View Setup & Configuration
- View All Data
- Read Encrypted Data
- Query All Files
- Knowledge User
- Marketing User
- Content User
- Manage Unlisted Groups
- Moderate Chatter
Click on the “Main” tab in CopyStorm and click “Test Salesforce Connection.” The window should show these boxes checked:
Salesforce object and field permissions can be validated by using the CS:Medic Permissions Checker. This tool is simple to run with a single button click, and the output is a list of objects and fields that the Salesforce user can not currently access.
In this example, the Salesforce user can not access data in 12 standard fields and 2 custom fields:
If permissions gaps are found, access to the identified objects and fields can be granted directly in Salesforce. Alternatively, CopyStorm’s Permissions Set Creator tool will create a “Read All” permissions set to grant access to all objects and fields.
Managed packages and some Salesforce features will require additional permissions in addition to the access granted via the CopyStorm created permissions set.
Once permissions are updated, run the Permissions Checker again to verify that there are no objects or fields inaccessible to the Salesforce user.
If Salesforce field level permissions are updated, a backup update is necessary in order to update older records that were backed up before the field was able to be read by the Salesforce user. This is necessary because the backup process captures records incrementally, meaning that the backup will not automatically re-read records that already exist in the backup database when Salesforce permissions are updated.
For example, the Salesforce user in the objects and fields permissions example above was not able to read the data in 2 custom fields. All of the records are already in the backup database, however, the data in these 2 fields is missing. The next step is to update the backup in order to capture the data in these two fields.
There are two approaches to choose from in order to update the backup.
- A full rescan – This option is used if there are many fields that the backup user was unable to see prior to updating permissions or when working with a smaller number of records.
- A targeted rescan – This option is used if there are few fields that the backup user was unable to see prior to updating permissions or when working with a very large number of records that would make a full rescan time prohibitive.
The full rescan will re-read all records from Salesforce in order to address field gaps caused by insufficient permissions. To perform this task, use CopyStorm to run a one-time backup using the parameters shown below in combination with targeted objects or all objects.
A Modified Since value older than the first record created ensures that CopyStorm reads all records from the Salesforce org. This setting ignores the most recent timestamp values in the existing CopyStorm database, instead querying all records.
Ensure that only “Force Updates” is checked under “Database Optimization.” This ensures that all records will be updated to include field data that was not visible historically due to the Salesforce user’s permissions.
Save this Configuration and run. Add customersuccess@capstorm.com to the Notifications distribution list if desired.
The targeted rescan uses CS:Medic to pull only the specific fields that need to be updated. Prior to using this option, have CopyStorm update the schema of the backup database using the “Schema Only Backup” option:
This step ensures that the structure of the object is updated to include the field(s) that are now visible to the Salesforce user. Once the schema has been updated, use the Refresh Columns tool in CS:Medic.
CopyStorm configuration review
This step ensure that CopyStorm is configured for a complete backup including all objects, retention of deleted records, an established rollback period for data changes, and notifications in case a backup encounters an error. Key parameters are outlined below along with CapStorm’s recommended settings.
Setting | Recommendation | Screenshot |
---|---|---|
Objects included | Create two configurations:
All additional settings below should be set |
Configuration 1:
Configuration 2: |
Deleted Record Retention | Leave “Delete Older Than” area blank. This will save deleted records indefinitely. |
|
Point-in-Time Record Snapshots | Activate feature by ticking “Active” then “Save Changes.”
This will automatically version data changes to support Reference Snapshot for more details. |
|
Notifications | Specify who should be notified if there are any exceptions.
Separate email addresses with a semicolon. Include customersuccess@capstorm.com |
Backup validation
This step validate that the backup contains all desired records by using two CS:Medic tools: CountRecords and Scan Timestamps.
- CountRecords performs a simple Count query to Salesforce and to the Database and outlines any differences.
- Scan Timestamps performs a deeper analysis, and is typically used to determine the reason for differences identified using the CountRecords tool.
Pay close to attention to any discrepancies with a difference greater than 1%. This can be indicative of a Salesforce permissions issue, for example, the User not having access to an Opportunity record type.
If the CountRecords tab is not open click “Other Tools” in the top menu bar to open the tool. Click “Invert” to include all objects then “Start Scan.” For assistance with this analysis contact customersuccess@capstorm.com.
Restore testing
Annual recovery tests are recommended for Salesforce disaster recovery preparation. An alternative is to leverage the Restore application frequent sandbox seeding, as the process for non-production environments closely mirrors a production recovery. As a starting point for recovery tests, the Restore Validation guide is available as a sample runbook. CapStorm’s Customer Success team also supports customer working sessions to help test and validate the restore process.
In the event of an emergency production recovery need, please contact CapStorm by phone and by emailing support@capstorm.com.