Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4161
  • Last Modified:

Delete Mailbox for deleted in AD user (Exchange 2010)

Hi All,

System :
Server 2008 as DC
Exchange Server 2010 as mail server

I have a little mistake, i deleted user in AD before deleting mailbox. Now this mailbox is not in mailboxes list and not in Disconnected mailboxes, but i can see this mailbox  from PowerShell. If i try to delete this mailbox i have this message :

[PS] C:\Windows\system32>Remove-Mailbox -Identity domain\user
The operation couldn't be performed because object 'domain\user' couldn't be found on 'dc.domain.yes'.
    + CategoryInfo          : NotSpecified: (0:Int32) [Remove-Mailbox], ManagementObjectNotFoundException
    + FullyQualifiedErrorId : 2F1637E6,Microsoft.Exchange.Management.RecipientTasks.RemoveMailbox
Because this user is deleted from AD.

Please help me to delete this mailbox from Exchange 2010 without restore object(user) to AD.

Thanks!
0
Tamooz
Asked:
Tamooz
2 Solutions
 
setasoujiroCommented:
The mailbox is kept for retention, if the retention period is over, it should be gone.
0
 
Yagya ShreeCommented:
In the Exchange Management Console, right-click and select disable mailbox or in the Exchange Management Shell, use the Disable-Mailbox cmdlet:

Disable-Mailbox -Identity mailboxname -Confirm:$false
0
 
TamoozAuthor Commented:
30 days?
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
setasoujiroCommented:
yes
0
 
TamoozAuthor Commented:
Disable-Mailbox -Identity mailboxname -Confirm:$false
It's steel check in AD, i have this message

[PS] C:\Windows\system32>Disable-Mailbox -Identity mailboxname -Confirm:$false
The operation couldn't be performed because object 'mailboxname' couldn't be found on 'DC.domain.yes'.
    + CategoryInfo          : NotSpecified: (0:Int32) [Disable-Mailbox], ManagementObjectNotFoundException
    + FullyQualifiedErrorId : DCC65151,Microsoft.Exchange.Management.RecipientTasks.DisableMailbox
0
 
TamoozAuthor Commented:
So, i have no way to delete this mailbox before the end of retention period?
0
 
SubsunCommented:
You need to run Clean-MailboxDatabase to view the disconnected mailbox.
Clean-MailboxDatabase MBD01

Use Remove-StoreMailbox to permanently Delete a Disconnected Mailbox
Ref : http://technet.microsoft.com/en-us/library/gg181092%28v=exchg.141%29.aspx
0
 
TamoozAuthor Commented:
Thank you Subsun! It's worked.

1) Clean DB
Clean-MailboxDatabase DB4

2) Check the Identity number of mailbox
Get-MailboxStatistics -Database DB4 | Select DisplayName, Identity | Sort-Object DisplayName  | Format-Table

3) Remove mailbox
Remove-StoreMailbox -Database DB4 -Identity "457465d4-6245-48f4-ab45-98573798cf0f" -MailboxState Disabled

Thank you All for help!!!
0
 
TamoozAuthor Commented:
Thanks!!!
0

Featured Post

Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now