Hi All,
I am attempting to assign a few licenses via powershell to a specific security group in our o365 environment. I have an older powershell script that assigns licenses ok if they don't have a mailbox associated with the license, but it doesn't seem to handle licenses with exchange attached well.
I have been attempting to use the following command, but it states that my license is not valid,
Get-MsolGroupMember -All -GroupObjectId (security group guid) | Set-MsolUserLicense -AddLicenses "(AccountSkuID)"
This has worked for me in the past for removing licenses, but now I cannot seem to even get it to do that. I know the that the sku's are correct.
Has anyone done any license assignment via security groups? I can't do by CSV since we are phasing out an old setup and we cannot discern new from old accounts easily.