User Tools

Site Tools


microsoft_365:exchange_online:hybrid_public_folders

This is an old revision of the document!


Exchange Hybrid Public Folders

Memo fof dealing with Public Folders when using Exchange Hybrid setup or migrating PF folders to Exchange Online trough hybrid

Public Folders on on-premise Exchange, hybrid access for Exchange Online users

Prerequisites:

  • Azure AD Connect is setup and Exchange Hybrid Deployment is enabled
  • Exchange Hybrid Wizards has been run and hybrid is setup
  • Exchange autodiscover fully works

Sync AD objects of Public Folder mailboxes

From Exchange 2013 onward Public Folders are stored in specific public folder type mailboxes. Find AD objects of those and sync them with Azure AD Connect, either include the OU they are in or move the object into OU which is synced. PowerShell to find Public Folder Mailboxes:

 Get-Mailbox -PublicFolder | FL Name,Alias,Id

If you have Exchange 2010 and legacy public folder databases, better to read MS article of the setup: Configure legacy on-premises public folders for a hybrid deployment | Microsoft Docs

Sync mail-enabled Public Folders to Exchange Online

AD Connect or Exchange Hybrid actually does not synchronize mail enabled Public Folders to Exchange Online and if EXO user tries to send email to Public Folder it will fail. Public Folders needs to be synced with specific powershell scripts from Microsoft, Link . These script will create mail contacts for each mail-enabled public folder.

Extract Sync-ModernMailPublicFolders.ps1 and Sync-ModernMailPublicFolders.psd1 to some folder on Exchange server. Then run Sync-ModernMailPublicFolders in Exchange powershell. You will also need Global Admin credentials. Script does not support MFA, not sure if it can be modified. Run it first with -Whatif option to catch any errors.

''.\Sync-ModernMailPublicFolders.ps1 -Credential (Get-Credential) -CsvSummaryFile:sync_summary.cs -Whatif
''

Then if there is not much red errors remove -WhatIf and run it for real. I've seen errors about Offline Address Book folders being corrupted, these are usually some remains from older Exchange server and I've ignored them.

Activate remote Public Folders in Exchange Online

Set-OrganizationConfig -PublicFoldersEnabled Remote -RemotePublicFolderMailboxes PFMailbox1

Permissions

Add-RecipientPermission -Identity "[PF Mailbox Address]" -Trustee "[User UPN]" -AccessRights 'SendAs'
Set-MailPublicFolder "[PF Mailbox Address]" -GrantSendOnBehalfTo "UPN"
microsoft_365/exchange_online/hybrid_public_folders.1624546931.txt.gz · Last modified: 2021/06/24 18:02 by admintomi