Mailbox stores, which are also called mailbox databases, are where mailboxes are located. There are quite a few configuration settings for mailbox stores which are beyond the scope of this chapter, but going through the ESM GUI when manually creating a mailbox store should give you an idea of what can be configured.
Depending on the version (Standard or Enterprise) of Exchange, you can have up to four storage groups per server and up to five mailbox stores per storage group. ESM enforces these limits, but it is possible to directly modify Active Directory to exceed these limits. If you create more databases or storage groups than allowed, the additional databases will not mount.
Mailbox stores are represented in Active Directory by the msExchPrivateMDB class. This class is not as simple as some of the other classes used by Exchange. In addition, several of the attributes hold binary data, so working directly with these Active Directory objects can be difficult via VBScript or command-line methods. One of the more notable attributes of the mailbox store objects is a back-link attribute called homeMDBBL. This multivalued attribute links back to all of the user objects that have mailboxes in this mailbox store.
Using a graphical user interface
- Open the Exchange System Manager (ESM) snap-in.
- In the left pane, browse to the server and storage group where you want to create a new mailbox store.
- Right-click on the storage group and select New -> Mailbox Store.
- Enter a name for the store, configure the settings on each tab, and click OK.
- When prompted to mount the store, click Yes.
Using VBScript
' This code creates a Mailbox Store.' ------ SCRIPT CONFIGURATION ------
strServer = "<Exchange Server>" ' e.g., ExchServer2
strSGName = "<Storage Group Name>" ' e.g., SG1
strMailStoreName = "<MailBox Store Name>" ' e.g., DB1
' ------ END CONFIGURATION ---------' Find Storage Group URL
strSearch = "CN=" & strSGName & ","
set objSrv = CreateObject("CDOEXM.ExchangeServer")
objSrv.DataSource.Open strServer
for each strSg in objSrv.StorageGroups
if (instr(1,strSg,strSearch,1)>0) then strSGUrl = strSg
next
' Generate Mailbox Store URL
strMBUrl = "LDAP://CN=" & strMailStoreName & "," & strSGUrl
' Create/configure Mailbox Store and save it
set objMb = CreateObject("CDOEXM.MailBoxStoreDB")
objMb.DataSource.SaveTo strMBUrl
' Mount DataBase
objMB.Mount
Wscript.Echo "Successfully created mailbox store."
Tags: mailbox store