Solved

get-Messagetrackinglog script

Posted on 2012-03-28
5
1,926 Views
Last Modified: 2012-04-16
Hi Team,

I need to know the script which will give the Mailflow for the month in our exchange servers.
I have edge server and need to track the mailflow based on the Sender ip and i need specifically counts.

Like this how many numbers are from this specific sender id and i need each count of the senderip or client ip.

The below command i tried to get for one day but not able to get the counts of each senderemailaddress or sender id. Kindly suggest

get-messagetrackinglog -start "03/26/2012 00:00:01" -end "03/26/2012 23:59:59" -eventid "receive" -resultsize unlimited | Export-Csv
0
Comment
Question by:sekar_raj32
[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
  • 3
  • 2
5 Comments
 
LVL 42

Assisted Solution

by:sedgwick
sedgwick earned 500 total points
ID: 37780691
do u have sender email/username?

try the following (replace "sender@domaincom"):

Get-MessageTrackingLog -start "03/26/2012 00:00:01" -end "03/26/2012 23:59:59" -Sender "sender@domaincom"
0
 
LVL 7

Author Comment

by:sekar_raj32
ID: 37781684
Let me explain clearly.

If i run the command it will give all the details like, sender id, client id and etc..


But i want to count the senderid and client id. For ex

If i get the report as

a@test.com
b@test.com
c@test.com
a@test.com

for this i need the count like

a@test.com = 2
b@test.com = 1
c@test.com = 1

Like this i need to get a count details based on senderid or client ip

Thanks
0
 
LVL 42

Accepted Solution

by:
sedgwick earned 500 total points
ID: 37782110
the following code will group all results by senderid (you can choose to group them by clientid instead).

run this code and post the output and we'll keep from there to export the reault to csv.

get-messagetrackinglog -start "03/26/2012 00:00:01" -end "03/26/2012 23:59:59" -eventid "receive" -resultsize unlimited | Group-Object senderid

Open in new window

0
 
LVL 7

Author Comment

by:sekar_raj32
ID: 37790025
When i run the command, it is just giving total number of counts but in need to get individually..

#TYPE Microsoft.PowerShell.Commands.GroupInfo
"Values","Count","Group","Name"
"System.Collections.ArrayList","4530","System.Collections.ObjectModel.Collection`1[System.Management.Automation.PSObject]",""
0
 
LVL 7

Author Closing Comment

by:sekar_raj32
ID: 37854516
partial
0

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Question has a verified solution.

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

Recently we ran in to an issue while running some SQL jobs where we were trying to process the cubes.  We got an error saying failure stating 'NT SERVICE\SQLSERVERAGENT does not have access to Analysis Services. So this is a way to automate that wit…
There are times when we need to generate a report on the inbox rules, where users have set up forwarding externally in their mailbox. In this article, I will be sharing a script I wrote to generate the report in CSV format.
To show how to create a transport rule 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 Mail Flow >> Rules tab.:  To cr…
This video discusses moving either the default database or any database to a new volume.
Suggested Courses
Course of the Month6 days, 19 hours left to enroll

622 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