-
Notifications
You must be signed in to change notification settings - Fork 31
Description
Expected Behavior
Register Background Daemon and Service Checks to collect metrics over time should work.
Register-IcingaBackgroundDaemon -Command 'Start-IcingaServiceCheckDaemon';
Register-IcingaServiceCheck -CheckCommand 'Invoke-IcingaCheckCPU' -Interval 30 -TimeIndexes 1, 3, 5, 15;
Show-IcingaRegisteredServiceChecks;
Current Behavior
Register-IcingaServiceCheck fails and print several powershell errors:
Add-Member : Cannot bind argument to parameter 'InputObject' because it is null.
At C:\Program Files\WindowsPowerShell\Modules\icinga-powershell-framework\cache\framework_cache.psm1:411 char:21
... figObject | Add-Member -MemberType NoteProperty -Name $ConfigKey -Val ...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
CategoryInfo : InvalidData: (:) [Add-Member], ParameterBindingValidationException
FullyQualifiedErrorId : ParameterArgumentValidationErrorNullNotAllowed,Microsoft.PowerShell.Commands.AddMemberCommand
Possible Solution
Steps to Reproduce (for bugs)
- follow guide to install IcingaForWindows (first installation on a new system)
- run
Register-IcingaBackgroundDaemon -Command 'Start-IcingaServiceCheckDaemon'; - run
Register-IcingaServiceCheck -CheckCommand 'Invoke-IcingaCheckCPU' -Interval 30 -TimeIndexes 1, 3, 5, 15; - multiple errors occured
Context
collect metrics over time not usable with framework 1.10
Your Environment
- PowerShell Version used (
$PSVersionTable.PSVersion):
Major Minor Build Revision
5_______1_____17763__592 - Operating System and version (
Get-IcingaWindowsInformation Win32_OperatingSystem | Select-Object Version, BuildNumber, Caption):
Version_____BuildNumber__Caption
10.0.17763__17763______Microsoft Windows Server 2019 Standard Evaluation
(fresh installed to exclude possible side effects)