Anyone knows a way to create a retention policy for EXO Inactive mailboxes?

%3CLINGO-SUB%20id%3D%22lingo-sub-2825637%22%20slang%3D%22en-US%22%3EAnyone%20knows%20a%20way%20to%20create%20a%20retention%20policy%20for%20EXO%20Inactive%20mailboxes%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2825637%22%20slang%3D%22en-US%22%3E%3CP%3EIn%20the%20article%20section%20of%20%22%3CSTRONG%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fmicrosoft-365%2Fcompliance%2Finactive-mailboxes-in-office-365%3Fview%3Do365-worldwide%23inactive-mailboxes-and-microsoft-365-retention-policies%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3EInactive%20mailboxes%20and%20Microsoft%20365%20retention%20policies%3C%2FA%3E%3C%2FSTRONG%3E%22%20it%20specifies%3A%3C%2FP%3E%3CBLOCKQUOTE%3E%3CP%3EYou%20might%20consider%20creating%20a%20Microsoft%20365%20retention%20policy%20specifically%20for%20inactive%20mailboxes.%20Here%20are%20some%20reasons%20for%20doing%20this%20and%20things%20to%20keep%20in%20mind.%3C%2FP%3E%3CP%3EYou%20can%20configure%20the%20retention%20policy%20to%20retain%20mailbox%20content%20only%20as%20long%20as%20necessary%20to%20meet%20your%20organization's%20requirement%20for%20former%20employees.%3C%2FP%3E%3CP%3EIt's%20a%20good%20way%20to%20identify%20inactive%20mailboxes%20because%20the%20retention%20policy%20will%20only%20be%20applied%20to%20inactive%20mailboxes.%3C%2FP%3E%3CP%3EYou%20are%20able%20to%20quickly%20identify%20the%20retention%20policy%20that's%20assigned%20to%20inactive%20mailboxes%20in%20your%20organization.%20This%20makes%20it%20easier%20to%20change%20the%20retention%20(or%20deletion)%20settings%20if%20necessary.%20It%20will%20also%20make%20it%20easier%20to%20permanently%20delete%20an%20inactive%20mailbox%20because%20you%20can%20remove%20it%20from%20the%20policy%20by%20using%20the%20Microsoft%20365%20compliance%20center.%20Otherwise%2C%20you%20have%20to%20use%20Exchange%20Online%20PowerShell%20to%20remove%20a%20Litigation%20Hold%20from%20an%20inactive%20mailbox%20or%20use%20Security%20%26amp%3B%20Compliance%20Center%20PowerShell%20to%20exclude%20an%20inactive%20mailbox%20from%20an%20organization-wide%20Microsoft%20365%20retention%20policy.%3C%2FP%3E%3CP%3EIf%20you%20create%20a%20Microsoft%20365%20retention%20policy%20specifically%20for%20inactive%20mailboxes%2C%20you%20can%20add%20a%20maximum%20of%201%2C000%20mailboxes%20to%20the%20policy.%20If%20you're%20a%20large%20organization%2C%20you%20might%20have%20to%20create%20more%20than%20one%20Microsoft%20365%20retention%20policy%20to%20use%20for%20inactive%20mailboxes.%3C%2FP%3E%3C%2FBLOCKQUOTE%3E%3CP%3EThese%20are%20exactly%20what%20my%20organization%20wants.%20However%2C%20I%20wonder%20whether%20it%20is%20possible%20to%20create%20a%20retention%20policy%20targeting%20all%20the%20inactive%20mailboxes.%20If%20so%2C%20what%20are%20the%20process%20to%20create%20such%20a%20retention%20policy.%20This%20article%20did%20not%20provide%20any%20feasible%20way%20to%20create%20such%20a%20policy.%3CBR%20%2F%3E%3CBR%20%2F%3ECould%20anyone%20advise%20whether%20it%20is%20possible%20and%20how%20this%20retention%20policy%20can%20be%20created%3F%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FP%3E%3CP%3EIn%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fmicrosoft-365%2Fcompliance%2Fcreate-retention-policies%3Fview%3Do365worldwide%23configuration-information-for-exchange-email-and-exchange-public-folders%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Eanother%20document%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3EIt%20mentions%3A%3C%2FP%3E%3CBLOCKQUOTE%3E%3CP%3EWhen%20you%20apply%20the%20retention%20settings%20to%20All%20recipients%2C%20any%20inactive%20mailboxes%20are%20included.%20However%2C%20if%20you%20change%20this%20default%20and%20configure%20specific%20inclusions%20or%20exclusions%2C%20inactive%20mailboxes%20aren't%20supported%20and%20retention%20settings%20won't%20be%20applied%20or%20excluded%20for%20those%20mailboxes.%3C%2FP%3E%3C%2FBLOCKQUOTE%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2825637%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExchange%20Online%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3Einactive%20mailbox%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ERetention%20Policy%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2826225%22%20slang%3D%22en-US%22%3ERe%3A%20Anyone%20knows%20a%20way%20to%20create%20a%20retention%20policy%20for%20EXO%20Inactive%20mailboxes%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2826225%22%20slang%3D%22en-US%22%3E%3CDIV%20class%3D%22%22%3E%3CP%3E%3CSPAN%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-organizationConfig%20%7C%20Fl%20InplaceHolds%2C%20LitigationHoldEnabled%3C%2FSPAN%3E%3C%2FP%3E%3C%2FDIV%3E%3CP%3EInPlaceHolds%20%3A%20%7Bmbx78340bdddf8a4bf3b480d566e69a7a64%3A2%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%23Note%3A%20this%20LitigationHold%20is%20manually%20enabled%3C%2FP%3E%3CP%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-mailbox%20-InactiveMailboxOnly%20-Identity%20DiegoS%20%7C%20FL%20LitigationHoldEnabled%2CInPlaceHolds%3C%2FP%3E%3CP%3ELitigationHoldEnabled%20%3A%20True%3CBR%20%2F%3EInPlaceHolds%20%3A%20%7B%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Get-RetentionCompliancePolicy%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-DistributionDetail%20%7C%20Fl%20Name%2C%20*Location%3C%2FP%3E%3CP%3EName%20%3A%20Retain%20mailboxes%20forever%3CBR%20%2F%3ESharePointLocation%20%3A%20%7B%7D%3CBR%20%2F%3EExchangeLocation%20%3A%20%7BAll%7D%3CBR%20%2F%3EPublicFolderLocation%20%3A%20%7B%7D%3CBR%20%2F%3ESkypeLocation%20%3A%20%7B%7D%3CBR%20%2F%3EModernGroupLocation%20%3A%20%7B%7D%3CBR%20%2F%3EOneDriveLocation%20%3A%20%7B%7D%3CBR%20%2F%3ETeamsChatLocation%20%3A%20%7B%7D%3CBR%20%2F%3ETeamsChannelLocation%20%3A%20%7B%7D%3CBR%20%2F%3EAdaptiveScopeLocation%20%3A%20%7B%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-organizationConfig%20%7C%20Fl%20InplaceHolds%2C%20LitigationHoldEnabled%3C%2FP%3E%3CP%3EInPlaceHolds%20%3A%20%7Bmbx78340bdddf8a4bf3b480d566e69a7a64%3A2%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%23Note%3A%20this%20LitigationHold%20is%20manually%20enabled%3C%2FP%3E%3CP%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-mailbox%20-InactiveMailboxOnly%20-Identity%20DiegoS%20%7C%20FL%20LitigationHoldEnabled%2CInPlaceHolds%3C%2FP%3E%3CP%3ELitigationHoldEnabled%20%3A%20True%3CBR%20%2F%3EInPlaceHolds%20%3A%20%7B%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Get-RetentionCompliancePolicy%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-DistributionDetail%20%7C%20Fl%20Name%2C%20*Location%3C%2FP%3E%3CP%3EName%20%3A%20Retain%20mailboxes%20forever%3CBR%20%2F%3ESharePointLocation%20%3A%20%7B%7D%3CBR%20%2F%3EExchangeLocation%20%3A%20%7BAll%7D%3CBR%20%2F%3EPublicFolderLocation%20%3A%20%7B%7D%3CBR%20%2F%3ESkypeLocation%20%3A%20%7B%7D%3CBR%20%2F%3EModernGroupLocation%20%3A%20%7B%7D%3CBR%20%2F%3EOneDriveLocation%20%3A%20%7B%7D%3CBR%20%2F%3ETeamsChatLocation%20%3A%20%7B%7D%3CBR%20%2F%3ETeamsChannelLocation%20%3A%20%7B%7D%3CBR%20%2F%3EAdaptiveScopeLocation%20%3A%20%7B%7D%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAccording%20to%20documentation%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fpowershell%2Fmodule%2Fexchange%2Fnew-retentioncompliancepolicy%3Fview%3Dexchange-ps%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3ENew-RetentionCompliancePolicy%20(ExchangePowerShell)%20%7C%20Microsoft%20Docs%3C%2FA%3E%3C%2FP%3E%3CDIV%3E-ExchangeLocation%3C%2FDIV%3E%3CDIV%20class%3D%22%22%3E%3CP%3EThe%20ExchangeLocation%20parameter%20specifies%20the%20mailboxes%20to%20include.%20Valid%20values%20are%3A%3C%2FP%3E%3CUL%3E%3CLI%3EA%20mailbox%3C%2FLI%3E%3CLI%3EA%20distribution%20group%20or%20mail-enabled%20security%20group%20(all%20mailboxes%20that%20are%20currently%20members%20of%20the%20group).%3C%2FLI%3E%3CLI%3EThe%20value%20All%20for%20all%20mailboxes.%20You%20can%20only%20use%20this%20value%20by%20itself.%3C%2FLI%3E%3C%2FUL%3E%3CP%3ETo%20specify%20a%20mailbox%20or%20distribution%20group%2C%20you%20can%20use%20any%20value%20that%20uniquely%20identifies%20it.%20For%20example%3A%3C%2FP%3E%3CUL%3E%3CLI%3EName%3C%2FLI%3E%3CLI%3EDistinguished%20name%20(DN)%3C%2FLI%3E%3CLI%3EEmail%20address%3C%2FLI%3E%3CLI%3EGUID%3C%2FLI%3E%3C%2FUL%3E%3CP%3ESo%20the%20pain%20starts......%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CPRE%3EPS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22DiegoS%22%0AThe%20specified%20recipient%20%22DiegoS%22%20couldn't%20be%20found.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectNotFoundException%20%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3D42a03677-62f2-4792-a1b4-6e7d08d879d2%2CTimeStamp%3D8%2F10%2F2021%209%3A13%3A35%20AM%5D%20%5BFailur%20eCategory%3DCmdlet-ManagementObjectNotFoundException%5D%203930D393%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%20%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-mailbox%20-InactiveMailboxOnly%20-Identity%20DiegoS%20%7C%20FL%20Guid%2C%20ExchangeGuid%2C%20DatabaseGuid%2C%20UserPrincipalName%2C%20DistingishedName%0A%0AGuid%20%3A%20426d751b-c0e4-4f14-b6ab-3897abd64907%0AExchangeGuid%20%3A%20e5364dd8-1716-468b-8e28-16731a7740df%0ADatabaseGuid%20%3A%20f720391d-f654-40d7-a84e-c57a1c74d204%0AUserPrincipalName%20%3A%20DiegoS%40ahu001.onmicrosoft.com%0A%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20get-mailbox%20-InactiveMailboxOnly%20-Identity%20DiegoS%20%7C%20FL%20Guid%2C%20ExchangeGuid%2C%20DatabaseGuid%2C%20UserPrincipalName%2C%20DistinguishedName%0A%0AGuid%20%3A%20426d751b-c0e4-4f14-b6ab-3897abd64907%0AExchangeGuid%20%3A%20e5364dd8-1716-468b-8e28-16731a7740df%0ADatabaseGuid%20%3A%20f720391d-f654-40d7-a84e-c57a1c74d204%0AUserPrincipalName%20%3A%20DiegoS%40ahu001.onmicrosoft.com%0ADistinguishedName%20%3A%20CN%3DDiegoS%2COU%3DSoft%20Deleted%20Objects%2COU%3Dahu001.onmicrosoft.com%2COU%3DMicrosoft%20Exchange%20Hosted%0AOrganizations%2CDC%3DAUSP282A003%2CDC%3DPROD%2CDC%3DOUTLOOK%2CDC%3DCOM%0A%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22426d751b-c0e4-4f14-b6ab-3897abd64907%22%0ACreating%20a%20new%20Remote%20PowerShell%20session%20using%20Modern%20Authentication%20for%20implicit%20remoting%20of%20%22Set-RetentionCompliancePolicy%22%20command%20...%0AWARNING%3A%20Your%20connection%20has%20been%20redirected%20to%20the%20following%20URI%3A%0A%22https%3A%2F%2Faus01b.ps.compliance.protection.outlook.com%2FPowershell-LiveId%3FBasicAuthToOAuthConversion%3Dtrue%3BPSVersion%3D5.1.19041.1237%22%0AThis%20operation%20requires%20a%20unique%20source%20object%2C%20but%20multiple%20objects%20have%20been%20found%20for%20the%20recipient%0A%22426d751b-c0e4-4f14-b6ab-3897abd64907%22.%20Please%20remove%20any%20wildcard%20characters%20and%20check%20the%20data%20source%20for%20corruption.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectAmbiguousException%0A%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3D44ed850e-2bb9-4630-82da-14733e41fce6%2CTimeStamp%3D8%2F10%2F2021%209%3A18%3A50%20AM%5D%20%5BFailur%0AeCategory%3DCmdlet-ManagementObjectAmbiguousException%5D%20455E7C8D%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%0A%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%0A%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22e5364dd8-1716-468b-8e28-16731a7740df%22%0AThis%20operation%20requires%20a%20unique%20source%20object%2C%20but%20multiple%20objects%20have%20been%20found%20for%20the%20recipient%0A%22e5364dd8-1716-468b-8e28-16731a7740df%22.%20Please%20remove%20any%20wildcard%20characters%20and%20check%20the%20data%20source%20for%20corruption.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectAmbiguousException%0A%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3Dab2f2837-9a15-470d-89e6-16a87a3691e6%2CTimeStamp%3D8%2F10%2F2021%209%3A19%3A16%20AM%5D%20%5BFailur%0AeCategory%3DCmdlet-ManagementObjectAmbiguousException%5D%2075D0ECB8%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%0A%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%0A%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22f720391d-f654-40d7-a84e-c57a1c74d204%22%0AThis%20operation%20requires%20a%20unique%20source%20object%2C%20but%20multiple%20objects%20have%20been%20found%20for%20the%20recipient%0A%22f720391d-f654-40d7-a84e-c57a1c74d204%22.%20Please%20remove%20any%20wildcard%20characters%20and%20check%20the%20data%20source%20for%20corruption.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectAmbiguousException%0A%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3D80788e3c-3d66-4650-ad35-57a3ae467eb6%2CTimeStamp%3D8%2F10%2F2021%209%3A19%3A34%20AM%5D%20%5BFailur%0AeCategory%3DCmdlet-ManagementObjectAmbiguousException%5D%20BD2815F1%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%0A%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22DiegoS%40ahu001.onmicrosoft.com%22%0AThe%20specified%20recipient%20%22DiegoS%40ahu001.onmicrosoft.com%22%20couldn't%20be%20found.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectNotFoundException%0A%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3D3cde8e9a-a17b-4199-94bf-02959e663820%2CTimeStamp%3D8%2F10%2F2021%209%3A19%3A50%20AM%5D%20%5BFailur%0AeCategory%3DCmdlet-ManagementObjectNotFoundException%5D%20B9C63728%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%0A%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%0A%0APS%20C%3A%5CWINDOWS%5Csystem32%26gt%3B%20Set-RetentionCompliancePolicy%20-Identity%20%2278340bdddf8a4bf3b480d566e69a7a64%22%20-AddExchangeLocationException%20%22CN%3DDiegoS%2COU%3DSoft%20Deleted%20Objects%2COU%3Dahu001.onmicrosoft.com%2COU%3DMicrosoft%20Exchange%20Hosted%20Organizations%2CDC%3DAUSP282A003%2CDC%3DPROD%2CDC%3DOUTLOOK%2CDC%3DCOM%22%0AThe%20specified%20recipient%20%22CN%3DDiegoS%2COU%3DSoft%20Deleted%20Objects%2COU%3Dahu001.onmicrosoft.com%2COU%3DMicrosoft%20Exchange%20Hosted%0AOrganizations%2CDC%3DAUSP282A003%2CDC%3DPROD%2CDC%3DOUTLOOK%2CDC%3DCOM%22%20couldn't%20be%20found.%0A%2B%20CategoryInfo%20%3A%20NotSpecified%3A%20(%3A)%20%5BSet-RetentionCompliancePolicy%5D%2C%20ManagementObjectNotFoundException%0A%2B%20FullyQualifiedErrorId%20%3A%20%5BServer%3DME1AUS01WS002%2CRequestId%3D0ea3c23c-1f35-4266-936f-690389166c63%2CTimeStamp%3D8%2F10%2F2021%209%3A20%3A14%20AM%5D%20%5BFailur%0AeCategory%3DCmdlet-ManagementObjectNotFoundException%5D%201DEF8726%2CMicrosoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy%0A%2B%20PSComputerName%20%3A%20aus01b.ps.compliance.protection.outlook.com%3C%2FPRE%3E%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2827850%22%20slang%3D%22en-US%22%3ERe%3A%20Anyone%20knows%20a%20way%20to%20create%20a%20retention%20policy%20for%20EXO%20Inactive%20mailboxes%3F%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2827850%22%20slang%3D%22en-US%22%3EI%20dont%20think%20there%20is%20one%2C%20perhaps%20with%20the%20newly%20introduced%20adaptive%20scopes%3F%3C%2FLINGO-BODY%3E
New Contributor

