GET RECEIVED/NUMBER EMAIL ON BUNCH OF DISTRIBUTION GROUPS
Hello,
I use Exchange 2007 and I would need to check whether some DistributionGroup are receiving email on oue main domain (*@company.com).
I have more than 900 Distribution Groups and I though about using the identity or SamAccountName and check whether some mails have been received.
Consulting only one Dstribution group is juste fine:
get-messagetrackinglog -resultsize unlimited -Start "10/03/2012 20:46:00" -End "10/04/2012 20:56:00" -EventID "RECEIVE" | where {$_.sender -like "*@company.com"} | ft timestamps,sender, recipients,messagesubject
--> My question are:
1) Is there any way to get that result for multiple distribution group in a nice format
2) If the above point is not possible or even if it is, Can I count the number of email recieved per distribution group?
Many thanks in advance and let me know if you need further information.
Graig
April 19th, 2012 5:02pm
Yes.
[PS] C:\admin>get-messagetrackinglog -resultsize unlimited -Start "04/19/2012 00:46:00" -End "04/19/2012 20:56:00" -Even
tID expand | where {$_.sender -like *@company.com} | ft timestamps,sender, RelatedRecipientAddress ,messagesubject -Autosize
James Chong MCITP | EA | EMA; MCSE | M+, S+ Security+, Project+, ITIL msexchangetips.blogspot.com
Free Windows Admin Tool Kit Click here and download it now
April 19th, 2012 5:31pm
Thanks James but the trick here is that I need to track only distribution lists and not the entiere items. In fact, my goals here is to know whether the distribution lists are used or not. As I have more than 900 lists I thought It would be useful to have
a nice script to track a bunch of DGs even a small amount like 10 lists.
I'm not good enought to create script with variable but I believe it would be the way to get what I need.
Thanks,
Graig
April 20th, 2012 2:14am
I have to say that the article and results are nice!
However, I need to check more than 900 distribution groups up. I do not know how to write a script that would allow me to check my distrubution lists (one by one ) and indicate me whether mails have been received or not during the last past 4 weeks.
Example of whaht I am looking forward:
Distribution.list1@company.com : 1
Distribution.list2@company.com : 18
Distribution.list3@company.com : 0
Distribution.list4@company.com : 0
Distribution.list5@company.com : 50
Distribution.list6@company.com : 32
Distribution.list7@company.com : 0
Distribution.list8@company.com : 89
Distribution.list9@company.com : 35
Thanks,
Graig
Free Windows Admin Tool Kit Click here and download it now
April 23rd, 2012 11:16am
In fact that command:
get-messagetrackinglog -Recipients:distributiongroups@company.com -start "23/03/2012 16:53:00" -End "23/04/2012 17:03:00" -eventid "receive" -resultsize 9999999 | measure-object
Which gives me:
Count : 6
Average :
Sum :
Maximum :
Minimum :
Property :
Tells me more about what I need to know.. But still how would I get a maybe nice CSV file with DG : COUNT (As the above example)??
Graig
April 23rd, 2012 11:18am
Thank you. I am getting that error message:
Format-Table : Illegal key Name
At line:1 char:99
+ Get-MessageTrackingLog -Start 2/1/1907 -EventId Expand | group-object RelatedRecipientAddress | ft <<<< Name,@{Name=' '; Expression={[String]::join(";",(" :"))}},C
ount -Autosize | export-csv c:\Test.csv
Free Windows Admin Tool Kit Click here and download it now
May 4th, 2012 3:24am
Anyone can help me out and tell me how I could get the number of emails received onto a bunch of distribution groups?
May 22nd, 2012 6:35am
Just do
[PS] C:\Windows\system32>Get-MessageTrackingLog -Start 5/21/2012 -EventId Expand | group-object RelatedRecipientAddress
| ft Name,Count -Autosize
James Chong MCITP | EA | EMA; MCSE | M+, S+ Security+, Project+, ITIL msexchangetips.blogspot.com
Free Windows Admin Tool Kit Click here and download it now
May 22nd, 2012 11:14am
Thanks James,
so I ran the command: Get-MessageTrackingLog -ResultSize unlimited -Start 21/05/2012 -EventId Expand | group-object RelatedRecipientAddress | ft Name,Count -Autosize
It then counted the number of mails per DG that has received mails on the 21th of may 2012 (as far as I understood).
I tried with -Start 21/05/2012 -End 23/05/2012 to give me a better out look. and It seems to give me exactly what I needed except one thing: The distribution groups that do not receive emails are not present on that list. Does it exist any command to show
the DG taht receive 0 mail?
Many thanks,
Graig
June 18th, 2012 5:05am
On Mon, 18 Jun 2012 09:05:35 +0000, Graiggoriz wrote:
>
>
>Thanks James,
>
>so I ran the command: Get-MessageTrackingLog -ResultSize unlimited -Start 21/05/2012 -EventId Expand | group-object RelatedRecipientAddress | ft Name,Count -Autosize
>
>It then counted the number of mails per DG that has received mails on the 21th of may 2012 (as far as I understood).
>
>I tried with -Start 21/05/2012 -End 23/05/2012 to give me a better out look. and It seems to give me exactly what I needed except one thing: The distribution groups that do not receive emails are not present on that list. Does it exist any command to
show the DG taht receive 0 mail?
You're looking at the message tracking log. If there are no messages
sent to a group the group isn't going to be found in those log files.
---
Rich Matheisen
MCSE+I, Exchange MVP
--- Rich Matheisen MCSE+I, Exchange MVP
Free Windows Admin Tool Kit Click here and download it now
June 18th, 2012 6:01pm