UPDATED 21-08-2020 - Added Exchange Online method
An outlook user with access to a shared mailbox, send as or send on behalf of rights sends an email from the shared mailbox, but the sent email doesn't get saved in the shared mailbox sent items folder but in the users sent items folder.
Since Exchange server 2010 SP2 update roll-up 4 it's possible to specify where the sent emails will be saved. This also goes for Exchange server 2013 CU9 and up.
First check the current settings for a shared mailbox:
Get-MailboxSentItemsConfiguration -Identity sharedmailboxname RunspaceId : 2d911aef-3416-42f9-9900-531d0fcdea94 SendAsItemsCopiedTo : Sender SendOnBehalfOfItemsCopiedTo : Sender Identity : IsValid : TrueAs you can see the "SendasItemsCopiedTo" and "SendOnBehalfOfItemsCopiedTo" is set to "Sender"
There are 2 settings to choose from: "Sender" "SenderAndFrom".
To set it to save in both mailboxes use:
Set-MailboxSentItemsConfiguration -Identity sharedmailboxname -SendAsItemsCopiedTo ` senderandfrom -SendOnBehalfOfItemsCopiedTo SenderAndFromCheck to be sure:
Get-MailboxSentItemsConfiguration -Identity sharedmailboxname RunspaceId : 2d911aef-3416-42f9-9900-531d0fcdea94 SendAsItemsCopiedTo : SenderAndFrom SendOnBehalfOfItemsCopiedTo : SenderAndFrom Identity : IsValid : TrueSet it to all shared mailboxes in a nice one liner for Exchange 2010:
Get-Mailbox -ResultSize Unlimited -RecipientTypeDetails sharedmailbox | Set-MailboxSentItemsConfiguration ` -SendAsItemsCopiedTo SenderandFrom -SendOnBehalfOfItemsCopiedTo SenderAndFromSet it to all shared mailboxes in a nice one liner for Exchange 2013:
Get-Mailbox -ResultSize Unlimited -RecipientTypeDetails sharedmailbox | Set-Mailbox ` -MessageCopyForSendOnBehalfEnabled $True -MessageCopyForSentAsEnabled $TrueFor Exchange Online there are two ways of doing this, in is in the Office 365 Admin portal and the other is in PowerShell.
In the Portal go to Groups - Shared Mailboxes
Then find the Shared mailbox you want to edit and edit "Sent Items"
And here you will see the two toggles to choose you options
With PowerShell:
After loggin in to Exchange Online Check the shared mailbox you want to modify:
Get-EXOMailbox -Identity sharedmailbox@domain.com | FL
MessageCopyForSentAsEnabled : True
MessageCopyForSendOnBehalfEnabled : True
Set these attributes for a single mailbox:
Set-EXOMailbox -Identity sharedmailbox@domain.com -MessageCopyForSendOnBehalfEnabled $true -MessageCopyForSentAsEnabled $true
Enable these settings on all your shared mailboxes in your environment:Get-EXOMailbox -RecipientTypeDetails shared | Where-Object {$_.messagecopyforsentasenabled -eq "" }
If you have to return all shared mailboxes that has the Sent Items Copy enabled:Get-EXOMailbox -RecipientTypeDetails shared | Where-Object {$_.messagecopyforsentasenabled -eq "true" }
Take the selection of the shared mailboxes that don’t have the Sent Items Copy enabled yet and combine that with the Set-Mailbox command that enables both Sent Items Copy attributes:
Get-EXOMailbox -RecipientTypeDetails shared | Where-Object{$_.messagecopyforsentasenabled -eq ""} | Set-EXOMailbox -MessageCopyForSendOnBehalfEnabled $true -MessageCopyForSentAsEnabled $true
No comments:
Post a Comment