In the article section of "Inactive mailboxes and Microsoft 365 retention policies" it specifies:

You might consider creating a Microsoft 365 retention policy specifically for inactive mailboxes. Here are some reasons for doing this and things to keep in mind.

You can configure the retention policy to retain mailbox content only as long as necessary to meet your organization's requirement for former employees.

It's a good way to identify inactive mailboxes because the retention policy will only be applied to inactive mailboxes.

You are able to quickly identify the retention policy that's assigned to inactive mailboxes in your organization. This makes it easier to change the retention (or deletion) settings if necessary. It will also make it easier to permanently delete an inactive mailbox because you can remove it from the policy by using the Microsoft 365 compliance center. Otherwise, you have to use Exchange Online PowerShell to remove a Litigation Hold from an inactive mailbox or use Security & Compliance Center PowerShell to exclude an inactive mailbox from an organization-wide Microsoft 365 retention policy.

If you create a Microsoft 365 retention policy specifically for inactive mailboxes, you can add a maximum of 1,000 mailboxes to the policy. If you're a large organization, you might have to create more than one Microsoft 365 retention policy to use for inactive mailboxes.

These are exactly what my organization wants. However, I wonder whether it is possible to create a retention policy targeting all the inactive mailboxes. If so, what are the process to create such a retention policy. This article did not provide any feasible way to create such a policy.

