add-circle-bold add-circle add-square add alarm-bell-1 alert-diamond analytics-pie-2 archive archive arrow-down-1 arrow-down-2 arrow-left-1 arrow-right-1 arrow-up-1 attachment-1 bin-paper-1 book-star button-record check-1 check-circle-1 close close-quote close cog-1 cog common-file-stack copy-paste credit-card-1 diagram-fall-down disable time-clock-midnight download-thick-bottom drawer-send envelope-letter envelope-letter expand-6 expand-6 file-code filter-1 floppy-disk flying-insect-honey folder-file-1 headphones-customer-support hierarchy-9 hyperlink-2 information-circle keyboard-arrow-down keyboard-arrow-up layout-module-1 list-bullets lock-2 lock-unlock-1 love-it messages-bubble-square move-to-top multiple-circle multiple-neutral-1 multiple-users-1 navigation-menu-horizontal navigation-menu network-browser open-quote pencil-1 pencil-write pencil-1 print-text rating-star rating-star remove-circle remove-square-1 search send-email-1 shield-warning single-neutral-actions single-neutral smiley-sad-1 smiley-unhappy smiley-indifferent smiley-smile-1_1 smiley-happy smiley-sad-1 smiley-unhappy smiley-indifferent smiley-happy smiley-thrilled social-media-twitter synchronize-arrows-1 tags-double ticket-1 ticket-1 time-clock-circle undo view-1 view-off view wench

DATASTOR backup options for the OneDrive folder


DATASTOR protection plans do not scan files located in cloud storage. To process OneDrive files and folders, a local copy must be present on the local disk. Otherwise, each OneDrive file returns a warning that access to the cloud file is denied. See an example from the log entry below.

WARNING: Cannot archive C:\Users\paula\OneDrive - my company\Microsoft Teams Chat Files\stuff to buy.xlsx - item skipped.
Unable to open the file
Reason: Access to the cloud file is denied. (395L)

To set OneDrive to keep a local copy of a folder, open OneDrive in File Explorer, right click the desired folder, or the OneDrive folder itself, and click the option 'Always keep on this device'. See image.

You must have disk space available to keep the files locally. 

Exclude OneDrive

You may not wish to back up OneDrive files if you have a copy kept both locally and in the cloud, Or, you may not have disk space available to keep a local copy. In this case, to prevent the protection plan warnings you can exclude the OneDrive folder from the backup. If you are running a Files and Folders type plan, use the plan settings to exclude the OneDrive folder. For a Computer System type plan, specify an exclusions file.

Files and Folders plan

The Files and Folders plan settings allow you to exclude the OneDrive folder. Highlight the protection plan, then click 'Plan Settings...' from the right pane. On the Folders tab of Plan Settings, click the Add button. See image.

 In the dialog box, select the exclude radio button, then browse to C:\Users\[the user]\[the OneDrive folder]. Click OK to add the exclusion. See image.

Note that the OneDrive folder path is followed by a backslash indicating a folder is specified rather than a file. Click OK to save and close the settings window.

Computer System plan

The Advanced Settings of the Computer System plan type contains an Exclusions field where a custom exclusion file may be defined to exclude the OneDrive folder from the backup. To set the plan to use a OneDrive exclusion file, follow the steps below. 

  • The OneDrive folder name is required for the exclusion file. For a personal account, the folder name is OneDrive. For an Office365 subscription, the name is in the format [OneDrive - MY LONG COMPANY NAME LLC], as defined when the Office 365 account was created. The default OneDrive folder location is under C:\Users\[your account]\. You can browse to the folder location to find the OneDrive folder name for your exclusion file. You may also review the plan log with the warning and the full path to the OneDrive folder.
  • Download the attached OneDriveExcludes.xml file.
  • Edit the OneDriveExclusions.xml file in notepad.
  • In notepad, edit the <exclude> line so the path="" entry matches the OneDrive folder name at C:\Users\[your account]. See below for an example. Use your own folder name.

<exclude name="OneDrive" path="C:\Users\*\OneDrive - DataStorageGroup\" subfolders="true" />

  • Note that the exclusion file uses a wildcard (*) so that all OneDrive folders for all users are excluded. You may define an explicit path for a single user if desired. End the path with a backslash to indicate a folder rather than a file.
  • Save the edited file and close notepad.
  • Copy OneDriveExclusions.xml into the software installation folder's Configurations subfolder. The default path is "c:\Program Files\DATASTOR\DATASTOR Shield Enterprise Protection Server\Server\Configurations" but you may have installed to a different location.
  • Highlight the protection plan and click 'Advanced Settings'. Scroll up to the Exclusions field and enter Configurations\OneDriveExcludes.xml and click OK to save and close the Advanced Settings window.