Exchange 2010 - Specific Mailbox Stats daily report

Craig Paulsen
Craig Paulsen used Ask the Experts™
on
Hi Experts,
I wish to generate a report against a specific mailbox and for the output to be statistical information such as:
Number of incoming emails within a given start/end date/timeframe


Obviously, I am not after exchange jargon, this is to be used by a department team leader on an ongoing basis so needs to simply output information, I need to automate that the department head receives this on a daily basis

Any suggestions on how I can go about this, any handy scripts that someone may have to do this?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
You could write a power shell script and schedule it
Craig PaulsenSenior Systems Engineer

Author

Commented:
thanks, that' s part I need help with
Craig PaulsenSenior Systems Engineer

Author

Commented:
anybody???
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Craig PaulsenSenior Systems Engineer

Author

Commented:
this is what I've come up with

Add-PSSnapin Microsoft.Exchange.Management.Powershell.Admin -erroraction silentlyContinue
get-messagetrackinglog -result unlimited -recipient blblahblah -start (get-date).adddays(-1) | select messageid -unique | measure | export-csv “c:\file.csv” -NoTypeInformation
$file = “c:\file.csv”
Send-MailMessage -SmtpServer 1x.1xx.6x.x4 -To craigpa@xxxxxxx.ba -From StatMail@test.govt.ba -Subject “Mailbox Count - DDS Request” -Body “Daily email count for PDS Request” Mailbox” -attachment $file

I also need to run this as a scheduled task, as business owner wants this daily, to see amount of emails this particular mailbox is getting daily,
if I run the commands manually it outputs, however if I save the above as a .ps1 scripts it doesn't run, what am I doing wrong
timgreen7077Exchange Engineer
Distinguished Expert 2018

Commented:
Do you mean if you save it as a ps1 script and attempt to run as a scheduled task or the ps1 doesn't run all, scheduled task or not?
Craig PaulsenSenior Systems Engineer

Author

Commented:
found my own solution, no help whatsoever on here
Senior Systems Engineer
Commented:
another forum, free mind you
begs the question why pay this?
timgreen7077Exchange Engineer
Distinguished Expert 2018

Commented:
I attempted the assist you but you didnt answer my question.
Craig PaulsenSenior Systems Engineer

Author

Commented:
Hi Tim, you responded by saying create a powershell script and schedule via Task Manager,
which I already know, I specificlly needed the syntax and I responded to that
timgreen7077Exchange Engineer
Distinguished Expert 2018

Commented:
review the comments I only responded with the following:

"Do you mean if you save it as a ps1 script and attempt to run as a scheduled task or the ps1 doesn't run all, scheduled task or not?"

you never replied to me. good you got it fixed though.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial