Back in 2010 Microsoft published their Large Mailbox Vision whitepaper for Exchange Server 2010 to explain how customers could leverage improvements in the platform, as well as the declining cost of storage, to provide large mailboxes for their end users. Before 2010 it was common to see mailbox quotas that would be considered tiny by today’s standards, especially in comparison to the 50GB mailbox quota in Office 365.
Small mailbox quotas are a pain to administer, because you’ll be dealing with end user support cases when quota thresholds are reached, regular requests for quota increases, use of PST files to preserve mailbox data, and the recovery and compliance headaches that come with users deleting important information to stay within their quotas.
Despite the trend towards very large mailboxes Exchange Server still creates new mailbox databases with a relatively small default quota of around 2GB. You can see your mailbox quota settings by running Get-MailboxDatabase.
[PS] C:\>Get-MailboxDatabase | select name,issue*,prohibit* Name IssueWarningQuota ProhibitSendReceiveQuota ProhibitSendQuota ---- ----------------- ------------------------ ----------------- DB05 1.899 GB (2,039,480,320 by... 2.3 GB (2,469,396,480 bytes) 2 GB (2,147,483,648 bytes) DB06 1.899 GB (2,039,480,320 by... 2.3 GB (2,469,396,480 bytes) 2 GB (2,147,483,648 bytes) DB07 1.899 GB (2,039,480,320 by... 2.3 GB (2,469,396,480 bytes) 2 GB (2,147,483,648 bytes) DB08 1.899 GB (2,039,480,320 by... 2.3 GB (2,469,396,480 bytes) 2 GB (2,147,483,648 bytes)
Although 2GB is fine for new users in an organization, who may take a year or more to fill up that much space, if your email storage strategy doesn’t have any kind of archiving or retention in place to help users manage their mailbox sizes you’ll probably find that 2GB will be too small for some of today’s workers.
Choosing Mailbox Quota Thresholds
Appropriate mailbox quotas can be difficult to calculate if you have no historical data from which you can determine the trend for mailbox growth in your organization. A simple approach is run a mailbox size report, then wait one month and run another report. You can then put the data side by side and use some Excel calculations to get an idea of the average mailbox growth rate.
The mailbox size reports will also give you data about average mailbox sizes, and also help you to identify which mailboxes are much larger than average and may need special consideration. As an example from a real world customer, the following mailbox size statistics were calculated:
- The average mailbox size was 1.3GB
- 20% of mailboxes were over 2GB in size
- 10% of mailboxes were over 5GB in size
- 5% of mailboxes were over 10GB in size
- <1% of mailboxes were over 20GB in size
From that analysis it could be determined that a quota of 5GB would satisfy 90% of the user population.
The question was then how to deal with the other 10% that were over 5GB? It was decided that mailbox users who were approved for a mailbox quota of greater than 5GB would be moved to specific databases that were configured with higher quota. Mailboxes greater than 20GB would then have mailbox-specific quotas applied on a case by case basis.
Configuring Mailbox Quotas on Exchange Server Databases
Mailbox storage quotas at the database-level will be inherited by all of the mailboxes hosted on that database, except for the mailboxes that are specifically marked as exempt from the database-level quotas. In my example scenario I want to set two of the databases to use the chosen quota of 5GB. I also need to choose a warning threshold, and a prohibit send/receive threshold (the latter is important because an unattended mailbox that continues to receive email will keep growing otherwise).
Using Set-MailboxDatabase I can configure the desired quota levels. DB05 and DB06 will have the standard quota, DB07 will have the larger quota, and DB08 is going to host a journal mailbox so I’m setting it to a very high quota level.
[PS] C:\>"DB05","DB06" | Set-MailboxDatabase -ProhibitSendReceiveQuota 6GB -ProhibitSendQuota 5GB -IssueWarningQuota 4.8GB [PS] C:\>Set-MailboxDatabase DB07 -ProhibitSendReceiveQuota 12GB -ProhibitSendQuota 10GB -IssueWarningQuota 9.6GB [PS] C:\>Set-MailboxDatabase DB08 -ProhibitSendReceiveQuota 120GB -ProhibitSendQuota 100GB -IssueWarningQuota 96GB [PS] C:\>Get-MailboxDatabase | select name,issue*,prohibit* Name IssueWarningQuota ProhibitSendReceiveQuota ProhibitSendQuota ---- ----------------- ------------------------ ----------------- DB05 4.8 GB (5,153,960,960 bytes) 6 GB (6,442,450,944 bytes) 5 GB (5,368,709,120 bytes) DB06 4.8 GB (5,153,960,960 bytes) 6 GB (6,442,450,944 bytes) 5 GB (5,368,709,120 bytes) DB07 9.6 GB (10,307,921,920 bytes) 12 GB (12,884,901,888 bytes) 10 GB (10,737,418,240 bytes) DB08 96 GB (103,079,215,104 bytes) 120 GB (128,849,018,880 by... 100 GB (107,374,182,400 by...
Excluding Databases from Automatic Mailbox Provisioning
When you create or move a mailbox it is optional to select a target database. When you do not choose a target database, Exchange will select one for you using a basic load balancing approach that tries to keep approximately the same number of mailboxes on each available database.
The special databases above (DB07 and DB08) should be exempt from that automatic mailbox provisioning load balancer, because in this case we only want to move approved users to DB07, and we only want to host the journal mailbox on DB08.
[PS] C:\>"DB07","DB08" | Set-MailboxDatabase -IsExcludedFromProvisioning:$true
Setting Mailbox-Specific Mailbox Quotas
In the customer example I mentioned earlier, some mailbox users would be approved for quotas even larger than the 10GB limit that is permitted for some users. Storage quotas can be set at the mailbox level as well, using the Set-Mailbox cmdlet.
[PS] C:\>Set-Mailbox emma.gardner -UseDatabaseQuotaDefaults $false -IssueWarningQuota 15GB -ProhibitSendQuota 16GB -ProhibitSendReceiveQuota 20GB
Personally I prefer to use a script instead of manually working out what the new quota values should be, and typing out that long command. Using my Set-MailboxQuota.ps1 script I can increase or decrease a user’s mailbox quota by a percentage, or reset them back to using the database-level quotas.
[PS] C:Scripts>.Set-MailboxQuota.ps1 -Mailbox Alannah.Shaw -IncreaseByPercentage 10 ---------------------------------------- Mailbox: Alannah Shaw ---------------------------------------- Uses Database Defaults: True Warning Quota: 1.899 GB (2,039,480,320 bytes) Prohibit Send Quota: 2 GB (2,147,483,648 bytes) Prohibit Send/Receive Quota: 2.3 GB (2,469,396,480 bytes) Calculating new quotas Current warning quota: 1991680 KB New warning quota: 2190848 KB Current send quota: 2097152 KB New send quota: 2306867.2 KB Current send/rec quota: 2411520 KB New send/rec quota: 2652672 KB Setting new quotas Quotas increased by 10 percent ----------------------------------------
For more examples of the script’s use go here.
Over-Provisioning
As a final note I just want to mention over-provisioning. Some organizations choose to over-provision their mailbox databases by allowing a greater amount of potential mailbox data than the underlying disk storage will accommodate. As an example, let’s say you have 100 users on a single mailbox database, and they are given a 5GB mailbox quota. Theoretically you have up to 500GB of mailbox data to be stored in that database, plus database overheads. If the underlying storage capacity won’t fit all of that data, then you’re going to run out of disk space and experience an outage.
I don’t generally like to over-provision in this way, but I know many customers do. As long as your capacity management and monitoring will allow you to provision more storage capacity before you run out then over-provisioning can work just fine. But if buying more storage in your organization is a painful process of navigating budget approvals and purchasing procedures, then I recommend you do not take risks by over-provisioning.
Hi what if the client doesn’t want a quota so whats the best way to archive. Do we use PST archive (we have a backup issue) or do we use Ecxchange Archive?
Lev
PST is never the right answer.
What does the client want to do? Keep mail forever? Delete mail older than X days?
Keep mail in case there is an issue with product they sold 7-8 years ago
Lev
Using PSTs won’t work then because PSTs aren’t easily searchable. I would recommend you look at either using Exchange archives, or a third party archive system.
If you want to *preserve* email for that long you’ll need to also look at using In-place Hold or Litigation Hold to prevent deletion of emails for that period of time.
I have a course on these topics on Pluralsight, which you can find here:
https://www.pluralsight.com/courses/designing-deploying-exchange-2016-70-345-compliance-archiving
Hello Paul
Are u saying I can set a limit at the database level example 5gb for all.
The go to some users and set them to 10gb, and the 5 GB will not apply to them due to the mailbox override?
Yes. as long as -UseDatabaseQuotaDefaults $false is configured on the mailbox, it will use the quota settings configured on the mailbox instead of the database.
Hi Paul,
Thank you for your script it is great but it is not changed of that “Prohibit send/receive quota” not set users. When Set Prohibit Send/Receive quota and than run again it run perfectly..
How to use mailbox that “prohibit send/receive” not set users
Thank you
[PS] C:Script>.Set-MailboxQuota.ps1 -Mailbox sinan -IncreaseByPercentage 10
—————————————-
Mailbox: Sinan
—————————————-
Uses Database Defaults: False
Warning Quota: 450 MB (471,859,200 bytes)
Prohibit Send Quota: 500 MB (524,288,000 bytes)
Prohibit Send/Receive Quota: unlimited
Calculating new quotas
Current warning quota: 460800 KB
New warning quota: 506880 KB
Current send quota: 512000 KB
New send quota: 563200 KB
Send/Receive quota is unlimited and mailbox will not be modified.
One or more quota values are set to unlimited, mailbox will not be modified.
—————————————-
[PS] C:Script>.Set-MailboxQuota.ps1 -Mailbox sinan -IncreaseByPercentage 10
—————————————-
Mailbox: Sinan
—————————————-
Uses Database Defaults: False
Warning Quota: 450 MB (471,859,200 bytes)
Prohibit Send Quota: 500 MB (524,288,000 bytes)
Prohibit Send/Receive Quota: 550 MB (576,716,800 bytes)
Calculating new quotas
Current warning quota: 460800 KB
New warning quota: 506880 KB
Current send quota: 512000 KB
New send quota: 563200 KB
Current send/rec quota: 563200 KB
New send/rec quota: 619520 KB
Setting new quotas
Quotas increased by 10 percent
—————————————-
You can either customize the script to suit your needs, or change those mailboxes so they have a prohibit send/receive quota.
I’m not good scripting. 🙂 How is customize that..
Consider it a good opportunity to start learning! Many people become skilled in PowerShell by learning how to customize other people’s scripts.
I’ve made a note in my GitHub repository about it, but it’s not something I’ll be able to look at right away.
OK. Thank you for your script and answers. I’ll try to learn PowerShell Scripting..
hi again sorry You’d written in script.. “If any of the three quota settings are set to “Unlimited” then this parameter will not make any changes to the mailbox.”
Yes, that is correct. The script is designed for mailboxes that have quotas set on them. A mailbox with an unlimited quota isn’t changed by the script.
Hi Paul,
I’ve tested this script in my environment and does not work.
Should I add anything else in the syntax or some different module?
Thanks
Can you explain what “does not work” means? Do you get an error?
This is the message that is showing up:
WARNING: You cannot call a method on a null-valued expression.
The script needs to be run in the Exchange Management Shell.