vMarkusK / Advanced-PRTG-Sensors

Collection of my Advanced PRTG Sensors
https://mycloudrevolution.com/
Apache License 2.0
69 stars 29 forks source link

NULL can't be converted in to Type "System.Guid" #96

Closed NSK-jo closed 1 year ago

NSK-jo commented 1 year ago

We had to switch Cloud Repositories and since then we have problems with the Script running. Unfortunately it's a german installation but maybe it's enough to find the issue.

PS C:\WINDOWS\system32> C:\VeeamBRStats.ps1 -httppush:$true -httpserver XXX -httptoken XXXX -httpport 5050 -debug
DEBUG: Starting to Process Connection to 'localhost' with user 'Veeam' ...

Bestätigung
Vorgang fortsetzen?
[J] Ja  [A] Ja, alle  [B] Befehl anhalten  [H] Anhalten  [?] Hilfe (Standard ist "J"): J
DEBUG: Connecting BRHost 'localhost' with user 'Veeam'...

Bestätigung
Vorgang fortsetzen?
[J] Ja  [A] Ja, alle  [B] Befehl anhalten  [H] Anhalten  [?] Hilfe (Standard ist "J"):
DEBUG: Veeam.Backup.Model.CBackupRepositoryInfo

Bestätigung
Vorgang fortsetzen?
[J] Ja  [A] Ja, alle  [B] Befehl anhalten  [H] Anhalten  [?] Hilfe (Standard ist "J"):
DEBUG: Cloud Repo Section Entered...

Bestätigung
Vorgang fortsetzen?
[J] Ja  [A] Ja, alle  [B] Befehl anhalten  [H] Anhalten  [?] Hilfe (Standard ist "J"):
C:\VeeamBRStats.ps1 : NULL kann nicht in den Typ "System.Guid" konvertiert werden.
In Zeile:1 Zeichen:1
+ C:\VeeamBRStats.ps1 -httppush:$true -httpserver XXXX -httptoken 85 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
    + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,VeeamBRStats.ps1

Edit: I'm using this script and it worked without any issues until we added a new cloud repo: .Notes NAME: PRTG-VeeamBRStats-v3.ps1 LASTEDIT: 2022/03/01 VERSION: 3.0.0 KEYWORDS: Veeam, PRTG

NSK-jo commented 1 year ago

I found the problem. Because we switched to a new Cloud Repository we had to delete the Service Provider.