diff --git a/pandora_server/conf/pandora_server.conf.new b/pandora_server/conf/pandora_server.conf.new index 1906fa72eb..9e38b6cdcf 100644 --- a/pandora_server/conf/pandora_server.conf.new +++ b/pandora_server/conf/pandora_server.conf.new @@ -163,7 +163,12 @@ wmiserver 1 network_timeout 4 # Network timeout (in seconds) for timeout in remote execution commands (PANDORA FMS ENTERPRISE ONLY). -rcmd_timeout 30 + +rcmd_timeout 10 + +# Pandora FMS remote execution commands timeout tool filepath (by default at /usr/bin) + +rcmd_timeout_bin /usr/bin/timeout # Remote execution modules, ssh_launcher extra option (PANDORA FMS ENTERPRISE ONLY). ssh_launcher /usr/share/pandora_server/util/ssh_launcher.sh diff --git a/pandora_server/conf/pandora_server.conf.windows b/pandora_server/conf/pandora_server.conf.windows index a7232e459c..44a36abad9 100644 --- a/pandora_server/conf/pandora_server.conf.windows +++ b/pandora_server/conf/pandora_server.conf.windows @@ -148,6 +148,14 @@ wmiserver 0 network_timeout 5 +# Network timeout (in seconds) for timeout in remote execution commands (PANDORA FMS ENTERPRISE ONLY). + +rcmd_timeout 10 + +# Pandora FMS remote execution commands timeout tool filepath (by default at /usr/bin) + +rcmd_timeout_bin C:\PandoraFMS\Pandora_Server\bin\pandora_exec.exe + # Server keepalive (in seconds) server_keepalive 45 diff --git a/pandora_server/lib/PandoraFMS/Config.pm b/pandora_server/lib/PandoraFMS/Config.pm index 7281fc565e..4580e3b90e 100644 --- a/pandora_server/lib/PandoraFMS/Config.pm +++ b/pandora_server/lib/PandoraFMS/Config.pm @@ -275,7 +275,8 @@ sub pandora_load_config { $pa_config->{"alert_recovery"} = 0; # Introduced on 1.3.1 $pa_config->{"snmp_checks"} = 1; # Introduced on 1.3.1 $pa_config->{"snmp_timeout"} = 8; # Introduced on 1.3.1 - $pa_config->{"rcmd_timeout"} = 30; # Introduced on 7.0.740 + $pa_config->{"rcmd_timeout"} = 10; # Introduced on 7.0.740 + $pa_config->{"rcmd_timeout_bin"} = '/usr/bin/timeout'; # Introduced on 7.0.743 $pa_config->{"snmp_trapd"} = '/usr/sbin/snmptrapd'; # 3.0 $pa_config->{"tcp_checks"} = 1; # Introduced on 1.3.1 $pa_config->{"tcp_timeout"} = 20; # Introduced on 1.3.1 @@ -806,6 +807,9 @@ sub pandora_load_config { elsif ($parametro =~ m/^rcmd_timeout\s+([0-9]*)/i) { $pa_config->{"rcmd_timeout"} = clean_blank($1); } + elsif ($parametro =~ m/^rcmd_timeout_bin\s(.*)/i) { + $pa_config->{"rcmd_timeout_bin"} = clean_blank($1); + } elsif ($parametro =~ m/^tcp_checks\s+([0-9]*)/i) { $pa_config->{"tcp_checks"} = clean_blank($1); }