Merge remote-tracking branch 'origin/develop' into ent-7595-12357-prototipo-event-server-paralelizado-y-con-recuperacion-de-alertas-bingo-card

This commit is contained in:
fbsanchez 2021-10-27 22:59:19 +02:00
commit 2d09e5bfb7
26 changed files with 51 additions and 28 deletions

View File

@ -1,5 +1,5 @@
package: pandorafms-agent-unix package: pandorafms-agent-unix
Version: 7.0NG.758-211026 Version: 7.0NG.758-211027
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.758-211026" pandora_version="7.0NG.758-211027"
echo "Test if you has the tools for to make the packages." echo "Test if you has the tools for to make the packages."
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null

View File

@ -1015,7 +1015,7 @@ my $Sem = undef;
my $ThreadSem = undef; my $ThreadSem = undef;
use constant AGENT_VERSION => '7.0NG.758'; use constant AGENT_VERSION => '7.0NG.758';
use constant AGENT_BUILD => '211026'; use constant AGENT_BUILD => '211027';
# Agent log default file size maximum and instances # Agent log default file size maximum and instances
use constant DEFAULT_MAX_LOG_SIZE => 600000; use constant DEFAULT_MAX_LOG_SIZE => 600000;

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_agent_unix %define name pandorafms_agent_unix
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
Summary: Pandora FMS Linux agent, PERL version Summary: Pandora FMS Linux agent, PERL version
Name: %{name} Name: %{name}

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_agent_unix %define name pandorafms_agent_unix
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
Summary: Pandora FMS Linux agent, PERL version Summary: Pandora FMS Linux agent, PERL version
Name: %{name} Name: %{name}

View File

@ -10,7 +10,7 @@
# ********************************************************************** # **********************************************************************
PI_VERSION="7.0NG.758" PI_VERSION="7.0NG.758"
PI_BUILD="211026" PI_BUILD="211027"
OS_NAME=`uname -s` OS_NAME=`uname -s`
FORCE=0 FORCE=0

View File

@ -186,7 +186,7 @@ UpgradeApplicationID
{} {}
Version Version
{211026} {211027}
ViewReadme ViewReadme
{Yes} {Yes}

View File

@ -30,7 +30,7 @@ using namespace Pandora;
using namespace Pandora_Strutils; using namespace Pandora_Strutils;
#define PATH_SIZE _MAX_PATH+1 #define PATH_SIZE _MAX_PATH+1
#define PANDORA_VERSION ("7.0NG.758 Build 211026") #define PANDORA_VERSION ("7.0NG.758 Build 211027")
string pandora_path; string pandora_path;
string pandora_dir; string pandora_dir;

View File

@ -11,7 +11,7 @@ BEGIN
VALUE "LegalCopyright", "Artica ST" VALUE "LegalCopyright", "Artica ST"
VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "OriginalFilename", "PandoraAgent.exe"
VALUE "ProductName", "Pandora FMS Windows Agent" VALUE "ProductName", "Pandora FMS Windows Agent"
VALUE "ProductVersion", "(7.0NG.758(Build 211026))" VALUE "ProductVersion", "(7.0NG.758(Build 211027))"
VALUE "FileVersion", "1.0.0.0" VALUE "FileVersion", "1.0.0.0"
END END
END END

View File

@ -1,5 +1,5 @@
package: pandorafms-console package: pandorafms-console
Version: 7.0NG.758-211026 Version: 7.0NG.758-211027
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.758-211026" pandora_version="7.0NG.758-211027"
package_pear=0 package_pear=0
package_pandora=1 package_pandora=1

View File

@ -20,7 +20,7 @@
/** /**
* Pandora build version and version * Pandora build version and version
*/ */
$build_version = 'PC211026'; $build_version = 'PC211027';
$pandora_version = 'v7.0NG.758'; $pandora_version = 'v7.0NG.758';
// Do not overwrite default timezone set if defined. // Do not overwrite default timezone set if defined.

View File

@ -129,7 +129,7 @@
<div style='height: 10px'> <div style='height: 10px'>
<?php <?php
$version = '7.0NG.758'; $version = '7.0NG.758';
$build = '211026'; $build = '211027';
$banner = "v$version Build $build"; $banner = "v$version Build $build";
error_reporting(0); error_reporting(0);

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name httpd %define httpd_name httpd

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name httpd %define httpd_name httpd

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_console %define name pandorafms_console
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
%define httpd_name httpd %define httpd_name httpd
# User and Group under which Apache is running # User and Group under which Apache is running
%define httpd_name apache2 %define httpd_name apache2

View File

@ -1,5 +1,5 @@
package: pandorafms-server package: pandorafms-server
Version: 7.0NG.758-211026 Version: 7.0NG.758-211027
Architecture: all Architecture: all
Priority: optional Priority: optional
Section: admin Section: admin

View File

