Forum Discussion
Tom-irp
Jul 20, 2022Brass Contributor
AIP - running Execute-AzureAdLabelSync appeared to do nothing
Hello I have Azure P1 licensing and M365 Business Premium. I would like to use Purview/AIP for Teams/Sharepoint. The "groups and sites" checkbox is not enabled when creating a new sensitivity labe...
alfonsobatres1
Jun 25, 2024Copper Contributor
This worked for me:
set-executionpolicy remotesigned
Get sure you have a private Internet connection
winrm quickconfig
winrm get winrm/config/client/auth
This will enable "EnableMIPLabels" to true
Install-Module Microsoft.Graph -Scope CurrentUser
Install-Module Microsoft.Graph.Beta -Scope CurrentUser
Connect-MgGraph -Scopes "Directory.ReadWrite.All"
grpUnifiedSetting = Get-MgBetaDirectorySetting -Search DisplayName:"Group.Unified"
$grpUnifiedSetting = Get-MgBetaDirectorySetting
$grpUnifiedSetting
Get-MgBetaDirectorySetting
$Setting = Get-MgBetaDirectorySetting | where { $_.DisplayName -eq "Group.Unified"}
$Setting.Values
Copy this as a single sentence
$params = @{
Values = @(
@{
Name = "EnableMIPLabels"
Value = "true"
}
)
}
Validate the values are updated in params, and update the settings
$params.Values
Update-MgBetaDirectorySetting -DirectorySettingId $Setting.Id -BodyParameter $params
Validate they are updated
$Setting = Get-MgBetaDirectorySetting | where { $_.DisplayName -eq "Group.Unified"}
$Setting.Values
Now you can go ahead and enable Azure Label Sync, remember to use your own admin
Install-Module -Name ExchangeOnlineManagement
Import-Module ExchangeOnlineManagement
Connect-IPPSSession -UserPrincipalName email address removed for privacy reasons
Execute-AzureAdLabelSync
Disconnect-ExchangeOnline
If this does not work, go ahead and read the articles, they contain the information I posted here. Some lines are just for validation and not necessarily perform a function
Good luck