Skip to main content

Balancing / Dispersing Mailboxes between Exchange 2010 Databases

I recently needed a script that would balance mailboxes between databases. Similar scripts exist, but I wanted one that specifically met all of my requirements. This script is very simple, but does exactly what I need. For now at least…
My needs
  • The ability to maintain the number of users across an Exchange 2010 DAG with up to 30,000 users. Size of the mailboxes wasn’t that important as there is only one quota across all mailboxes.
  • The ability to exclude certain mailboxes, in my case Symantec Enterprise Vault Archiving Mailboxes.
  • The ability for the script to be scheduled with ease. A lot of the scripts that exist, generate a “move list”, I didn’t want that.
  • E-Mail status reports after processing.
Logic
The script will discover the number of users, then discover the number of databases. It will then find the optimum number of users per database and create a move request ensuring that all but one of the databases contain the same number of users. It will then send an e-mail detailing what it’s done.
There script will skip mailboxes with a display name beginning with “GIG_EVMailbox” you can change that string to skip what you need it to skip.
The script in action
image
The Powershell script is available here…. https://docs.google.com/open?id=0B7OxVSEjnHfickV3aVN4RWw4ZTg .
I hope you find it useful.

Comments

Popular posts from this blog

Convert Linked Mailboxes to User Mailboxes in Bulk

My organisation has gone through a massive migration project to unify Active Directories and Exchange organisations. As a result of these migrations a lot of mailbox migrations have resulted in a lot of mailboxes ending up as linked mailboxes even though their not.The official TechNet article on this explains how to disconnect the mailbox and re-attach it to the user account correctly as a user mailbox. http://technet.microsoft.com/en-us/library/bb201749(EXCHG.80).aspxAnother way to make this appear to be corrected is to manually change the “Recipient Type” AD property on the affected mailboxes. This though, is unsupported.Using the official method from Microsoft results in the loss of any specific mailbox information such as SMTP, x400 & x500 addresses, mailbox sizes and any other individual mailbox settings.Only e-mail addresses and mailbox sizes were important to me (I must admit, I forgot about mailbox sizes at first). I came up with the script below that would properly conver…

Creating a Windows PE 3 Bootable USB device

I’ve used Windows PE for a long time. And I’ve grown to love it. It’s an extremely useful tool, not just for OS installation, but for diagnostics.Since there’s a version of WinPe for x64 & x86 (& itanium) I like to keep both x64 & x86 on my USB stick. Essentially copying the each version to the root of the USB stick as needed. Meaning at any one time I have three copies of WinPE on my USB stick. Other applications I copy directly to my USB stick, so that I don’t have to remount the image every time i need another application added.Shortly after Windows 7 was released came a new version of WinPE, WinPE 3.0 on the Windows Automated Installation Kit.Preparing the USB stick. You’ll need to prepare the USB stick. To do this open a command prompt using Run As Administrator and use the following commands.diskpart
list disk
select disk 7
clean
create partition primary
select partition 1
active
format quick fs=fat32
assign
exitMake sure…

Duplicate legacyExchangeDN Properties

Had a case recently that wasn’t immediately obvious to resolve.We had reports of a user that no one was able to e-mail due to duplicate addressing. At first look there was no duplicate addresses on the object. We were receiving the following NDR’sThere is a problem with the recipient's e-mail system. More than one user has this e-mail address. The recipient's system administrator will have to fix this. Microsoft Exchange will not try to redeliver this message for you. Please provide the following diagnostic text to your system administrator and then try resending the message after the problem has been resolved.IMCEAEX-_O=ORGNAME_OU=EXCHANGE+20ADMINISTRATIVE+20GROUP+20+28FYDIBOHF23SPDLT+29_CN=RECIPIENTS_CN=NAME+2ESURNAME@DOMAIN.SUFFIX
#550 5.1.4 RESOLVER.ADR.Ambiguous; ambiguous address ##Further investigations showed that there was a problem with the way that the user was shown in the Exchange Address Books. It seemed as though the object was being confused with another …