Disable Onedrive for specific users

Brass Contributor

Hello,

 

Is there ability either in the Portal or via Powershell where I can disable OneDrive4B without disabling other Sharepoint sites?

 

thx

21 Replies

If, You mean you have list of user or all and you want change their license options (Plans)? For example, if you want to disable "Sites" you need to disable license option - "Sharepoint (Plan 1)" etc.

Example on PowerShell

(ctreate variable for license options)

$myO365SkuOption = New-MsolLicenseOptions -AccountSkuId <tenant>:ENTERPRISEPACK `
-DisabledPlans SHAREPOINTWAC

(set this option to user)

Set-MsolUserLicense -UserPrincipalName user1@tenant.onmicrosoft.com `
 -LicenseOptions $myO365SkuOption 

Or you can do it from GUI Admin center (User list menu)

Mustafiz is correct, these are the two approaches you have to selectively disable OneDrive for specific users. Easies way is by means of the license controls you have in the Administration Portal...right one, through PowerShell
Hi, your answers seems to cover all of shareponit, including OneDrive4B. Questions was if I can disable the personal OneDrive4B without other company SharePoint resources.
thx

As each Onedrive is technically a site collection where the the given user gets access rights through the site collection admin role, you can simply remove the user from the site collection admin role through the SP admin center or the Set-SPOUser PS cmdlet.

Ok, not the solution I was hoping for.

 

So if each user has its own site collection for OneDrive, does that also mean that we can remote the ability for a specific user to not be able to share anonymous links, while other specific users can.  I assume I would disable for the site collection "<domain>-my.sharepoint.com" and then enable via PS for individual users?

 

thx

 

 

Be aware that every user is (and must be) the site collection admin of his/her ODFB site collection.

Hence, whatever you configure in ODFB can be later reconfigured by the user and you can't forbid it.

To expand on this answer, there is new functionality for assigning licenses using Groups in Azure AD, see https://docs.microsoft.com/en-us/azure/active-directory/active-directory-licensing-group-assignment-...

Good point, but not aware that Azure allows for assigning ONLY OneDrive4B without SharePoint. Since that is in the same license, I am having to have to keep OneDrive since I need SharePoint. thx.

I agree with you and reminded me that the License assignment options seem to be incomplete because it is possible to buy standalone ODfB plans, but there does not seem to be anyway (in PowerShell or Azure AD) to assign a comparable license,

Hi,

Have you managed to find an answer / solution to this? 

Cheers,

Alex.

Hi, I have not.  It appears to me that OneDrive does not have a seperate license control to disable Onedrive for users without disabling sharepoint also.

 

thx

This is possible from SPO perspective via User Profiles. From SharePoint Admin Center > User Profiles > Manage User Permissions. Remove the 'Create Personal Site' permission for Everyone Except external users. Instead add a Security group with users which will have ODB access and assign it Create Personal Site permsisions. From now on, clicking on OneDrive shall redirect the users to Delve instead of ODB.

To remove onedrive client sync as well, delete the Mysite of the user via powershell or change site admins.

 

Hope this helps!

I have tried this approach and it doesn't work, as the test user still able to access their ODFB files normally.

Did ur test user have ODB prior to these changes? If yes, is he able to access ODB from browser even post changing the site collection admin ?
I have tested this and it is working seamlessly for me. Their offline files on the sync client will be accessible but they can't sync changes to ODB.

Hi Robert,

Can I ask the reason behind wanting to stop certain using have access to OneDrive? Is it more in line with the fear of certain behaviours surrounding compliance/security such as sharing, downloading, granting permissions etc? If so, shoot me a pm and I can point you in the right direction but I don't want to throw third-party solutions into this thread.

Thanks,

Tom

Hi Tom,

 

The reason for the request, is to be able to allow only key trusted/long time employees to share outside company if possible, not including all employees.  Currently am not looking at 2rd party solutions.

 

I do believe I seen that MS is working to get this capability soon however.

 

thx

 

 

One solution for that problem is to block external sharing for all OneDrive sites, enable it for designated SPO site collections and tell the trusted users to share from those external sharing enabled sites.

Hi,

 

Yes I have thought of this, however, it creates complications in my view, since some users need to be able to share directly from their main storage, without having to copy a file to another site, and then share from there, but thank you.

Please check this post on how to Selectively disable OneDrive for Busniess.

 

What no one tells you about disabling OneDrive for Business