Could anyone advise whether it is possible and how this retention policy can be created?

In another document It mentions:

When you apply the retention settings to All recipients, any inactive mailboxes are included. However, if you change this default and configure specific inclusions or exclusions, inactive mailboxes aren't supported and retention settings won't be applied or excluded for those mailboxes.

3 Replies

PS C:\WINDOWS\system32> get-organizationConfig | Fl InplaceHolds, LitigationHoldEnabled

InPlaceHolds : {mbx78340bdddf8a4bf3b480d566e69a7a64:2}

 

#Note: this LitigationHold is manually enabled

PS C:\WINDOWS\system32> get-mailbox -InactiveMailboxOnly -Identity DiegoS | FL LitigationHoldEnabled,InPlaceHolds

LitigationHoldEnabled : True
InPlaceHolds : {}

 

PS C:\WINDOWS\system32> Get-RetentionCompliancePolicy "78340bdddf8a4bf3b480d566e69a7a64" -DistributionDetail | Fl Name, *Location

Name : Retain mailboxes forever
SharePointLocation : {}
ExchangeLocation : {All}
PublicFolderLocation : {}
SkypeLocation : {}
ModernGroupLocation : {}
OneDriveLocation : {}
TeamsChatLocation : {}
TeamsChannelLocation : {}
AdaptiveScopeLocation : {}

 

