What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Avamar Backup Clients Sensor "The access has been denied"

Votes:

0

Hello, i am trying to monitor Avamar backup clients, i download the script from this topic: https://kb.paessler.com/en/topic/71941-how-to-monitor-emc-avamar-clients-with-prtg but i get this error "The access has been denied. To resolve this issue, check your Credentials for Windows System in the device settings" i already checked the credentials but i have no luck to find the source of this problem. Someone can help me?

My best regards!

avamar backup-sensor dell-emc prtg

Created on Jan 18, 2022 2:11:15 PM



3 Replies

Votes:

0

Hello,

Thank you for your message.

To check where the issue might come from, I invite you to execute the script manually on the probe server and check its output.

I also recommend to replace the code by the following which properly returns the data to PRTG as well as display any execution error in the sensor message field:

try{
    $DEVICE=$args[0]
    #Set Path
    $logpath = "\\$($DEVICE)\c$\Program Files\avs\var\clientlogs"
    cd $logpath
    #Get Latest Log
    $logfile = gci *.log | sort LastWriteTime | select -last 1 | Select-object -Property Name
    #Check Log
    $status = Select-String -Path $logfile.Name -Pattern "avtar Info <5314>:" |  Foreach {$_.Line}
    #remove unwanted chars
    $statusclean = $status -replace ‘[<>]’
    #check status outcome
    if ($status -match "Command failed") { $result= "1" } else { $result = "0" }
    #send to PRTG

    Write-Output @"
    {
        "prtg": {
            "result": [
                {
                    "channel": "BackupStatus",
                    "value": $result
                }
            ],
            "text": "Status: $($statusclean)"
        }
    }
"@
} catch {
    Write-Output @"
    {
        "prtg": {
            "text": "$($_.exception.message) at line : $($_.InvocationInfo.ScriptLineNumber)",
            "error": "1" 
        }
    }
"@
}

Best regards.

Created on Jan 21, 2022 1:39:53 PM by  Florian Lesage [Paessler Support]

Last change on Jan 21, 2022 1:45:24 PM by  Florian Lesage [Paessler Support]



Votes:

0

Thank you for your reply,

My avamar console is on linux, this script is for windows console right?

    $DEVICE=$args[0]
    #Set Path
    $logpath = "\\$($DEVICE)\c$\Program Files\avs\var\clientlogs"
    cd $logpath

I think that sensor is trying to log in on windows console, there is a way to script the log in to Linux, im sorry for my dumb question, but im not programmer, i varely understand the code.

Thank you for your support.

Best regards.

Created on Jan 21, 2022 5:22:55 PM

Last change on Jan 24, 2022 7:38:13 AM by  Florian Lesage [Paessler Support]



Votes:

0

Hi,

The script is developed in PowerShell and therefore can be executed on Windows (required for the existing probe). Converting the script for Linux might be possible however I'm afraid that we do not provide official support for customizations.

Nevertheless, I invite you to check if PowerShell can be installed on your system as it can be installed on Linux: https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-linux?view=powershell-7.2. That way, you would not have to rewrite the script but simply use the one I provided above.

Best regards.

Created on Jan 24, 2022 7:50:43 AM by  Florian Lesage [Paessler Support]




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.