-
- Expert
- Posts: 235
- Liked: 37 times
- Joined: Aug 06, 2013 10:40 am
- Full Name: Peter Jansen
- Contact:
Trry to figure out excludeonedrivefolders syntax powershell
Hi,
I've been trying to figure out what the exact syntax is for defining a onedrive folder that needs to be excluded. I tried various definitions, none worked. How is a onedrive path seen within VBO? Browsing a backup I see an url mentioned for a directory. Is that url also to be considered as the path for that directory and can be given within excludeonedrivefolders? I suspect no as this didn't seem to work.
I really like to exclude some generic directories for backuprocessing of our onedrives and thus want to solve this by using excludeonedrivefolders. knowing how to define the folders would be more than welcome,
thanks, Peter
I've been trying to figure out what the exact syntax is for defining a onedrive folder that needs to be excluded. I tried various definitions, none worked. How is a onedrive path seen within VBO? Browsing a backup I see an url mentioned for a directory. Is that url also to be considered as the path for that directory and can be given within excludeonedrivefolders? I suspect no as this didn't seem to work.
I really like to exclude some generic directories for backuprocessing of our onedrives and thus want to solve this by using excludeonedrivefolders. knowing how to define the folders would be more than welcome,
thanks, Peter
-
- Product Manager
- Posts: 5797
- Liked: 1215 times
- Joined: Jul 15, 2013 11:09 am
- Full Name: Niels Engelen
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
You can just use folder names in it and they will be excluded.
Personal blog: https://foonet.be
GitHub: https://github.com/nielsengelen
GitHub: https://github.com/nielsengelen
-
- Veteran
- Posts: 1143
- Liked: 302 times
- Joined: Apr 27, 2020 12:46 pm
- Full Name: Natalia Lupacheva
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
Hi Peter,
In addition, if you are looking for the example, you may take a look at this thread.
Thanks!
In addition, if you are looking for the example, you may take a look at this thread.
Thanks!
-
- Expert
- Posts: 235
- Liked: 37 times
- Joined: Aug 06, 2013 10:40 am
- Full Name: Peter Jansen
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
Well, I tried foldernames (various ways), no success.. Also looked at that other thread and it didn't help me either. I suspect the real folder(name) is different than it is visually presented by explorer. When I browse a backup I see a path (url) for a folder that is being backed up as : personal/somename/documents/testfolder. So this was a onedrive backup for "somename" for whom I'd like to exclude the testfolder. I can continue trying to find the correct path definition but maybe you can put me in the right direction for that..
thanks!
thanks!
-
- Product Manager
- Posts: 5797
- Liked: 1215 times
- Joined: Jul 15, 2013 11:09 am
- Full Name: Niels Engelen
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
If this is a subfolder, you should use documents\testfolder normally to exclude it. Did you try this already?
Personal blog: https://foonet.be
GitHub: https://github.com/nielsengelen
GitHub: https://github.com/nielsengelen
-
- Expert
- Posts: 235
- Liked: 37 times
- Joined: Aug 06, 2013 10:40 am
- Full Name: Peter Jansen
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
Hi Niels,
I did that, didn't work. created a complete new job to backup my onedrive. No other backup present for me. Added folderexclusion (2 folders):
....
$folders="documents\testfolder,documents\Googlechrome"
set-vbojob -job $job -excludedonedrivefolders $folders
...
ran the job, did as expected full, both folders are being backed up, so not excluded...
regards, Peter
I did that, didn't work. created a complete new job to backup my onedrive. No other backup present for me. Added folderexclusion (2 folders):
....
$folders="documents\testfolder,documents\Googlechrome"
set-vbojob -job $job -excludedonedrivefolders $folders
...
ran the job, did as expected full, both folders are being backed up, so not excluded...
regards, Peter
-
- Product Manager
- Posts: 8191
- Liked: 1322 times
- Joined: Feb 08, 2013 3:08 pm
- Full Name: Mike Resseler
- Location: Belgium
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
Peejay62,
Can you try it like this:
$folders = @("test", "test2", "test3")
Can you try it like this:
$folders = @("test", "test2", "test3")
-
- Expert
- Posts: 235
- Liked: 37 times
- Joined: Aug 06, 2013 10:40 am
- Full Name: Peter Jansen
- Contact:
Re: Trry to figure out excludeonedrivefolders syntax powershell
Hi Mike,
I tried that. That also didn't work (at first). To keep figuring out I changed to "selectedonedrivefolders" for trying to select just 1 folder. Put in a variety of notations for folders and succeeded in backup of one folder.
It seems to be the case that "documents" also belongs to the rootpath. So in order to select the folders "testfolders and Googlechrome" the folderarray needs to be $folders=@("testfolder", "Googlechrome")
Well, my problem is solved, I now can exclude folders that I don't want to backup out of MS365.
thanks, Peter
I tried that. That also didn't work (at first). To keep figuring out I changed to "selectedonedrivefolders" for trying to select just 1 folder. Put in a variety of notations for folders and succeeded in backup of one folder.
It seems to be the case that "documents" also belongs to the rootpath. So in order to select the folders "testfolders and Googlechrome" the folderarray needs to be $folders=@("testfolder", "Googlechrome")
Well, my problem is solved, I now can exclude folders that I don't want to backup out of MS365.
thanks, Peter
Who is online
Users browsing this forum: glwschwarz and 21 guests