PS C:\WINDOWS\system32> get-organizationConfig | Fl InplaceHolds, LitigationHoldEnabled

InPlaceHolds : {mbx78340bdddf8a4bf3b480d566e69a7a64:2}

 

#Note: this LitigationHold is manually enabled

PS C:\WINDOWS\system32> get-mailbox -InactiveMailboxOnly -Identity DiegoS | FL LitigationHoldEnabled,InPlaceHolds

LitigationHoldEnabled : True
InPlaceHolds : {}

 

PS C:\WINDOWS\system32> Get-RetentionCompliancePolicy "78340bdddf8a4bf3b480d566e69a7a64" -DistributionDetail | Fl Name, *Location

Name : Retain mailboxes forever
SharePointLocation : {}
ExchangeLocation : {All}
PublicFolderLocation : {}
SkypeLocation : {}
ModernGroupLocation : {}
OneDriveLocation : {}
TeamsChatLocation : {}
TeamsChannelLocation : {}
AdaptiveScopeLocation : {}

 

According to documentation New-RetentionCompliancePolicy (ExchangePowerShell) | Microsoft Docs

-ExchangeLocation

The ExchangeLocation parameter specifies the mailboxes to include. Valid values are:

  • A mailbox
  • A distribution group or mail-enabled security group (all mailboxes that are currently members of the group).
  • The value All for all mailboxes. You can only use this value by itself.

