Office 365: Clearing Mailbox Stops At 30 GB

Recently at work, we needed to make a shared account for some API credentials to a service. Not wanting to tie them to any individual user, I thought we could create a new proxy address, assign it to a shared mailbox that all relevant people had access to, and sign up with that. I quickly identified an old, largely forgotten shared mailbox that seemed to fit the bill nicely, and it only took a few moments for someone with the proper rights in Office 365 to assign the additional proxy address.

The problem came when I actually opened up the shared mailbox. When signing up for the new service, I would need to receive an email that would allow me to complete the signup process. Unfortunately, this shared mailbox had 50 GB of storage allocated and somehow contained 100 GB of content; it had basically been used for a handful of things in the past that were no longer relevant but which had continued to regularly pump email into it.

As a result, I set about what I errantly assumed would be the simple task of cleaning out the mailbox given that none of the old content was important to anyone. Office 365 webmail even provides a nice faculty for this by navigating to:

Settings > General > Storage

This gives a nice breakdown of each folder in the mailbox, sorted by the largest, and gives a quick actions for clearing out all of the content or content older than a given timeframe. The downside is that, under the hood, the service is still deleting messages one-by-one, even if you opt to simply clear out the entire folder. This makes the process glacially slow. I went on to do other work, periodically tabbing back to the shared mailbox to check in the progress (which annoyingly necessitates a refresh.)

After a few hours, though, I quickly noticed that progress had stopped altogether. I had been able to get the mailbox down from 100 GB to 70 GB, but absolutely nothing was happening beyond that, even after waiting overnight. At this point we had moved the alias to a different shared mailbox and proceeded with what we needed for the new registration, so it was more a matter of just wanting to make this mailbox potentially useful again.

One of my coworkers threw out the idea that maybe Recover Deleted Items was the culprit. For the uninitiated, there are several layers of content deletion in an Office 365 mailbox. When you normally delete content, it will go to the Deleted Items folder. If you empty the Deleted Items folder or opt to “permanently” delete something from another folder, it will actually go to Recover Deleted Items rather than being fully deleted. This is just an extra layer of protection to ensure that something important can’t be irrevocably deleted on a whim. Content in Recover Deleted Items will generally persist for 7 days (though this is customizable by policy) before actually being deleted. (Note that there’s actually another layer beyond Recover Deleted Items that’s completely transparent to the end user for Litigation Hold.)

The problem is that Recover Deleted Items has limits of its own:

In Exchange Online, the default limits for the Recoverable Items quota are: a soft limit of 20 GB and a hard limit of 30 GB. However, the quotas for the Recoverable Items folder are automatically increased to 90 GB and 100 GB, respectively, when you place a mailbox on Litigation Hold or In-Place Hold or if a Microsoft 365 or Office 365 retention policy is applied to the mailbox.

The good part is that users do have agency to empty content from Recover Deleted Items if they so choose, though it doesn’t show up in the normal Storage section of settings that I mentioned earlier; users have to go to their Deleted Items folder and then click the link for Recover Deleted Items. I hopped to that section of the shared mailbox and told it to delete everything. It was once again glacially slow, but at least something was happening for a change:

Once this section was cleared out, I was able to go back to the Storage area and once again start pruning mail. It was a process I needed to repeat several times since, yet again, the remaining 70 GB of content wouldn’t all fit in the 30 GB limit of Recover Deleted Items.