Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nervouswiggles/308b0e5f6ae2295c2273 to your computer and use it in GitHub Desktop.
Save nervouswiggles/308b0e5f6ae2295c2273 to your computer and use it in GitHub Desktop.
Issue when running an O365 Powershell command to disable the service plan. Error - Set-MsolUserLicense : Unable to assign this license. https://technicalconfessions.com/posts.php?post_id=408
PS C:\Windows\system32> $newLicenseAssignmentOption = New-MsolLicenseOptions -AccountSkuId Montgomerydev:STANDARDWOFFPACK_FACULTY -DisabledPlans SHAREPOINTSTANDARD_EDU
PS C:\Windows\system32> Get-MsolUser -ObjectId b8f53583-ec3f-47d2-afaf-a0f29ad22ad0 | Set-MsolUserLicense -LicenseOptions $newLicenseAssignmentOption
Set-MsolUserLicense : Unable to assign this license.
At line:1 char:63
+ Get-MsolUser -ObjectId b8f53583-ec3f-47d2-afaf-a0f29ad22ad0 | Set-MsolUserLicens ...
+ ~~~~~~~~~~~~~~~~~~
+ CategoryInfo : OperationStopped: (:) [Set-MsolUserLicense], MicrosoftOnlineException
+ FullyQualifiedErrorId : Microsoft.Online.Administration.Automation.InvalidLicenseConfigurationException,Microsoft.Online.Administration.Automation.SetUserLicense
PS C:\Windows\system32>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment