ASKER
ASKER
$DG=get-distributiongroup -resultsize unlimited
$incount=0
$excount=0
$start = "2011-10-01"
$end = "2011-10-09"
foreach ($item in $DG)
{
$msg= Get-TransportServer | get-messagetrackinglog -start $start -end $end -eventid receive -recipients $item.primarySMTPaddress.tostring() -resultsize unlimited
$accepted_domains = Get-AcceptedDomain |% {$_.domainname.domain}
[regex]$dom_rgx = "`(?i)(?:" + (($accepted_domains |% {"@" + [regex]::escape($_)}) -join "|") + ")$"
foreach ($m in $msg){
if ($m.sender -match $dom_rgx){
$incount++;
}
else {$excount++;}
#write-host $m.sender
}
"Distribution Group: "+$item.name
"Internal: " +$incount
"External: " +$excount
$incount=0
$excount=0
}
$DG = get-distributiongroup -ResultSize unlimited
$incount=0
$excount=0
$start = "2011-10-01"
$end = "2011-10-09"
foreach ($item in $DG)
{
$msg= Get-TransportServer | get-messagetrackinglog -start $start -end $end -eventid receive -recipients $item.primarySMTPaddress.tostring() -resultsize unlimited
$accepted_domains = Get-AcceptedDomain |% {$_.domainname.domain}
[regex]$dom_rgx = "`(?i)(?:" + (($accepted_domains |% {"@" + [regex]::escape($_)}) -join "|") + ")$"
foreach ($m in $msg){
if ($m.sender -match $dom_rgx){
$incount++
}
elseif($m){$excount++}
}
"Distribution Group: "+$item.name
"Internal: " + $incount
"External: " + $excount
$incount=0
$excount=0
}
ASKER
ASKER
Exchange is the server side of a collaborative application product that is part of the Microsoft Server infrastructure. Exchange's major features include email, calendaring, contacts and tasks, support for mobile and web-based access to information, and support for data storage.
TRUSTED BY
http://www.msexchange.org/tutorials/Sending-As.html