This will grant full access rights to all mailboxes for the Domain Admins group. Obviously, you need to replace “YourDomainHere” with your actual domain name. Type the following inside of the Exchange Management Shell:
Get-Mailbox -ResultSize unlimited -Filter {(RecipientTypeDetails -eq 'UserMailbox') -and (Alias -ne 'Admin')} | Add-MailboxPermission -User "YourDomainHere\Domain Admins" -AccessRights fullaccess -InheritanceType all