The power of PowerShell

To quote a colleague of mine:

“Be one with PowerShell”.

This statement holds near and dear to me.

Learning PowerShell has been a life changing skill, one which has paid many dividends. Having an understanding of PowerShell enables you to work with almost all of Microsoft’s services / products… and more importantly, understanding PowerShell lets you learn about a product quickly… it allows you to address problems at scale, on the spot, and get things done with relative ease.

There is practically a cmdlet for everything in the m365/o365 suite (except for intune, last time I checked). Therefore, understanding how to use get-help and Microsoft docs lets you administer things like Exchange Online, Skype for Business, SharePoint Online, and AzureAD with relative ease.

Product knowledge is without a doubt of great importance, understanding the fundamentals and principals behind the technology you’re administering is certainly helpful. Knowing where to look, though, is king. In the age of the cloud, where everything is fluid and changing — it’s not entirely about what you know at any given moment… rather… the value comes from what you can potentially know, how fast you find it, how quickly you can learn it and what skills you have to ACT on the findings.

PowerShell is the backbone of enablement, onboarding and administration.

Having been with one of most decorated Microsoft partners in the U.S. for nearly 3 years now, I’ve impacted some of the largest customers in the world. Having played a critical role on multiple projects has provided me insight into the things I’ve stated above. That is to say.. PowerShell is truly the great equalizer. Know it well. Know its inner workings and the world is yours.

How to fix “RequestExpiryCleanup” Error in a Hybrid Exchange Environment.

A Hybrid Exchange Environment is in place and you are having problems migrating a mailbox from Exchange Online (Office 365 Email) back to Exchange on premises.

When you attempt to off board the user, the move request takes an unusual amount of time to validate. Once it finally validates, the move request is generated but the request gets stuck at 0% and shows a StatusDetail of “RequestExpiryCleanup”.

Things You’ve Already Tried:
You have attempted to remove the move request and have created a new off boarding request a few times. However, the problem still persists.

Do a targetless move request from within Exchange Online. This will move the mailbox into a different database within Exchange Online. Here’s how:

1. Connect to Exchange Online PowerShell

2. Remove the problematic move request and migration user:

Remove-MigrationUser -Identity
Remove-MoveRequest -Identity

3. Perform the targetless move request (move the mailbox to a new DB in EXO)

New-MoveRequest -Identity

4. Monitor the move request, until completion:

Get-MoveRequestStatistics -Identity

Once the new move request finishes, go back into the Exchange Admin Center via the O365 portal (or use PowerShell) and generate a new off boarding request.

Hope this helps!