Solved

exchange 2007/2010 mailbox sizes

Posted on 2010-11-09
7
629 Views
Last Modified: 2012-06-21
Is there a way in powershell I can use an input text list of users/aliases to feed in and output mailbox sizes and item counts to a CSV file?
0
Comment
Question by:ENTPF
  • 4
  • 3
7 Comments
 
LVL 49

Expert Comment

by:Akhater
ID: 34095813
import-csv c:\users.csv | get-mailboxstatistics | select-object displayname,itemcount,totalitemsize | export-csv c:\mailboxstat.csv
0
 

Author Comment

by:ENTPF
ID: 34096486
getting nothing in the output file.  
0
 
LVL 49

Expert Comment

by:Akhater
ID: 34096503
what do you have in your input file ?
what is the output of import-csv c:\users.csv alone
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 

Author Comment

by:ENTPF
ID: 34096637
just usernames in the input file.  
output file does not show anything even there is no command in between import and export.
0
 
LVL 49

Expert Comment

by:Akhater
ID: 34096649
import-csv c:\users.csv | get-mailboxstatistics

try this  alone any output?

0
 

Author Comment

by:ENTPF
ID: 34096690
Get-MailboxStatistics : The input object cannot be bound to any parameters for
the command either because the command does not take pipeline input or the inpu
t and its properties do not match any of the parameters that take pipeline inpu
t.
At line:1 char:74
0
 
LVL 49

Accepted Solution

by:
Akhater earned 500 total points
ID: 34096781
ok


1. in the top of your csv file add name so it looks something like

name
administrator
ENTPF
AKhater

2. change the code to

import-csv "C:\userscsv" | foreach{ Get-MailboxStatistics $_.name |  select-object displayname,itemcount,totalitemsize} | Export-Csv c:\t.txt
0

Featured Post

Is Your AD Toolbox Looking More Like a Toybox?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

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

This script can help you clean up your user profile database by comparing profiles to Active Directory users in a particular OU, and removing the profiles that don't match.
How to resolve IMCEAEX NDRs in Exchange or Exchange Online related to invalid X500 addresses.
In this video we show how to create a Contact 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 Recipients >> Contact ta…
In this video we show how to create a Resource Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: Navigate to the Recipients >> Resources tab.: "Recipients" is our default selection …

820 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