Freigeben über


Playing with Powershell

In this post we will be talking about the very basic of using powershell to generates reports. (Please note, there would be updates to this post as and when required)
To get the different types of recipient in your ORG and their Count

Get-Recipient | group -Property RecipientType | Sort Count -Descending | Select name, Count

Name Count

--------- -----

UserMailbox 10

MailUser 7

MailContact 2

DynamicDistributionGroup 1

MailUniversalDistributionGroup 1

 

 

Distribution of Mailbox Among various Mailboxes in your org

Get-Mailbox | group -Property Servername | Sort Count -Descending | Select name, Count

 

 

To get the list of recipients who actually have a mailbox

Get-Recipient | Where{$_.recipientType -eq "UserMailbox"}

 

I know, you might think why should I use this rather I will use Get-Mailbox right ??? Correct, but since this post is regarding Powershell wanted to show how we can use the "Where" clause to achieve the same !

 

 

Get the list of Mailbox that have an archive and that too we are only interested in Local archive not remote

Get-Mailbox | Where{$_.ArchiveStatus -eq "Active" -and $_.ArchiveState -eq "Local"}

 

 

Please do let know what kind of clauses, powershell scripts etc that you want to be discussed, If possible will create a post for the same.

Comments

  • Anonymous
    August 12, 2015
    Harry,

    We ALL had to start somewhere.
  • Anonymous
    August 13, 2015
    Thanks
    disregard some idiots around here:)
  • Anonymous
    August 13, 2015
    Thanks for the support. Tell me what stuff you need to know and would blog on that :)