Scenario: You need to find the Distribution Groups that a specific user is a manager of.
Resolution: Run the following in Exchange PowerShell:
get-distributiongroup -resultsize unlimited | Where {$_.Managedby -like “*username“}
Scenario: You need to find the Distribution Groups that a specific user is a manager of.
Resolution: Run the following in Exchange PowerShell:
get-distributiongroup -resultsize unlimited | Where {$_.Managedby -like “*username“}
Scenario: You have a user complaining that they cannot access mail through Outlook 2011. When you search the Exchange servers IIS logs, you see a bunch of HTTP 500 responses provided by the Exchange server only for that user. You also found out that this user is on travel.
Resolution: Instead of changing the timezone to reflect the area the user was in, the user adjusted the current time. Changing the timezone to where they were at or adjusting the time back to the current time of the original time zone resolved this issue.
Scenario: Customer emails a recipient and receives this error message:
The recipient’s mailbox is full and can’t accept messages now. Please try resending this message later, or contact the recipient directly.#554-5.2.2 mailbox full 554 5.2.2
STOREDRV.Deliver.Exception:QuotaExceededException.MapiExceptionShutoffQuotaExceeded; Failed to process message due to a permanent exception with message Move/Copy messages failed. 16.55847:4000000
The sender may also receive the following error message in Outlook:
The message store has reached its maximum size. To reduce the amount of data in this message store, select some items that you no longer need, permanently (Shift + Del) delete them.
The sender may also receive the following error message in Outlook Web App:
The action couldn’t be completed. An error occurred on the server.
Cause: This occurs if the items in the Recoverable Items folder of the recipient have exceeded the default quota of 30 gigabytes (GB).
Resolution: Administrator needs to increase recoverable items quota for the recipients by using this one liner: set-mailbox -recoverableitemsquota 50GB -UseDatabaseQuotaDefaults $false
New CMDlet: Clean-MailboxDatabase in Exchange 2013
Command is Update-StoreMailboxState
Examples:
This updates the mailbox state for a mailbox located on the mailbox database DB01
Update-StoreMailboxState -Database DB01 -Identity GUIDof DB
Scenario: You have a list of mailboxes that you do not know if they still exist or not. Instead of checking one by one, you can script this.
In my users.csv I have a header with Name that contains all of the aliases underneath.
$users = Import-csv C:users.csv
$users | ForEach { $exist = [bool](Get-mailbox $_.name -erroraction SilentlyContinue); Write-host “$Exist $_.Name”}
Scenario: You are using PowerShell for Active Directory to export a list of members in a group, but you receive this error:
Get-ADGroupMember : The size limit for this request was exceeded
Work Around: Run this following command:
$grp = get-adgroup groupname -properties members
$grp.members | get-aduser | Select Name | Export-csv C:\temp\exportsgroupmembers.csv
Scenario: A user has found a missing mobile device. While the device was missing, the user has initiated a remote wipe on it. We want to prevent the remote wipe from occurring when the phone is powered back on.
Solution: Run this via Exchange Management Shell:
clear-activesyncdevice <identity> -cancel:$true
Note: I tried running the -cancel $true as stated in the article, but I received this error:
A positional parameter cannot be found that accepts argument ‘True’. I replaced it with -cancel:$true
Within Exchange Powershell, change the Directory to the scripts directory of your Exchange Install Location. Run either of the following commands to rebuild the content index for a single database or all databases on a single server:
.resetsearchindex.ps1 -force <database>
or
.resetsearchindex.ps1 -force -all
The Exchange store uses write-ahead transaction logs and checkpoint files to help prevent data loss. Transaction logs record all the changes that have been committed to the in-memory database, while checkpoint files record which logged transactions have been written to the on-disk database files.
To check the last log file that has been written to the on-disk database, you can run the following in Exchange PowerShell. It will provide the Checkpoint file that was last committed. Any log files after that checkpoint file have not been committed to the on-disk database yet, where any log files prior have already been written and can be safely removed if manual purge is required.
Powershell: ESEUTIL /MK C:FilePathDatabaseLogsE00.chk
Results:
Extensible Storage Engine Utilities for Microsoft(R) Exchange Server
Version 14.03
Copyright (C) Microsoft Corporation. All Rights Reserved.
Initiating FILE DUMP mode…
Checkpoint file: E:DatabaselogsE00.chk
LastFullBackupCheckpoint: (0x0,0,0)
Checkpoint: (0x4E1617,80,0) <– The log file may look like E00004E1617.log in the logs directory.
FullBackup: (0x4D48C3,173,1E1)
FullBackup time: 05/18/2014 06:01:36
IncBackup: (0x4E0CB3,447,48)
IncBackup time: 05/23/2014 05:04:41
Signature: Create time:06/05/2012 15:17:03 Rand:89681821 Computer:
Env (CircLog,Session,Opentbl,VerPage,Cursors,LogBufs,LogFile,Buffers)
( off, 2027, 101350, 16384, 101350, 2048, 2048,1804596)
Operation completed successfully in 0.32 seconds.
Reference