Hello everyone,

I've created a script gives information about how many emails have been delivered to a certain mailbox in a certain amount of time.

When the sensor runs it will always return an "Access Denied" error message, except if I login on the probe or open any application with runas with the user that is supposed to run the script.

This script makes use of the CMDlet "New-PSSession" to connect to our Exchange Server.

$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://$target/PowerShell/ -Credential $Cred -Authentication Kerberos

I've tried to give it credentials via the windows placeholders from PRTG and also tried to import the credentials via a text file. Another try was to let it run without any extra import of credentials.

But the picture was always the same. Access Denied - if the user is not logged in and Results - if it is logged in or runs any application.


Article Comments

Attention: This article is a record of a conversation with the Paessler support team. The information in this conversation is not updated to preserve the historical record. As a result, some of the information or recommendations in this conversation might be out of date.

Hey,

Please note that we cannot provide support for custom scripts. Therefore, we need to ask you to contact anyone who can provide you with a solution here.


Sep, 2022 - Permalink