Solved

produce a list of all exchange mailbox users sorted by size  and username

Posted on 2013-12-12
8
305 Views
Last Modified: 2013-12-17
i want to produce a list of all exchange users and the size of their mailboxes
i want to use username instead of display name
and need them listed from the largest to the smallest
i tried using the following command

Get-Mailbox -ResultSize Unlimited | Get-MailboxStatistics | Sort-Object TotalItemSize -Descending | Select-Object UserName,TotalItemSize -First 1500 | Export-CSV mailboxes.csv

this produces the report but the username fields are empty

if i change username to displayname it works but i dont want display name i need username
0
Comment
Question by:dougdog
  • 3
  • 2
  • 2
  • +1
8 Comments
 
LVL 19

Expert Comment

by:jss1199
ID: 39714489
change Username to Alias
0
 

Expert Comment

by:Lord_aLi112
ID: 39714492
I can confirm the username column is empty.
0
 
LVL 53

Expert Comment

by:Will Szymkowski
ID: 39714509
Unfortunately when you are piping to get-mailboxstatistics username is not a valid a member of that cmdlet. If you pipe a command you can only display the member attributes for the last piped cmdlet. As you have listed above you are not interested in Display Name but that is the only attribute that is available for Name.

Will.
0
 

Author Comment

by:dougdog
ID: 39714527
so how could i get a report with
username    mailbox size
0
Make managing Office 365 email signatures a breeze

Are you using Office 365? Having trouble trying to set up email signatures for your users? Getting stressed out managing multiple signatures? Need an easier way to manage? We have a solution for you, try the most-user friendly and powerful signature management tool on the market.

 

Expert Comment

by:Lord_aLi112
ID: 39714536
does not work with alias neither
0
 

Author Comment

by:dougdog
ID: 39714541
can confirm alias does not work
0
 
LVL 53

Accepted Solution

by:
Will Szymkowski earned 500 total points
ID: 39714548
Take a look at the following link below as it provides exactly what you are looking for. There is a little more detail than piping cmdlets. You need to create new Expressions. It is very well layed out in the document step-by-step.

http://get-exchange.blogspot.ca/2009/03/did-you-ever-needed-to-supply-list-of.html

Will.
0
 

Author Comment

by:dougdog
ID: 39714558
i will see if i can figure it out what command to use
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains in simple steps how to renew expiring Exchange Server Internal Transport Certificate.
A brief introduction to what I consider to be the best editor for PowerShell.
In this video we show how to create a mailbox database in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Servers >> Data…
The video tutorial explains the basics of the Exchange server Database Availability groups. The components of this video include: 1. Automatic Failover 2. Failover Clustering 3. Active Manager

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now