Forum Discussion
rodoj
Jul 17, 2024Copper Contributor
Issue with retention policy with adaptive scope
Dear community, We created an adaptive scope and a retention policy about two weeks ago. If I check the scope details on the Purview portal, the adaptive scope shows 9602 users, but the policy shows...
FcoManigrasso
Jul 19, 2024Iron Contributor
Hi rodoj
I guess that you should be able to identify it checking for the mailboxes In-Place holds.
Get-Mailbox <username> | Select-Object -ExpandProperty InPlaceHolds
To get all organization-wide Microsoft Purview retention policies you can run:
Get-OrganizationConfig | FL InPlaceHolds
And once you have the GUID, somthing like this should work to get all the mailboxes with that policy applied:
Get-mailbox -Resultsize Unlimited | Where {$_.InPlaceHolds -like "*GUID*"}
You can get more information here: How to identify the hold on an Exchange Online mailbox | Microsoft Learn
Hope this helps.
Have a good day.
Best Regards,
Francisco Manigrasso.
- rodojJul 19, 2024Copper ContributorThanks for the suggestion, but that was the second point in the original article that I tried. I cannot see the GUID of this particular policy. I checked it in our test environment and there I saw the same result. I can't see the policy that is retaining Teams chats. Neither in the mailbox attributes nor by issuing the Get-ComplianceRetentionPolicy command.
- FcoManigrassoJul 19, 2024Iron Contributor
Hi rodoj
That´s strange. You may need to open a support case.
Do you see al correct in the policy details?
When you click on Policy details you should find the "Locations" section.
On the other hand, if you know that the scope is working properly, you can identify the mailboxes running something like this, (adapt to your scope):
$attribute = "Department" $value = "Sales" Get-Mailbox -Filter "{$attribute -eq '$value'}" | Select-Object DisplayName, PrimarySmtpAddress
- rodojAug 02, 2024Copper ContributorThanks for the comment. We have already opened a support case, but there is no progress so far... We are sure that the problem is on MS' side. We tried everything that we could. The scope is okay, but the policy does not cover all the accounts from the adaptive scope, even though the policy details say the status is Enabled (Success). But if I query the policy from powershell it says SyncTimeout.