Power Shell Exchange 2013

I get few Power Shell commend for Exchange 2013

#How to find which mailboxes are over quota limits

Get-Mailbox -Database db1 | Get-MailboxStatistics | Select-Object DisplayName,StorageLimitStatus

Get-MailboxDatabase | Get-MailboxStatistics | Where-Object {$_.StorageLimitStatus -match ‘IssueWarning|ProhibitSend|MailboxDisabled’}

#Get Exchange Online Mailbox Size in GB

Get-Mailbox -ResultSize Unlimited

Get-MailboxStatistics | Select DisplayName,StorageLimitStatus

Get-Mailbox -ResultSize Unlimited | Get-MailboxStatistics | Sort-Object TotalItemSize -Descending | Select-Object DisplayName,TotalItemSize -First 30

Get-MailboxDatabase | Select-Object Name,IssueWarningQuota,ProhibitSendQuota,ProhibitSendReceiveQuota | Sort-Object Name | Export-Csv –Path .\DatabaseLimits.csv

Get-Mailbox | Select-Object DisplayName,Database,IssueWarningQuota,ProhibitSendQuota,ProhibitSendReceiveQuota | Sort-Object DisplayName | Export-Csv –Path c:\PST\MailboxLimits.csv

remove pictures
Get-MailboxDatabase | Get-Mailbox | Set-Mailbox -RemovePicture
Update-GlobalAddressList -Identity “Default Global Address List”

[Int] $intSent = $intRec = 0

Get-TransportServer | Get-MessageTrackingLog -ResultSize Unlimited -Start “11/01/2015” -End “12/01/2015” -Sender “user@companyname.com” -EventID RECEIVE | ? {$_.Source -eq “STOREDRIVER”} | ForEach { $intSent++ }

Get-TransportServer | Get-MessageTrackingLog -ResultSize Unlimited -Start “11/01/2015” -End “12/01/2015” -Recipients “user@companyname.com” -EventID DELIVER | ForEach { $intRec++ }

Write-Host “E-mails sent: “, $intSent

Write-Host “E-mails received:”, $intRec

Get-MessageTrackingLog -ResultSize Unlimited -Start “11/01/2015” -End “12/01/2015” | where{$_.recipients -like “tandersson@companyname.com”} | select-object Timestamp,SourceContext,Source,EventId,MessageSubject,Sender,{$_.Recipients} | export-csv C:\pst\ExchangeLogRecipientcTom.txt

Get-MessageTrackingLog -ResultSize Unlimited -Start “11/01/2015” -End “12/01/2015” | where{$_.sender -like “tandersson@companyname.com”} | select-object Timestamp,SourceContext,Source,EventId,MessageSubject,Sender,{$_.Recipients} | export-csv C:\ExchangeSend.txt