Delete a mailbox using PowerShell

In the last week, I got a couple of emails from folks who simply wanted to know how to delete a mailbox from Exchange Labs.  They had listed the available cmdlets, and tried the one that looked right, but they got an error message when they tried it…  here is what happened…

Get-Command -CommandType All

This produces a list of the available cmdlets on the Exchange Labs PowerShell interface.  One of the cmdlets is ‘remove-mailbox’.

If you simply try ‘remove-mailbox <mailbox name>‘, you will get an error message.  This is primarily because there is a tie between the Exchange mailbox and the LiveID that is associated with it. 

What you actually need to enter is:

remove-mailbox <mailbox name> -DisableWindowsLiveID -Confirm:$false

So, I’ll not hold you back any more, you might have mailboxes to delete!


Technorati Tags: ,

2 Responses to Delete a mailbox using PowerShell

  1. Krzysztof says:

    Hi,But what about situation when I need to temporary disable mailbox??

  2. US LiveAtedu says:

    @KrzysztofComing very soon starting in Q1 of next calendar year we hope.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: