Monday, July 14, 2008

Useful Exchange Management Shell Cmdlets

Convert a legacy Exchange 2003 "resource" into a room mailbox in Exchange 2007

Move the mailbox to an Exchange 2007 server
Run: set-mailbox [MailboxName] –type Room
Then run: set-mailboxcalendarsettings [MailboxName] –AutomateProcessing AutoAccept

Configure the conference room resource mailboxes to remove attached files from meeting requests

Get-Mailbox - RecipientTypeDetails RoomMailbox Set-MailboxCalendarSettings -DeleteAttachments:$true

Get a list of Exchange ActiveSync users

$mbx = get-casmailbox where {$_.hasactivesyncdevicepartnership -eq $true -and $_.identity -notlike "*CAS_{*"} ; $mbx foreach {$name = $_.name; $device = get-activesync devicestatistics -mailbox $_.identity; $device foreach {write-host $mbx.name, $_.devicemodel, $_.devicephonenumber, $_.deviceid, $_.FirstSyncTime, $_.LastSuccessSync} }

Get details of single EAS mailbox

Get-ActivesyncDeviceStatistics -mailbox user@domain.com

An inappropriate message that has the subject line of exchange is sent to all users on the Exchange server 2007 mailbox server named Exch1. You need to delete this message from all the mailboxes.

Create a new mailbox named TempMailbox that has a folder named Export. Run the Get-Mailbox -Server Exch1 Export-Mailbox -TargetMailbox TempMailbox -TargetFolder Export -SubjectKeywords "Exchange" -DeleteContent cmdlet.

Get list of all user mailboxes with a list of email addresses attached to each user.

get-mailbox select-object name, alias, primarySmtpAddress Export-Csv C:\mailboxes.csv -NoTypeInformation

4 comments:

Anonymous said...

Can anyone recommend the best Network Management utility for a small IT service company like mine? Does anyone use Kaseya.com or GFI.com? How do they compare to these guys I found recently: N-able N-central system monitoring
? What is your best take in cost vs performance among those three? I need a good advice please... Thanks in advance!

Viagra Online said...

Excellent information my friend, too bad I just recently discover your blog, a lot of this could served me back then.

Alex said...

MS Exchange is the very interesting software. But sometimes it has unpleasant problems and only some tools may work out theirs. The next one is one of the best in this sphere and has many good facilities for working out most every issues related to ms exchange - recover edb file.

iservepharmacy said...

Hey thanks! I was looking for this for a project that I have at my work. Keep it up the good work and also keep posting.