To specify a mailbox or distribution group, you can use any value that uniquely identifies it. For example:

  • Name
  • Distinguished name (DN)
  • Email address
  • GUID

So the pain starts......

 

PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "DiegoS"
The specified recipient "DiegoS" couldn't be found.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectNotFoundException + FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=42a03677-62f2-4792-a1b4-6e7d08d879d2,TimeStamp=8/10/2021 9:13:35 AM] [Failur eCategory=Cmdlet-ManagementObjectNotFoundException] 3930D393,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy + PSComputerName : aus01b.ps.compliance.protection.outlook.com

PS C:\WINDOWS\system32> get-mailbox -InactiveMailboxOnly -Identity DiegoS | FL Guid, ExchangeGuid, DatabaseGuid, UserPrincipalName, DistingishedName

Guid : 426d751b-c0e4-4f14-b6ab-3897abd64907
ExchangeGuid : e5364dd8-1716-468b-8e28-16731a7740df
DatabaseGuid : f720391d-f654-40d7-a84e-c57a1c74d204
UserPrincipalName : DiegoS@ahu001.onmicrosoft.com


PS C:\WINDOWS\system32> get-mailbox -InactiveMailboxOnly -Identity DiegoS | FL Guid, ExchangeGuid, DatabaseGuid, UserPrincipalName, DistinguishedName

Guid : 426d751b-c0e4-4f14-b6ab-3897abd64907
ExchangeGuid : e5364dd8-1716-468b-8e28-16731a7740df
DatabaseGuid : f720391d-f654-40d7-a84e-c57a1c74d204
UserPrincipalName : DiegoS@ahu001.onmicrosoft.com
DistinguishedName : CN=DiegoS,OU=Soft Deleted Objects,OU=ahu001.onmicrosoft.com,OU=Microsoft Exchange Hosted
Organizations,DC=AUSP282A003,DC=PROD,DC=OUTLOOK,DC=COM


PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "426d751b-c0e4-4f14-b6ab-3897abd64907"
Creating a new Remote PowerShell session using Modern Authentication for implicit remoting of "Set-RetentionCompliancePolicy" command ...
WARNING: Your connection has been redirected to the following URI:
"https://aus01b.ps.compliance.protection.outlook.com/Powershell-LiveId?BasicAuthToOAuthConversion=true;PSVersion=5.1.19041.1237"
This operation requires a unique source object, but multiple objects have been found for the recipient
"426d751b-c0e4-4f14-b6ab-3897abd64907". Please remove any wildcard characters and check the data source for corruption.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectAmbiguousException
+ FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=44ed850e-2bb9-4630-82da-14733e41fce6,TimeStamp=8/10/2021 9:18:50 AM] [Failur
eCategory=Cmdlet-ManagementObjectAmbiguousException] 455E7C8D,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy
+ PSComputerName : aus01b.ps.compliance.protection.outlook.com


PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "e5364dd8-1716-468b-8e28-16731a7740df"
This operation requires a unique source object, but multiple objects have been found for the recipient
"e5364dd8-1716-468b-8e28-16731a7740df". Please remove any wildcard characters and check the data source for corruption.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectAmbiguousException
+ FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=ab2f2837-9a15-470d-89e6-16a87a3691e6,TimeStamp=8/10/2021 9:19:16 AM] [Failur
eCategory=Cmdlet-ManagementObjectAmbiguousException] 75D0ECB8,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy
+ PSComputerName : aus01b.ps.compliance.protection.outlook.com


PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "f720391d-f654-40d7-a84e-c57a1c74d204"
This operation requires a unique source object, but multiple objects have been found for the recipient
"f720391d-f654-40d7-a84e-c57a1c74d204". Please remove any wildcard characters and check the data source for corruption.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectAmbiguousException
+ FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=80788e3c-3d66-4650-ad35-57a3ae467eb6,TimeStamp=8/10/2021 9:19:34 AM] [Failur
eCategory=Cmdlet-ManagementObjectAmbiguousException] BD2815F1,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy
+ PSComputerName : aus01b.ps.compliance.protection.outlook.com

PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "DiegoS@ahu001.onmicrosoft.com"
The specified recipient "DiegoS@ahu001.onmicrosoft.com" couldn't be found.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectNotFoundException
+ FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=3cde8e9a-a17b-4199-94bf-02959e663820,TimeStamp=8/10/2021 9:19:50 AM] [Failur
eCategory=Cmdlet-ManagementObjectNotFoundException] B9C63728,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy
+ PSComputerName : aus01b.ps.compliance.protection.outlook.com

PS C:\WINDOWS\system32> Set-RetentionCompliancePolicy -Identity "78340bdddf8a4bf3b480d566e69a7a64" -AddExchangeLocationException "CN=DiegoS,OU=Soft Deleted Objects,OU=ahu001.onmicrosoft.com,OU=Microsoft Exchange Hosted Organizations,DC=AUSP282A003,DC=PROD,DC=OUTLOOK,DC=COM"
The specified recipient "CN=DiegoS,OU=Soft Deleted Objects,OU=ahu001.onmicrosoft.com,OU=Microsoft Exchange Hosted
Organizations,DC=AUSP282A003,DC=PROD,DC=OUTLOOK,DC=COM" couldn't be found.
+ CategoryInfo : NotSpecified: (:) [Set-RetentionCompliancePolicy], ManagementObjectNotFoundException
+ FullyQualifiedErrorId : [Server=ME1AUS01WS002,RequestId=0ea3c23c-1f35-4266-936f-690389166c63,TimeStamp=8/10/2021 9:20:14 AM] [Failur
eCategory=Cmdlet-ManagementObjectNotFoundException] 1DEF8726,Microsoft.Office.CompliancePolicy.Tasks.SetRetentionCompliancePolicy
+ PSComputerName : aus01b.ps.compliance.protection.outlook.com
I dont think there is one, perhaps with the newly introduced adaptive scopes?

@Vasil Michev It has been answered by Mark Johnson@MSFT:
Is it even possible to create a retention policy for Inactive Mailboxes only and what are the proces...

You are correct to assume that you can't add an existing inactive mailbox to a retention policy. The guidance in this article implies that you would have to add a mailbox to a retention policy before the mailbox is made inactive. So the sequence would be to add active mailbox to an explicit retention policy and then make the mailbox inactive.