Solved

Exchange mailbox stats. need to get the results in MB rather than bytes.

Posted on 2011-02-23
3
428 Views
Last Modified: 2012-05-11
Hi,

Exchange mailbox stats. need to get the results in MB rather than bytes.

I have the below code from a expert. Can this be able to fetch in MB

Get-MailboxStatistics -Database "EX07\First Storage Group\Mailbox Database" | select displayname, totalitemsize | export-csv c:\result.csv

Regards
Raja
0
Comment
Question by:bsharath
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 53

Expert Comment

by:Dhaest
ID: 34967839
Why don't you convert the bytes to MB when you received it ?

http://technet.microsoft.com/en-us/library/ee692684.aspx
0
 
LVL 11

Author Comment

by:bsharath
ID: 34967847
I get the stats from 20,000 mailboxes. Could be useful some way within the code
0
 
LVL 53

Accepted Solution

by:
Dhaest earned 500 total points
ID: 34967878
Convert the Get-MailboxStatistics output from Bytes to MB or GB in Exchange 2007.
http://aspoc.net/archives/2007/11/07/convert-the-get-mailboxstatistics-output-from-bytes-to-mb-or-gb-in-exchange-2007/


Customizing results
This is all fine and good, but having to figure out how big a mailbox is based on the number of bytes is more math than we should have to use. Fortunately, we can convert bytes to MB by replacing the “TotalItemSize” field with

@{expression={$_.TotalItemSize.Value.ToMB()}

http://www.petri.co.il/getting-mailbox-sizes-in-powershell.htm
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

A procedure for exporting installed hotfix details of remote computers using powershell
A recent project that involved parsing Tableau Desktop and Server log files to extract reusable user queries for use in other systems. I chose to use PowerShell to gather the data, and SharePoint to present it...
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

734 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