@ -14,7 +14,7 @@
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details. # GNU General Public License for more details.
pandora_version="7.0NG.758-211026" pandora_version="7.0NG.758-211027"
package_cpan=0 package_cpan=0
package_pandora=1 package_pandora=1

View File

@ -46,7 +46,7 @@ our @EXPORT = qw(
# version: Defines actual version of Pandora Server for this module only # version: Defines actual version of Pandora Server for this module only
my $pandora_version = "7.0NG.758"; my $pandora_version = "7.0NG.758";
my $pandora_build = "211026"; my $pandora_build = "211027";
our $VERSION = $pandora_version." ".$pandora_build; our $VERSION = $pandora_version." ".$pandora_build;
# Setup hash # Setup hash

View File

@ -4263,8 +4263,26 @@ sub pandora_evaluate_snmp_alerts ($$$$$$$$$) {
# Generate an event, ONLY if our alert action is different from generate an event. # Generate an event, ONLY if our alert action is different from generate an event.
if ($action->{'id_alert_command'} != 3 && $alert->{'disable_event'} == 0){ if ($action->{'id_alert_command'} != 3 && $alert->{'disable_event'} == 0){
pandora_event ($pa_config, "SNMP alert fired (" . safe_output($alert->{'description'}) . ")", pandora_event (
0, 0, $alert->{'priority'}, 0, 0, 'alert_fired', 0, $dbh); $pa_config,
"SNMP alert fired (" . safe_output($alert->{'description'}) . ")",
0,
0,
$alert->{'priority'},
0,
0,
'alert_fired',
0,
$dbh,
undef,
undef,
undef,
undef,
undef,
undef,
undef,
undef,
p_encode_json($pa_config, $custom_data));
} }
# Update alert status # Update alert status
@ -4320,6 +4338,11 @@ sub pandora_evaluate_snmp_alerts ($$$$$$$$$) {
'disable_event' => $alert->{'disable_event'} 'disable_event' => $alert->{'disable_event'}
); );
# Additional execution information for the console.
my $custom_data = {
'actions' => [],
};
pandora_execute_action ($pa_config, $trap_rcv_full, \%agent, \%alert_action, 1, $other_action, undef, $dbh, $timestamp, \%macros) if (defined ($other_action)); pandora_execute_action ($pa_config, $trap_rcv_full, \%agent, \%alert_action, 1, $other_action, undef, $dbh, $timestamp, \%macros) if (defined ($other_action));
push(@{$custom_data->{'actions'}}, safe_output($other_action->{'action_name'})); push(@{$custom_data->{'actions'}}, safe_output($other_action->{'action_name'}));
@ -4342,7 +4365,7 @@ sub pandora_evaluate_snmp_alerts ($$$$$$$$$) {
undef, undef,
undef, undef,
undef, undef,
undef,, undef,
undef, undef,
p_encode_json($pa_config, $custom_data)); p_encode_json($pa_config, $custom_data));
} }

View File

@ -34,7 +34,7 @@ our @ISA = qw(Exporter);
# version: Defines actual version of Pandora Server for this module only # version: Defines actual version of Pandora Server for this module only
my $pandora_version = "7.0NG.758"; my $pandora_version = "7.0NG.758";
my $pandora_build = "211026"; my $pandora_build = "211027";
our $VERSION = $pandora_version." ".$pandora_build; our $VERSION = $pandora_version." ".$pandora_build;
our %EXPORT_TAGS = ( 'all' => [ qw() ] ); our %EXPORT_TAGS = ( 'all' => [ qw() ] );

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_server %define name pandorafms_server
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
Summary: Pandora FMS Server Summary: Pandora FMS Server
Name: %{name} Name: %{name}

View File

@ -3,7 +3,7 @@
# #
%define name pandorafms_server %define name pandorafms_server
%define version 7.0NG.758 %define version 7.0NG.758
%define release 211026 %define release 211027
Summary: Pandora FMS Server Summary: Pandora FMS Server
Name: %{name} Name: %{name}

View File

@ -9,7 +9,7 @@
# ********************************************************************** # **********************************************************************
PI_VERSION="7.0NG.758" PI_VERSION="7.0NG.758"
PI_BUILD="211026" PI_BUILD="211027"
MODE=$1 MODE=$1
if [ $# -gt 1 ]; then if [ $# -gt 1 ]; then

View File

@ -35,7 +35,7 @@ use PandoraFMS::Config;
use PandoraFMS::DB; use PandoraFMS::DB;
# version: define current version # version: define current version
my $version = "7.0NG.758 Build 211026"; my $version = "7.0NG.758 Build 211027";
# Pandora server configuration # Pandora server configuration
my %conf; my %conf;

View File

@ -36,7 +36,7 @@ use Encode::Locale;
Encode::Locale::decode_argv; Encode::Locale::decode_argv;
# version: define current version # version: define current version
my $version = "7.0NG.758 Build 211026"; my $version = "7.0NG.758 Build 211027";
# save program name for logging # save program name for logging
my $progname = basename($0); my $progname = basename($0);