What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general. You are invited to get involved by asking and answering questions!

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
300.000 administrators have chosen PRTG to monitor their network. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Emails monitored by timestamp

Votes:

0

Your Vote:

Up

Down

Hi,

I need to monitor the last time since received email. As we have over 300 emails, i need a sensor that can monitor when the last email arrived. If we don`t receive an email during one hour than give an error. Currently we are using a PowerShell script that monitors the number of emails present in a mailbox, we need to add monitoring by hour. Is there a way to achieve this with PRTG? Can someone give us a hand? This is the script we are using for number of emails:

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://server.domain/PowerShell/ -Authentication Kerberos
Import-PSSession $Session -DisableNameChecking
 $Inbox = Get-MailboxFolderStatistics -Identity "mailbox1.com"| Where {$_.Name -match "Inbox|Postvak IN"} | Select ItemsInFolder
 Write-Host
"<prtg>"
    "<result>"
        "<channel>Country - Mailbox1</channel>"
        "<value>$($Inbox.ItemsInFolder)</value>"
    "</result>"
 $Inbox = Get-MailboxFolderStatistics -Identity "mailbox2.com"| Where {$_.Name -match "Inbox|Postvak IN"} | Select ItemsInFolder
 Write-Host
    "<result>"
        "<channel>Country - Mailbox2</channel>"
        "<value>$($Inbox.ItemsInFolder)</value>"
    "</result>"
 		Remove-PSSession $Session
"</prtg>"

email exchange script

Created on Oct 16, 2020 9:48:23 AM by  ROOC (0) 1

Last change on Oct 19, 2020 5:05:12 AM by  Marijan Horsky [Paessler Support]



1 Reply

Votes:

0

Your Vote:

Up

Down

Hello there,

Thanks for your KB post.

I can't seem to find any exact script for this from our KB for this.

The script required a check and compare function to return the status. We have something similar that can serve as an idea or starting point.

With kind regards,
Chan Siau Hen
Technical Support Team, Paessler AG

Created on Oct 19, 2020 9:37:08 AM by  Chan Siau Hen [Paessler Technical Support]

Last change on Oct 19, 2020 9:37:22 AM by  Chan Siau Hen [Paessler Technical Support]



Please log in or register to enter your reply.


Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.