Maintain control of your Microsoft 365 data
Post Reply
HeineA
Lurker
Posts: 2
Liked: never
Joined: Jul 31, 2019 7:51 am
Contact:

Backup only a specific onedrive folder

Post by HeineA »

Hi,
Our Veeam currently takes backup of all company users onedrives, however, alot of private elements, like pictures, is also being backupped. Is it possible to only take backup of specific folder(s) on the users onedrives?
For example, only take backup of a folder on all onedrives called "Work" and all folders + files in the Work folder.
With this we can tell people that all private files should be located in other folders then the Work folder.

We currently use Veeam backup for Microsoft office 365 v3.
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

Hi @HeineA! Welcome to the Community

You can exclude specific OneDrive folders with PowerShell using the ExcludedOneDriveFolders parameter.
Mike Resseler
Product Manager
Posts: 8044
Liked: 1263 times
Joined: Feb 08, 2013 3:08 pm
Full Name: Mike Resseler
Location: Belgium
Contact:

Re: Backup only a specific onedrive folder

Post by Mike Resseler »

And to add to Polina's answer... In your case it might be better to work with the SelectedOneDriveFolders parameter ;-)
HeineA
Lurker
Posts: 2
Liked: never
Joined: Jul 31, 2019 7:51 am
Contact:

Re: Backup only a specific onedrive folder

Post by HeineA »

Hi Polina and Mike,
Thanks for the response. Just to clarify, with the SelectedOneDriveFolders parameter I can choose to only backup a specific folder, like a folder named "Work", on all user onedrives in the company? :-)
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

Yep, that's correct.

Note though that the selected folders will be backed up only if they're root folders. To back up any subfolders with the same name, you need to explicitly add them.

For example, there's a OneDrive with the following structure inside:
* Folder A -> Folder B -> Folder C
* Folder B

To back up all folders "B", you need to specify both "Folder B" (for the "B" root folder) and “Folder A\Folder B” - for "B" subfolder.
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

I am also having issues excluding a folder from Onedrive. Below is the response I received from support:

"It looks like the -ExcludedOneDriveFolders option in the Add-VBOJob command is somewhat misleading.
It doesn't actually exclude individual folders within a OneDrive account; it can only exclude an entire OneDrive account."

This seems to go against what I am reading in this thread.

Below is my case information.

Case # 03835058

Additional Details: A test job was created for a user that has separately a windows agent backup to onedrive. My single user, onedrive only office 365 backup job excludes the folder "veeambackup" from onedrive. There are no other folders in his onedrive, however the job takes a long time to complete for the span of days. I have a main job that has only 3 users using windows backup agent and the backup takes a week for 100 users. The week long job was stuck processing those 3 users onedrive's

Id : (removed)
Organization : (removed)
Name : test
Description :
JobBackupType : SelectedItems
SelectedItems : {Veeam.Archiver.PowerShell.Model.BackupItems.VBOBackupUser}
ExcludedItems : {}
SelectedOneDriveFolders : {}
ExcludedOneDriveFolders : {veeambackup}
Repository : BACKUP-O365
LastStatus : Failed
LastRun :
NextRun : Never
IsEnabled : True
SchedulePolicy : <Not Scheduled>
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina » 1 person likes this post

Hi Joshua,

First, the folder exclusion functionality does exactly what expected - it allows excluding folders from backup, not entire accounts. The response from support might be a misunderstanding and I'll follow up on your case with the engineers to get more details.

Thanks!
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

Joshua,

I've briefly checked your logs provided to support and it looks that one of the issues affecting your OneDrive backups speed is throttling (there're multiple 429 errors). Potentially, you could lower this risk by reducing the number of threads on the proxy.

Please continue working with support and, if you have a minute, share the results/progress in this thread.

Thanks!
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

Polina,

Thanks for following up. I think I've come upon the source of the issue by chance. I had given up and decided to delete the veeambackup folder on onedrive from sharepoint online and was receiving an error code 36. I found a folder post stating the following:

https://answers.microsoft.com/en-us/mso ... 2a0313c47a

"SharePoint has resource throttles and limits that govern the amount of data and throughput that can be managed. The List View Threshold is by default, approximately 5000 items."

The veeam agent treats onedrive like an object store and the blockstore folder alone contained 7000+ objects of multiple subfolders with 256 items each. I believe veeam office 365 is unable to enumerate the tree structure to even attempt to exclude the folder from backup. I tested the deletion by deleting 24x256=6,144 objects and was partially successful (Only 7x256=1792 was actually deleted) and failed completely with 27x256=6912 objects.

So I'm curious if veeam backup for 0365 or any other vendor in general has an issue backing up onedrive with that many objects and not just the veeambackup folder. And whether if a timeout followed by attempting to enumerate the folder recursively would help.
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

Update. After deleting most of the files while keeping most of the folder structure intact with about 200 objects remaining the job only took 2 minutes and 45 seconds as the veeambackup folder was excluded from Onedrive using ExcludedOneDriveFolders. This is as opposed to taking days backing up a onedrive with nothing else besides the excluded folder and failing. I can try excluding the veeam system account from the view instead of excluding the folder using powershell. However as per Gostev's forum digest, there are issues restoring from a veeam agent for windows onedrive backup, therefore I won't waste the effort.

Therefore I am now working under the assumption that veeam agent for windows backup to onedrive is incompatible with veeam backup for microsoft office 365. And also that the List View Threshold may effect onedrive and SharePoint backups containing more the 5000 items using veeam backup for Microsoft office 365.
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

Last Update. If you go to Library Settings under a user's onedrive on the web then you will see the following from a user that has the veeam agent for windows:

List view threshold :
638134 items (list view threshold is 5000).
The number of items in this list exceeds the list view threshold, which is 5000 items. Tasks that cause excessive server load (such as those involving all list items) are currently prohibited.
Learn about managing a large list or library and ensuring that items display quickly.
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

Hi Joshua,

Great updates, they make the situation much clearer now.
Indeed, in the past, we have seen issues caused by the List View Threshold, but those have been fixed and the fix is now included in the cumulative patch distributed via support. Did you have a chance to install it? (your current product version would be 3.0.0.473)
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

Yes, this was post fix. Updated logs have been uploaded.
lopeztaz
Novice
Posts: 9
Liked: never
Joined: May 06, 2010 7:58 pm
Full Name: Joshua Lalanne
Location: Houston, TX
Contact:

Re: Backup only a specific onedrive folder

Post by lopeztaz »

I wanted to give an update regarding throttling issues (429 errors) and List view thresholds. According to the following blog post they are related and tested the same way I had discussed earlier when using the graph api. I also included this info in my ticket.

https://camerondwyer.com/2018/01/31/mic ... rror-code/
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

In the upcoming version of VBO, it will be possible to reduce (or even eliminate completely) throttling risks by distributing the load between multiple backup accounts. If you would like to try it out, you can join the public beta testing program.
Polina
Veeam Software
Posts: 2939
Liked: 681 times
Joined: Oct 21, 2011 11:22 am
Full Name: Polina Vasileva
Contact:

Re: Backup only a specific onedrive folder

Post by Polina »

Joshua,

I've just got an update from the RnD team, that under certain conditions the List View Threshold may still occur even after installing the fix. Our engineers are working to resolve the problem, please follow the updates from your support engineer.

Thanks!
Post Reply

Who is online

Users browsing this forum: No registered users and 22 guests