Icinga Powershell Framework - CheckUsedPartitionSpace ends with ConversionUnitMissing error

Hi,

I rolled out Icinga Powershell Framework to a bunch of Windows servers. It works great. Only one server has a problem. Invoke-IcingaCheckUsedPartitionSpace ends with an error.

System configuration

Icinga for Windows environment overview:

Installed components on this system

Component    Version   Available
---          ---       ---
agent        2.13.1
plugins      1.6.0
framework    1.6.1

Available versions flagged with "*" mean that this component is locked to this version

Environment configuration

PowerShell Root                 => C:\Program Files\WindowsPowerShell\Modules\
Icinga for Windows Service Path => C:\Program Files\icinga-framework-service
Icinga for Windows Service User => NT Authority\NetworkService
Icinga Agent Path               => C:\Program Files\ICINGA2\
Icinga Agent User               => .\icingalocal
Defined Default User            => NT Authority\NetworkService
Icinga Managed User             => False
PowerShell Version              => 5.1.14393.4583
Operating System                => Microsoft Windows Server 2016 Datacenter
Operating System Version        => 10.0.14393
JEA Context                     =>
JEA Session File                =>

Icinga for Windows Certificate

Not installed

List of configured repositories on this system. The list order matches the apply order.

Icinga Stable
-----------
CloneSource  =>
Enabled      => True
LocalPath    =>
Order        => 0
RemotePath   => https://packages.icinga.com/IcingaForWindows/stable/ifw.repo.json
UseSCP       => False

