I do need little help regarding the check_nscp_api command trying to check a process. This is the error I get through director:
“C:\Program Files\ICINGA2/sbin/check_nscp_api” --password df4RtgS! -a process=Microsoft.PowerBI.DataMovement.PersonalGateway.exe -q check_process -H localhost failed to execute: 193, “%1 is not a valid Win32 application.”
The same command works perfectly in the host’s terminal.
I’ve spent a bunch of time trying to fix it without any success, so any help would be greatly appreciated
Is the director executing the command on the correct endpoint?
Is the application a 32-bit application, but icinga is starting a 64-bit console or vice versa? In Powershell “sysnative” in the path is your friend then.
Found it! There were two check_nscp_api files on the C:\Program Files\ICINGA2\sbin directory. One was the binary one and the other an empty file. I just deleted the latter and everything worked
I would expect that one was “.exe” and the other one had no extension. As windows strips off known extensions the files look like the same name, but they are not. When you NOT use full filename in your checks, the command need to “choose”… You end up with this configuration, when you copy your checks from linux, then you have the non exe linux version there too.