mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-27 15:44:11 +02:00
log an error to debug when check_command not found on service execution
refs #4391
This commit is contained in:
parent
80f899783a
commit
9249af1c66
@ -698,8 +698,10 @@ void Service::ExecuteCheck(void)
|
|||||||
try {
|
try {
|
||||||
CheckCommand::Ptr command = GetCheckCommand();
|
CheckCommand::Ptr command = GetCheckCommand();
|
||||||
|
|
||||||
if (!command)
|
if (!command) {
|
||||||
|
Log(LogDebug, "icinga", "No check_command found for service '" + GetName() + "'. Skipping execution.");
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
result = command->Execute(GetSelf());
|
result = command->Execute(GetSelf());
|
||||||
} catch (const std::exception& ex) {
|
} catch (const std::exception& ex) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user