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

Invoke-IcingaCheckDiskHealth Returns Inappropriate Output on Timeout

iperry-indigex opened this issue · comments

If the disk health check times out after obtaining a value, it will return [OK] in the output, but because of the timeout, will return with status code 3.
image

Anyone wanna take a shot at this?

Thank you for the issue. I'm not even sure on how this can happen. Is this reproducible on a constant frame or does it happen random?

It looks to me output is written to the CLI and during that time, Icinga will read everything from the buffer and kills the plugin at the same moment. <Timeout exceeded> is an Icinga thing. Which means, the plugin output is generated and killed before exit code 0 is reached.

Yeah, the plugin itself reports a healthy state, but before it is exited with code 0 in this case, it is terminated by Icinga with exit code 3 and a timeout exceeded message.

Didn't even know Icinga reads plugin outputs while in a timeout scenario.

@Al2Klimov do you have an idea on how this can happen? To me it looks like the chances to win a lottery is higher than achieving this behaviour😂

Exactly. xD But seriously, too late by 1ms is still too late, technically. So you seem to be right: #382 (comment)