Forum Discussion
Dean_Gross
Jun 04, 2019Silver Contributor
Admins don't include Office 365 Group Owners
In the SPO Admin Center, on the Information Panel I see the following message for some sites:
The admins for this site don't include the Office 365 group owners.Add the group owners as admins
I think that this was caused by another admin running a script incorrectly
Does anyone know what property this is using and how I can fix this for all of the sites in the tenant automatically?
It's most likely going to be someone overwrote all the site collection admins of the sites and they don't have the owners group set as site collection admins?
You should either be able to go to site collection admins in the site itself if you have access, or run powershell get-spouser -site "Siteurl" | fl and check for the group in there and IsSiteAdmin should be true on the owners group. If not then we need to set that using set-spouser -site "siteurl" -LoginName guid -IsSitecollectionadmin $true guid being the guid of that group.You might be able to script using the IsGroup property to find the groups where the name includes Owners but it could get complicated to do for all sites, but forall looping and looking for something like that might work, you should be able to write a select for all the owner groups and export to csv and audit it, if it looks like it would be the right groups then you can then take that query and then you can use set-sposite command with similar filters and make all those groups sitecollection admins. I'm no powershell expert, but it goes something like that, but it'll take some work to figure out.