Quantcast
Viewing all articles
Browse latest Browse all 19214

Remove multiple mailboxes and remove from Exchange database - Exchange 2010

Hi folks,

I wonder could anyone point me in the right direction on something!

I currently archive out multiple mailboxes at the one time each month using the following PowerShell script and it works very well: -

foreach ($i in (Import-Csv .\testmbexp.csv)) { New-MailboxExportRequest -Mailbox $i.Alias -FilePath "\\Dex02\MBExports\$($i.Alias).pst" }

I just populate the csv file with the mailbox names and when the script runs it just targets those specific mailboxes.

I then have to delete their mailbox and remove it from the Exchange database using the following command but I wonder does anyone know a PowerShell script that would allow me to delete the mailbox and remove it from the DB using a similar csv files as above.

Remove-Mailbox -Identity serc\bloggsj -Permanent $true

Any help greatly appreciated!

Regards,

Tony



Viewing all articles
Browse latest Browse all 19214

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>