17.14. Reconnecting a Deleted Mailbox
You want to reconnect a mailbox in the Exchange Store to a user object.
Using a graphical user interface
Open the Exchange System Manager (ESM) snap-in.
In the left pane, browse to the mailboxes container of the server, storage group, and database where you want to reconnect a mailbox.
In the right pane, scroll down until you find the mailbox you wish to reconnect. The mailbox should have a small red circle with a white X on it indicating it is disconnected.
Right-click the mailbox and select Reconnect.
Choose a user object in the directory you wish to reconnect this mailbox to.
A dialog box indicating the Reconnect Operation has completed successfully should pop up. Click OK.
' This code reconnects a mailbox to a user. ' ------ SCRIPT CONFIGURATION ------ strComputer = "
<Exchange Server>" ' e.g., ExchServer2 strUser = "
<Userid>" ' e.g., jsmith strMailbox = "
<Mailbox Alias>" ' e.g., jsmith ' ------ END CONFIGURATION --------- set objWMI = GetObject("winmgmts:\\" & strComputer & _ "\root\MicrosoftExchangeV2") set objDiscMbx = objWMI.ExecQuery("Select * from Exchange_Mailbox WHERE " _ & "MailboxDisplayName='" & strMailbox & "'",,48) for each objMbx in objDiscMbx objMbx.Reconnect strUser next Wscript.Echo "Successfully reconnected mailbox."
When you tell the system to delete an Exchange mailbox, it isn't really deleted. It is simply disassociated or disconnected from the user object. These mailboxes are referred ...