Solved

Message tracking Exchange 2007 - Distribution groups

Posted on 2010-08-31
4
878 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
Comment Utility
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
Comment Utility
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
Comment Utility
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
Comment Utility
Thanks!
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Utilizing an array to gracefully append to a list of EmailAddresses
Create and license users in Office 365 in bulk based on a CSV file. A step-by-step guide with PowerShell script examples.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

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

11 Experts available now in Live!

Get 1:1 Help Now