The check CheckUsedPartitionSpace ends with an error in Icinga Web and on the commandline call of Invoke-IcingaCheckUsedPartitionSpace: [UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Details

(First part with error “Systemfehler” repeats ~10 times until everything finishes with the compile error.)

[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException

[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  "Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  "Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  "Ausnahme beim Aufrufen von
"__CreateDefaultThresholdObject" mit 0 Argument(en):  "Systemfehler""""
In C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-framework\cache\framework_cache.psm1:23124 Zeichen:16
+         return $IcingaCheckResult.Compile();
+                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodRuntimeException


Check
-----
@{Name=Used Partition Space; Verbose=0; __CheckPerfData=System.Collections.Hashtable; __Hidden=False; __Parent=; __Indention=0; __ErrorMessage=; __CheckState=0; __CheckCommand=Invoke-IcingaCheckUsedPartitionSpace; __CheckOutput=;...

I tried the following to resolve the error:

  • uninstall and reinstall the whole framework
  • setting units with options -Warning and -Critical
  • recreate the framework cache

I have no idea how to fix this error. Any help is welcome.

Regards,
Ralf

Hi,

could you also show us the command definition?

The command is created by the framework itself and imported into Icinga.

command definition
object CheckCommand "Invoke-IcingaCheckUsedPartitionSpace" {
    import "PowerShell Base"

    arguments += {
        "-C" = {
            order = 0
            value = "try { Use-Icinga -Minimal; } catch { Write-Output 'The Icinga PowerShell Framework is either not installed on the system or not configured properly. Please check https://icinga.com/docs/windows for further details'; Write-Output 'Error:' $$($$_.Exception.Message)Components:`r`n$$( Get-Module -ListAvailable 'icinga-powershell-*' )`r`n'Module-Path:'`r`n$$($$Env:PSModulePath); exit 3; }; Exit-IcingaExecutePlugin -Command 'Invoke-IcingaCheckUsedPartitionSpace' "
        }
        "-Critical" = {
            order = 3
            value = "$IcingaCheckUsedPartitionSpace_Object_Critical$"
        }
        "-Exclude" = {
            order = 5
            value = {{
                var arr = macro("$IcingaCheckUsedPartitionSpace_Array_Exclude$");
                if (len(arr) == 0) {
                    return "@()";
                }
                return arr.map(
                    x => if (typeof(x) == String) {
                        var argLen = len(x);
                        if (argLen != 0 && x.substr(0,1) == "'" && x.substr(argLen - 1, argLen) == "'") {
                            x;
                        } else {
                            "'" + x + "'";
                        }
                    } else {
                        x;
                    }
                ).join(",");
            }}
        }
        "-IgnoreEmptyChecks" = {
            order = 99
            set_if = "$IcingaCheckUsedPartitionSpace_Switchparameter_IgnoreEmptyChecks$"
        }
        "-Include" = {
            order = 4
            value = {{
                var arr = macro("$IcingaCheckUsedPartitionSpace_Array_Include$");
                if (len(arr) == 0) {
                    return "@()";
                }
                return arr.map(
                    x => if (typeof(x) == String) {
                        var argLen = len(x);
                        if (argLen != 0 && x.substr(0,1) == "'" && x.substr(argLen - 1, argLen) == "'") {
                            x;
                        } else {
                            "'" + x + "'";
                        }
                    } else {
                        x;
                    }
                ).join(",");
            }}
        }
        "-NoPerfData" = {
            order = 99
            set_if = "$IcingaCheckUsedPartitionSpace_Switchparameter_NoPerfData$"
        }
        "-SkipUnknown" = {
            order = 99
            set_if = "$IcingaCheckUsedPartitionSpace_Switchparameter_SkipUnknown$"
        }
        "-ThresholdInterval" = {
            order = 100
            value = "$IcingaCheckUsedPartitionSpace_String_ThresholdInterval$"
        }
        "-Verbosity" = {
            order = 6
            value = "$IcingaCheckUsedPartitionSpace_Int32_Verbosity$"
        }
        "-Warning" = {
            order = 2
            value = "$IcingaCheckUsedPartitionSpace_Object_Warning$"
        }
    }
    vars.IcingaCheckUsedPartitionSpace_Switchparameter_IgnoreEmptyChecks = false
    vars.IcingaCheckUsedPartitionSpace_Switchparameter_NoPerfData = false
    vars.IcingaCheckUsedPartitionSpace_Switchparameter_SkipUnknown = false
}

Sorry my fault, I meant the service definition

Here is the service template from Icinga Director

Service Template
template Service "IcingaCheckUsedPartitionSpace" {
    import "Agent-based Service"

    check_command = "Invoke-IcingaCheckUsedPartitionSpace"
}
Service Template resolved
zones.d/director-global/service_templates.conf

template Service "IcingaCheckUsedPartitionSpace" {
    check_command = "Invoke-IcingaCheckUsedPartitionSpace"
    max_check_attempts = "3"
    check_period = "24x7"
    check_interval = 5m
    retry_interval = 1m
    enable_notifications = true
    enable_active_checks = true
    enable_passive_checks = true
    enable_event_handler = true
    enable_perfdata = true
    command_endpoint = host_name
}

The service template is assigned to a host template, which is based on the default Icinga Agent host template. This host template is assigned to 12 servers. I use also these framework checks without problems: CheckCPU, CheckDiskHealth, CheckMemory, CheckUptime.

ok and where you’ve defined the values? This would be the main interesting point. Because the error you’ll see from the framework is talking about wrong passed values incl. used unit!

I don’t pass any values. Here is the call from the debuglog.

[2021-10-20 15:06:44 +0200] notice/Process: Running command 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NoLogo -ExecutionPolicy ByPass -C "try { Use-Icinga -Minimal; } catch { Write-Output 'The Icinga PowerShell Framework is either not installed on the system or not configured properly. Please check https://icinga.com/docs/windows for further details'; Write-Output 'Error:' $($_.Exception.Message)Components:rn$( Get-Module -ListAvailable 'icinga-powershell-*' )rn'Module-Path:'rn$($Env:PSModulePath); exit 3; }; Exit-IcingaExecutePlugin -Command 'Invoke-IcingaCheckUsedPartitionSpace' " -Include @() -Exclude @()': PID 6140

And here I set warning and crtitical values in Director. The error is the same like before.

[2021-10-20 15:15:01 +0200] notice/Process: Running command 'C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -NoProfile -NoLogo -ExecutionPolicy ByPass -C "try { Use-Icinga -Minimal; } catch { Write-Output 'The Icinga PowerShell Framework is either not installed on the system or not configured properly. Please check https://icinga.com/docs/windows for further details'; Write-Output 'Error:' $($_.Exception.Message)Components:rn$( Get-Module -ListAvailable 'icinga-powershell-*' )rn'Module-Path:'rn$($Env:PSModulePath); exit 3; }; Exit-IcingaExecutePlugin -Command 'Invoke-IcingaCheckUsedPartitionSpace' " -Warning 5GB -Critical 10GB -Include @() -Exclude @()': PID 11036

you write you’re not passing any value. But the debug message says something diffrent: :wink:

And also there is passed a double quote. Maybe there is an (old) definition in your host/service object?
If you are using the director, you can use the function “inspect” in icingaweb. Here you’ll find how the check will be called by icinga and also a lot of key/value pairs.

Hi, the first output at 15:06:44 is my default setting without any values for every server. The second output from 15:15:01 is only a test to see what changes, when I enter values for critical/warning in Director. I tried it on another server without any problem.

The double quote area starts at "try.

I’ll uninstall everything and try to delete everything from the powershell folders. Perhaps a previous installation left things behind.

Nothing changes. Cleanup (nothing to delete) and a fresh install with exactly the same steps as on every other of my servers leads to the same errors. I deleted the host in Icinga and let the installation script recreate it, so I started with a clean configuration.

Looks like there is a problem with my disk configuration. It’s a server with 120 physical disks, 14 logical disks, combined in 1 Windows dynamic disk, and over 300TB of space. I think, I should file an issue on Github.

Thank you very much Stevie.

Because the check is working without values and the error message tells you that the conversion of a passed value is not working, I’m out of ideas.

Hi,

it looks like a mismatching combination of ps-framework and ps-plugins. I’d suggest to completely remove the icinga-environment locally on that host and start with a fresh local installation:
Use-Icinga; Uninstall-IcingaAgent –RemoveDataFolder; Uninstall-IcingaFrameworkService; del C:\ProgramData\icinga2 –Recurse -Force; del ‘C:\Program Files\ICINGA2’ –Recurse -Force; del ‘C:\Program Files\icinga-framework-service’ –Recurse -Force; del ‘C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-framework’ –Recurse -Force; del ‘C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-plugins’ –Recurse -Force; del $env:TEMP\icinga*

I’ve seen some strange behaviour of plugins or framework if there were some files or so left. The syntax of the plugin-call itself seems to be correct, it is also working in my environment. But a server with so many disks is also a good hint - framework/plugins > 1.6 are doing a lot of things in the background and maybe this leads to other issues. How long does this plugin-call takes to run on this particular system?

Hi, that’s work for Monday. I do it once again, the last time I used Uninstall-IcingaForWindows;, and checked all the folders you mentioned.

The call of Invoke-IcingaCheckUsedPartitionSpace takes 45 seconds. The error message repeats 14 times, exactly the number of virtual disks of the big RAID. See the full error file.

The NULL-Array error is on every server, virtual and bare metal, even on fresh installs without any Icinga installation before.

Complete stderr/stdout
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "WarnOutOfRange" mit 1 Argument(en):  "Systemfehler"
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\plugins\Invoke-IcingaCheckUsedPartitionSpace.psm1:144 
Zeichen:17
+ ...             $IcingaCheck.WarnOutOfRange($Warning).CritOutOfRange($Cri ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodFlowControlException
 
[UNKNOWN]: Icinga Invalid Input Error was thrown: ConversionUnitMissing

Unable to parse input value. You have to add an unit to your input value. Example: "10GB". Allowed units are: "B, KB, 
MB, GB, TB, PB, KiB, MiB, GiB, TiB, PiB".
Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  "Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  
"Ausnahme beim Aufrufen von "Compile" mit 0 Argument(en):  "Ausnahme beim Aufrufen von 
"__CreateDefaultThresholdObject" mit 0 Argument(en):  "Systemfehler""""
In C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-framework\cache\framework_cache.psm1:23124 Zeichen:16
+         return $IcingaCheckResult.Compile();
+                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [], MethodInvocationException
    + FullyQualifiedErrorId : ScriptMethodRuntimeException
 

Check                                                                                                                  
-----                                                                                                                  
@{Name=Used Partition Space; Verbose=0; __CheckPerfData=System.Collections.Hashtable; __Hidden=False; __Parent=; __I...



Hi Ralf,
what output do you get if you do that “Get-IcingaPhysicalDiskInfo” directly? This is what I get:

Get-IcingaPhysicalDiskInfo (2 volumes)

Name Value


0 {IsPartial, DeviceID, Status, InstallDate…}
1 {IsPartial, DeviceID, Status, InstallDate…}

4 volumes:
Get-IcingaPhysicalDiskInfo

Name Value


2 {IsPartial, DeviceID, Status, InstallDate…}
0 {IsPartial, DeviceID, Status, InstallDate…}
1 {IsPartial, DeviceID, Status, InstallDate…}
3 {IsPartial, DeviceID, Status, InstallDate…}

Is there a difference if you call this command within a admin-powershell or a non privileged shell? Is the user the icinga-agent is running with allowed to query this info?

Regards & enjoy the weekend!

Hi Henning & Stevie, after a sunny weekend - nothing changed. I uninstalled Icinga, deleted my non-privileged Icinga user, and checked every folder. I installed Icinga again, plugins and framework service in default fashion. No special user and special user rights like before. Nothing changes.

Here is the output of Get-IcingaPhysicalDiskInfo. The only difference between an Administrator and a non privileged user is the NULL Array exception. The stdout ouput is the same.

Administrator
Name Value
---- -----
3    {IsPartial, DeviceID, Status, InstallDate...}
5    {IsPartial, DeviceID, Status, InstallDate...}
12   {IsPartial, DeviceID, Status, InstallDate...}
10   {IsPartial, DeviceID, Status, InstallDate...}
2    {IsPartial, DeviceID, Status, InstallDate...}
8    {IsPartial, DeviceID, Status, InstallDate...}
0    {IsPartial, DeviceID, Status, InstallDate...}
11   {IsPartial, DeviceID, Status, InstallDate...}
1    {IsPartial, DeviceID, Status, InstallDate...}
9    {IsPartial, DeviceID, Status, InstallDate...}
14   {IsPartial, DeviceID, Status, InstallDate...}
7    {IsPartial, DeviceID, Status, InstallDate...}
6    {IsPartial, DeviceID, Status, InstallDate...}
4    {IsPartial, DeviceID, Status, InstallDate...}
13   {IsPartial, DeviceID, Status, InstallDate...}
non privileged user
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:122 Zeichen:17
+                 $DiskInfo.BusType           = @{
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 
Es ist nicht möglich, einen Index auf ein NULL-Array anzuwenden.
In C:\Program 
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\provider\disks\Get-IcingaPhysicalDiskInfo.psm1:130 Zeichen:25
+ ...             Add-IcingaHashtableItem -Hashtable $OperationalStatus -Ke ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (:) [], RuntimeException
    + FullyQualifiedErrorId : NullArray
 

Name                           Value                                                                                   
----                           -----                                                                                   
3                              {IsPartial, DeviceID, Status, InstallDate...}                                           
5                              {IsPartial, DeviceID, Status, InstallDate...}                                           
12                             {IsPartial, DeviceID, Status, InstallDate...}                                           
10                             {IsPartial, DeviceID, Status, InstallDate...}                                           
2                              {IsPartial, DeviceID, Status, InstallDate...}                                           
8                              {IsPartial, DeviceID, Status, InstallDate...}                                           
0                              {IsPartial, DeviceID, Status, InstallDate...}                                           
11                             {IsPartial, DeviceID, Status, InstallDate...}                                           
1                              {IsPartial, DeviceID, Status, InstallDate...}                                           
9                              {IsPartial, DeviceID, Status, InstallDate...}                                           
14                             {IsPartial, DeviceID, Status, InstallDate...}                                           
7                              {IsPartial, DeviceID, Status, InstallDate...}                                           
6                              {IsPartial, DeviceID, Status, InstallDate...}                                           
4                              {IsPartial, DeviceID, Status, InstallDate...}                                           
13                             {IsPartial, DeviceID, Status, InstallDate...}                                           

Hi Ralf,
I assume that the unprivileged user - in contrast to the Admin-account - is not allowed to access a required information (e.g. WMI, registry-key, whatever…). The result is an unexpected empty variable which cannot be processed. One idea is using “Process Monitor” for discovering which access is not working as expected.
You could also enable the debug-mode in framework and try run the command again: Enable-IcingaFrameworkDebugMode
If the output is helpful to identify the problem you should open an issue in github.

Hi Hennig, I’ll give your debug options a try.

FYI I added permissions in this way:

Add-LocalGroupMember -Group "Leistungsüberwachungsbenutzer" -Member icingalocal
Set-IcingaAgentServiceUser -User icingalocal -Password $Secure_String_Pwd -SetPermission

Add-IcingaWmiPermissions -User "icingalocal" -Namespace root\cimv2 -Enable -Recursive
Add-IcingaWmiPermissions -User "icingalocal" -Namespace root\WMI -Enable -Recursive
Add-IcingaWmiPermissions -User "icingalocal" -Namespace root\Microsoft\Windows\Storage -Enable -Recursive

I checked the rights in MMC WMI Control with working servers, no difference.

Thanks for your help.
Ralf

Hello,

does this only affect the partition space plugin or is the disk health plugin also having an issue on this system?
It seems like one partition or disk can not be read properly, and therefor internally the values are incorrect, causing an issue on this specific machine.

Hi, the disk health plugin is not affected. Here is the Icinga Web output.

Plugin Output
[OK] Physical Disk Package: 16 Ok

I can’t get this output from a command line call, even when I use the same options like in debug.log.

When I exclude my big volume D from the check:, the error disappears Invoke-IcingaCheckUsedPartitionSpace -Exclude @('D:'). It’s a dynamic windows volume, which combines 14 volumes from a RAID. It’s ReFS formatted. I don’t see any access problems (ACCESS DENIED) in procmon. Looks like there is something special with this volume I can’t see.