Solved

Message tracking Exchange 2007 - Distribution groups

Posted on 2010-08-31
4
885 Views
Last Modified: 2012-05-10
Hi,

I need to report how many messages (total numer of messages and size in Mb's) were received by exchange distribution groups.
I wrote some powershell script which counts only total messages sent to a distr. groups but i don't know how to add to the script info about total messages in Mb's.

Plese help.
Thanks in advance!
Get-TransportServer | foreach {get-messagetrackinglog -resultsize unlimited -server $_.Identity -start "2010-08-01 00:01" -end "2010-08-31 23:59" -EventId Expand | group-object RelatedRecipientAddress | select Name,Count} | export-csv c:\Exchange_Message_tracking_Distr_Groups.csv

Open in new window

0
Comment
Question by:pi01162
  • 3
4 Comments
 
LVL 13

Expert Comment

by:soostibi
ID: 33567260
This gives a new column TotalMBs.
Get-TransportServer |

	foreach {get-messagetrackinglog -resultsize unlimited -server $_.identity -start "2010-08-01 00:01" -end "2010-08-31 23:59" -EventId Expand | 

		Group-Object RelatedRecipientAddress | Select-Object Name, Count, 

			@{n="totalMBs"; e={[int] (($_.group | Measure-Object -Property totalbytes -Sum).sum/1mb)}}

	}

Open in new window

0
 
LVL 13

Expert Comment

by:soostibi
ID: 33567367
This is even simpler:
Get-TransportServer | ?{$_.name -eq "iqjb-exchback"} |

	get-messagetrackinglog -resultsize unlimited -start "2010-08-01 00:01" -end "2010-08-31 23:59" -EventId Expand | 

		Group-Object RelatedRecipientAddress | Select-Object Name, Count, 

			@{n="totalMBs"; e={[int] (($_.group | Measure-Object -Property totalbytes -Sum).sum/1mb)}}

Open in new window

0
 
LVL 13

Accepted Solution

by:
soostibi earned 500 total points
ID: 33567376
Sorry, this is it:
Get-TransportServer | 

	get-messagetrackinglog -resultsize unlimited -start "2010-08-01 00:01" -end "2010-08-31 23:59" -EventId Expand | 

		Group-Object RelatedRecipientAddress | Select-Object Name, Count, 

			@{n="totalMBs"; e={[int] (($_.group | Measure-Object -Property totalbytes -Sum).sum/1mb)}}

Open in new window

0
 

Author Closing Comment

by:pi01162
ID: 33574734
Thanks!
0

Featured Post

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.

Question has a verified solution.

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

This article will help you understand what HashTables are and how to use them in PowerShell.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…
Learn how to create flexible layouts using relative units in CSS.  New relative units added in CSS3 include vw(viewports width), vh(viewports height), vmin(minimum of viewports height and width), and vmax (maximum of viewports height and width).

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

12 Experts available now in Live!

Get 1:1 Help Now