how automatically disable unused mailbox????
Hi All, Can someone suggest how to automatically disable unused mailbox after say 1 or 2 months. We have an Microsoft AD 2008 and Exchange 2010,in which Some users do not use mailbox stores for long time as a result the mailbox gets full and unnecessary space is consumed on the server. Now I need a way to automatically disable these mailbox store which are not utilized for over a period and then delete them automaticlly Regards,
October 9th, 2010 1:02pm

Hi, I think that this tool can help you: http://powershellneedfulthings.blogspot.com/2009/06/cleanup-unused-exchange-2007-mailboxes.html you can learn from it’s powershell code and customize it for your needs. Netanel Ben-Shushan, IT Consultant & Trainer | Website (Hebrew): http://www.ben-shushan.net | IT Services: http://www.ben-shushan.net/services | Weblog (Hebrew): http://blogs.microsoft.co.il/blogs/netanelb | E-mail: msilforums@ben-shushan.net
Free Windows Admin Tool Kit Click here and download it now
October 9th, 2010 3:02pm

Here's an idea using the code from this example. You could schedule the following script to run on a regular basis. Mailboxes without sent items in the last 60 days would be marked for deletion. Once the deleted item retention period for the mailbox database is met, the mailbox will be deleted: $xDays = 60 $mailboxes = Get-Mailbox -ResultSize Unlimited -RecipientTypeDetails UserMailbox $mailboxes | Foreach-Object { $si= Get-MailboxFolderStatistics $_ -IncludeOldestAndNewestItems -FolderScope SentItems if($si.NewestItemReceivedDate -AND (New-TimeSpan $si.NewestItemReceivedDate.ToLocalTime()).Days -ge $xDays) { Disable-Mailbox $_ -confirm:$false } }
October 9th, 2010 3:32pm

There are many ways to do it. Depends on what you want to choose. Like others replied you can do it, if there is nothing in sent items in the last 60 days or nothing received in the last 60 days. I would do it this way as I have implemented it based on last logon to the mailbox. So, if the user does not logon to the mailbox in the last 100 days, I would assume that we disable the mailbox. However some of them have rules setup to forward all the domain mail to another mailbox (and we did not want that), therefore we communicated this to them and we run a similar script as mentioned in the blog below. -- Regards, Vik Singh -------------------------------------------------------------------------------- Please remember to click ??Mark as Answer? on the post that helps you, and to click ??Unmark as Answer? if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. "mashaleh" wrote in message news:78c2fe16-dc22-4f96-a1d2-18dc3d3b4ddb@communitybridge.codeplex.com... Hi All, Can someone suggest how to automatically disable unused mailbox after say 1 or 2 months. We have an Microsoft AD 2008 and Exchange 2010,in which Some users do not use mailbox stores for long time as a result the mailbox gets full and unnecessary space is consumed on the server. Now I need a way to automatically disable these mailbox store which are not utilized for over a period and then delete them automaticlly Regards,
Free Windows Admin Tool Kit Click here and download it now
October 9th, 2010 6:58pm

Forgot to paste the link - http://blogcastrepository.com/blogs/0_to_60_in_a_fortnight/archive/2007/05/03/when-did-a-user-last-logon-to-their-exchange-2007-mailbox-and-how-do-i-use-powershell.aspx -- Regards, Vik Singh -------------------------------------------------------------------------------- Please remember to click ??Mark as Answer? on the post that helps you, and to click ??Unmark as Answer? if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. "Vik Singh" <vikramjs@live.com> wrote in message news:6c15a27e-35da-4514-9264-55fe81722aaa@communitybridge.codeplex.com... There are many ways to do it. Depends on what you want to choose. Like others replied you can do it, if there is nothing in sent items in the last 60 days or nothing received in the last 60 days. I would do it this way as I have implemented it based on last logon to the mailbox. So, if the user does not logon to the mailbox in the last 100 days, I would assume that we disable the mailbox. However some of them have rules setup to forward all the domain mail to another mailbox (and we did not want that), therefore we communicated this to them and we run a similar script as mentioned in the blog below. -- Regards, Vik Singh -------------------------------------------------------------------------------- Please remember to click ??Mark as Answer? on the post that helps you, and to click ??Unmark as Answer? if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. "mashaleh" wrote in message news:78c2fe16-dc22-4f96-a1d2-18dc3d3b4ddb@communitybridge.codeplex.com... Hi All, Can someone suggest how to automatically disable unused mailbox after say 1 or 2 months. We have an Microsoft AD 2008 and Exchange 2010,in which Some users do not use mailbox stores for long time as a result the mailbox gets full and unnecessary space is consumed on the server. Now I need a way to automatically disable these mailbox store which are not utilized for over a period and then delete them automaticlly Regards,
October 9th, 2010 6:58pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics