I did run into the situation that I lost all my public folder permissions which were assigned via groups.
Before the migration started from our MSEX2016 server to Office 365, all the permissions got exported to a XML file, what I think (described on this Microsoft page) happened with the following command:
Get-PublicFolder -Recurse -ResultSize Unlimited | Get-PublicFolderClientPermission | Select-Object Identity,User,AccessRights -ExpandProperty AccessRights | Export-CliXML OnPrem_PFPerms.xml
The output file "OnPrem_PFPerms.xml" has about 5 GB. That sounds a lot to me for permissions only on a about 300 GB PF structure, but maybe is its huge size cause by the complexity of the XML format. 7-Zip compression brings it down to 25 MB, means there is a lot of redundant data in it.
On our MSEX2010 which got migrated to MSEX2016 before is a "Legacy_PFPerms.xml" file with about 500 MB.
What would be the proper PowerShell command to apply all the permissions from the XML file to the public folder structure on the Office 365 / Exchange online?
I guess Import-CliXML would do the job somehow, but I am not that familiar with PowerShell to build the right command.