Solved

PowerShell-Exchange 2010-Mailbox sze, User name, and Mailbox DB

Posted on 2012-03-28
4
692 Views
Last Modified: 2012-05-04
I have just joined here, and they dont have any mailbox limit, so i am trying to generate a report for all the users (i.e. around 400), to get there username, with there mailbox size and in the database they are associated with, because over here they have couple of different databases in different drives.
So would it possible i can generate a report into a CSV file.

When i open up powershell, if i run a command under c:\windows\system32...it says i dont have permissions? so would it be ok if i run the command just under c:\, make up a folder and generate the report in that folder.

thanks....
0
Comment
Question by:Leo
  • 2
4 Comments
 
LVL 18

Expert Comment

by:suriyaehnop
Comment Utility
Normally, you can use EMS (Exchange Management Shell). Try below code:

Get-Mailbox -ResultSize Unlimited | Select-Object alias,IssueWarningQuota,Database,@{Name='Size (MB)';expression={$mbx = Get-MailboxStatistics $_.alias; $mbx.totalitemsize.value.toMB() }},@{Name='Storage Limit Status';expression= { $mbx = Get-MailboxStatistics $_.alias; $mbx.StorageLimitStatus }} >c:\status.csv

Open in new window

0
 
LVL 5

Assisted Solution

by:duraswitch
duraswitch earned 500 total points
Comment Utility
First, make sure you open the Exchange Managment Shell, and not regular Powershell.  if you are a member of the Organizer Management group you shouldn't run into any permissions problems.  As for the command, run this:

get-mailbox -resultsize unlimited |select displayname,database | export-csv c:\mailboxes.csv -NoTypeInformation
0
 
LVL 8

Accepted Solution

by:
Leo earned 0 total points
Comment Utility
0
 
LVL 8

Author Closing Comment

by:Leo
Comment Utility
Found the answer as i was typing my response.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
This process describes the steps required to Import and Export data from and to .pst files using Exchange 2010. We can use these steps to export data from a user to a .pst file, import data back to the same or a different user, or even import data t…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
Windows 8 comes with a dramatically different user interface known as Metro. Notably missing from the new interface is a Start button and Start Menu. Many users do not like it, much preferring the interface of earlier versions — Windows 7, Windows X…

772 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

13 Experts available now in Live!

Get 1:1 Help Now