Icinga / icinga-powershell-plugins

A collection of Windows check plugins for the Icinga PowerShell Framework

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[IcingaUNCPath] does not contain a method named 'GetIcingaDiskFreeSpace'

Meister1900 opened this issue · comments

When running:

icinga { Invoke-IcingaCheckUNCPath -Path '\\example.com\Shares\Icinga' -Critical '20TB:' }

I get:
Method invocation failed because [IcingaUNCPath] does not contain a method named 'GetIcingaDiskFreeSpace'.

At C:\Program
Files\WindowsPowerShell\Modules\icinga-powershell-plugins\compiled\icinga-powershell-plugins.ifw_compilation.psm1:6612
char:5
[IcingaUNCPath]::GetIcingaDiskFreeSpace($authToken, $ptrPath, [re ...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
CategoryInfo : InvalidOperation: (:) [], RuntimeException
FullyQualifiedErrorId : MethodNotFound

I am using the latest version on Windows Server 2019

Have you updated all components to v1.11.0, including Framework and Plugins?
How did you update the modules? You can try to run the following:

icinga -Shell -RebuildCache;
Clear-IcingaAddTypeLib;

This function has been renamed internally and therefor no longer exist. With the above code, pre-compiled libs will be removed and the entire cache is rebuilt. Afterwards the plugin should work just fine,

Thanks, after rebuilding the cache and upgrading to v1.11.1 it's working