Forum Discussion
Jesper Stein
Sep 01, 2017Brass Contributor
Removing owner from all OneDrives....
I need some help to a powershell script, that can remove an owner on all users OneDrive. The user is added trough a 3rd party tool named ShareGate (I think by mistake) by the Sharepoint admin, so no...
- Sep 01, 2017
You can refer the this blog and it will be helpful for you
http://www.jijitechnologies.com/blogs/add-remove-secondary-site-collection-admin-to-all-onedrive-for-business-users
Sep 01, 2017
I think you can do this by following bellow steps:
(1) This script will provide you the logic to access all the ODFBs of all the users in your tenant: https://gallery.technet.microsoft.com/office/How-to-get-all-the-space-24065b8c
(2) Use Set-SPOSite in the following way to remove the added ODFB admin: Set-SPOUser -Site $spoODFBUrl -LoginName $Office365ODFBAdmin -IsSiteCollectionAdmin $false
(1) This script will provide you the logic to access all the ODFBs of all the users in your tenant: https://gallery.technet.microsoft.com/office/How-to-get-all-the-space-24065b8c
(2) Use Set-SPOSite in the following way to remove the added ODFB admin: Set-SPOUser -Site $spoODFBUrl -LoginName $Office365ODFBAdmin -IsSiteCollectionAdmin $false
Daniel Richardson
Dec 12, 2017Copper Contributor
Had the same thing pop up in our tenant. This script helped resolve it, Thanks!!!