mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-27 07:44:35 +02:00
Merge remote-tracking branch 'origin/develop' into new-vc-line-element
This commit is contained in:
commit
536af6f33a
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-agent-unix
|
package: pandorafms-agent-unix
|
||||||
Version: 7.0NG.742-200116
|
Version: 7.0NG.742-200119
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -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.742-200116"
|
pandora_version="7.0NG.742-200119"
|
||||||
|
|
||||||
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
|
||||||
|
@ -55,7 +55,7 @@ my $Sem = undef;
|
|||||||
my $ThreadSem = undef;
|
my $ThreadSem = undef;
|
||||||
|
|
||||||
use constant AGENT_VERSION => '7.0NG.742';
|
use constant AGENT_VERSION => '7.0NG.742';
|
||||||
use constant AGENT_BUILD => '200116';
|
use constant AGENT_BUILD => '200119';
|
||||||
|
|
||||||
# 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;
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_agent_unix
|
%define name pandorafms_agent_unix
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
Summary: Pandora FMS Linux agent, PERL version
|
Summary: Pandora FMS Linux agent, PERL version
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_agent_unix
|
%define name pandorafms_agent_unix
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
Summary: Pandora FMS Linux agent, PERL version
|
Summary: Pandora FMS Linux agent, PERL version
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
# **********************************************************************
|
# **********************************************************************
|
||||||
|
|
||||||
PI_VERSION="7.0NG.742"
|
PI_VERSION="7.0NG.742"
|
||||||
PI_BUILD="200116"
|
PI_BUILD="200119"
|
||||||
OS_NAME=`uname -s`
|
OS_NAME=`uname -s`
|
||||||
|
|
||||||
FORCE=0
|
FORCE=0
|
||||||
|
@ -186,7 +186,7 @@ UpgradeApplicationID
|
|||||||
{}
|
{}
|
||||||
|
|
||||||
Version
|
Version
|
||||||
{200116}
|
{200119}
|
||||||
|
|
||||||
ViewReadme
|
ViewReadme
|
||||||
{Yes}
|
{Yes}
|
||||||
|
@ -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.742(Build 200116)")
|
#define PANDORA_VERSION ("7.0NG.742(Build 200119)")
|
||||||
|
|
||||||
string pandora_path;
|
string pandora_path;
|
||||||
string pandora_dir;
|
string pandora_dir;
|
||||||
|
@ -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.742(Build 200116))"
|
VALUE "ProductVersion", "(7.0NG.742(Build 200119))"
|
||||||
VALUE "FileVersion", "1.0.0.0"
|
VALUE "FileVersion", "1.0.0.0"
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-console
|
package: pandorafms-console
|
||||||
Version: 7.0NG.742-200116
|
Version: 7.0NG.742-200119
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -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.742-200116"
|
pandora_version="7.0NG.742-200119"
|
||||||
|
|
||||||
package_pear=0
|
package_pear=0
|
||||||
package_pandora=1
|
package_pandora=1
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
START TRANSACTION;
|
START TRANSACTION;
|
||||||
|
|
||||||
|
ALTER TABLE `tserver` ADD COLUMN `port` int(5) unsigned NOT NULL default 0;
|
||||||
ALTER TABLE `tmap` ADD COLUMN `id_group_map` INT(10) UNSIGNED NOT NULL default 0;
|
ALTER TABLE `tmap` ADD COLUMN `id_group_map` INT(10) UNSIGNED NOT NULL default 0;
|
||||||
ALTER TABLE `tevent_filter` MODIFY `severity` TEXT NOT NULL;
|
ALTER TABLE `tevent_filter` MODIFY `severity` TEXT NOT NULL;
|
||||||
|
|
||||||
|
@ -1778,6 +1778,7 @@ ALTER TABLE tserver_export_data MODIFY `module_name` varchar(600) NOT NULL defau
|
|||||||
-- Table `tserver`
|
-- Table `tserver`
|
||||||
-- ---------------------------------------------------------------------
|
-- ---------------------------------------------------------------------
|
||||||
ALTER TABLE tserver ADD COLUMN exec_proxy tinyint(1) UNSIGNED NOT NULL default 0;
|
ALTER TABLE tserver ADD COLUMN exec_proxy tinyint(1) UNSIGNED NOT NULL default 0;
|
||||||
|
ALTER TABLE `tserver` ADD COLUMN `port` int(5) unsigned NOT NULL default 0;
|
||||||
|
|
||||||
-- ---------------------------------------------------------------------
|
-- ---------------------------------------------------------------------
|
||||||
-- Table `tevent_response`
|
-- Table `tevent_response`
|
||||||
|
@ -95,7 +95,12 @@ background:black;opacity:0.1;left:0px;top:0px;width:100%;height:100%;
|
|||||||
<img class='modalcontentim' src='<?php echo $config['homeurl']; ?>/images/mysqlerr.png'>
|
<img class='modalcontentim' src='<?php echo $config['homeurl']; ?>/images/mysqlerr.png'>
|
||||||
<div class='modalcontenttex'>
|
<div class='modalcontenttex'>
|
||||||
<?php
|
<?php
|
||||||
echo __('Failure to connect to Database server, please check the configuration file config.php or contact system administrator if you need assistance.');
|
if ($config['history_db_connection'] === false) {
|
||||||
|
echo __('Failure to connect to historical database, please check the configuration or contact system administrator if you need assistance.');
|
||||||
|
} else {
|
||||||
|
echo __('Failure to connect to Database server, please check the configuration file config.php or contact system administrator if you need assistance.');
|
||||||
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -134,4 +139,4 @@ background:black;opacity:0.1;left:0px;top:0px;width:100%;height:100%;
|
|||||||
<div id="opacity"></div>
|
<div id="opacity"></div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
@ -45,3 +45,22 @@ switch ($wizard_section) {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
require 'agent_wizard.'.$wizard_section.'.php';
|
require 'agent_wizard.'.$wizard_section.'.php';
|
||||||
|
|
||||||
|
?>
|
||||||
|
<script language="javascript" type="text/javascript">
|
||||||
|
|
||||||
|
function satellite_remote_warn(id_satellite, remote)
|
||||||
|
{
|
||||||
|
if(!remote)
|
||||||
|
{
|
||||||
|
$('#server_to_exec option[value='+id_satellite+']').prop('disabled', true);
|
||||||
|
$('#satellite_remote_tip').removeAttr("style").show();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$('#satellite_remote_tip').removeAttr("style").hide();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
</script>
|
@ -738,11 +738,16 @@ $servers_to_exec[0] = __('Local console');
|
|||||||
if (enterprise_installed()) {
|
if (enterprise_installed()) {
|
||||||
enterprise_include_once('include/functions_satellite.php');
|
enterprise_include_once('include/functions_satellite.php');
|
||||||
|
|
||||||
$rows = get_proxy_servers(true);
|
$rows = get_proxy_servers();
|
||||||
|
|
||||||
|
// Check if satellite server has remote configuration enabled.
|
||||||
|
$satellite_remote = config_agents_has_remote_configuration($id_agent);
|
||||||
|
|
||||||
foreach ($rows as $row) {
|
foreach ($rows as $row) {
|
||||||
if ($row['server_type'] != 13) {
|
if ($row['server_type'] != 13) {
|
||||||
$s_type = ' (Standard)';
|
$s_type = ' (Standard)';
|
||||||
} else {
|
} else {
|
||||||
|
$id_satellite = $row['id_server'];
|
||||||
$s_type = ' (Satellite)';
|
$s_type = ' (Satellite)';
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -750,8 +755,16 @@ if (enterprise_installed()) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$table->data[1][2] = '<b>'.__('Server to execute command').'</b>';
|
$table->data[1][2] = '<b>'.__('Server to execute command').'</b>'.ui_print_help_icon('agent_snmp_explorer_tab', true);
|
||||||
$table->data[1][3] = html_print_select($servers_to_exec, 'server_to_exec', $server_to_exec, '', '', '', true);
|
$table->data[1][3] = html_print_select(
|
||||||
|
$servers_to_exec,
|
||||||
|
'server_to_exec',
|
||||||
|
$server_to_exec,
|
||||||
|
'satellite_remote_warn('.$id_satellite.','.$satellite_remote.')',
|
||||||
|
'',
|
||||||
|
'',
|
||||||
|
true
|
||||||
|
);
|
||||||
|
|
||||||
$snmp_versions['1'] = 'v. 1';
|
$snmp_versions['1'] = 'v. 1';
|
||||||
$snmp_versions['2'] = 'v. 2';
|
$snmp_versions['2'] = 'v. 2';
|
||||||
@ -1020,6 +1033,8 @@ ui_require_javascript_file('pandora_modules');
|
|||||||
var separator = '<?php echo $separator; ?>';
|
var separator = '<?php echo $separator; ?>';
|
||||||
|
|
||||||
$(document).ready (function () {
|
$(document).ready (function () {
|
||||||
|
$('#server_to_exec option').trigger('change');
|
||||||
|
|
||||||
$("#walk_form").submit(function() {
|
$("#walk_form").submit(function() {
|
||||||
$("#oid_loading").show ();
|
$("#oid_loading").show ();
|
||||||
});
|
});
|
||||||
|
@ -492,7 +492,7 @@ if (enterprise_installed()) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$table->data[1][2] = '<b>'.__('Server to execute command').'</b>';
|
$table->data[1][2] = '<b>'.__('Server to execute command').'</b>'.ui_print_help_icon('agent_snmp_explorer_tab', true);
|
||||||
$table->data[1][2] .= '<span id=satellite_remote_tip>'.ui_print_help_tip(__('In order to use remote executions you need to enable remote execution in satellite server'), true, 'images/tip_help.png', false, 'display:').'</span>';
|
$table->data[1][2] .= '<span id=satellite_remote_tip>'.ui_print_help_tip(__('In order to use remote executions you need to enable remote execution in satellite server'), true, 'images/tip_help.png', false, 'display:').'</span>';
|
||||||
$table->data[1][4] = html_print_select(
|
$table->data[1][4] = html_print_select(
|
||||||
$servers_to_exec,
|
$servers_to_exec,
|
||||||
@ -734,20 +734,5 @@ function snmp_changed_by_multiple_snmp (event, id_snmp, selected) {
|
|||||||
"json");
|
"json");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function satellite_remote_warn(id_satellite, remote)
|
|
||||||
{
|
|
||||||
if(!remote)
|
|
||||||
{
|
|
||||||
$('#server_to_exec option[value='+id_satellite+']').prop('disabled', true);
|
|
||||||
$('#satellite_remote_tip').removeAttr("style").show();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
$('#satellite_remote_tip').removeAttr("style").hide();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ]]> */
|
/* ]]> */
|
||||||
</script>
|
</script>
|
||||||
|
@ -64,12 +64,22 @@ if ($wmiexplore) {
|
|||||||
$processes_name_field = 1;
|
$processes_name_field = 1;
|
||||||
if (enterprise_installed() && (int) $server_to_exec != 0) {
|
if (enterprise_installed() && (int) $server_to_exec != 0) {
|
||||||
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
||||||
exec(
|
|
||||||
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
if (empty($server_data['port'])) {
|
||||||
'".$wmi_processes."'",
|
exec(
|
||||||
$output,
|
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
$rc
|
'".$wmi_processes."'",
|
||||||
);
|
$output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
exec(
|
||||||
|
'ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
|
'".$wmi_processes."'",
|
||||||
|
$output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
exec($wmi_processes, $output);
|
exec($wmi_processes, $output);
|
||||||
}
|
}
|
||||||
@ -110,12 +120,21 @@ if ($wmiexplore) {
|
|||||||
'id_server',
|
'id_server',
|
||||||
$server_to_exec
|
$server_to_exec
|
||||||
);
|
);
|
||||||
|
if (empty($server_data['port'])) {
|
||||||
exec(
|
exec(
|
||||||
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
'".$wmi_services."'",
|
'".$wmi_services."'",
|
||||||
$output,
|
$output,
|
||||||
$rc
|
$rc
|
||||||
);
|
);
|
||||||
|
} else {
|
||||||
|
exec(
|
||||||
|
'ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
|
'".$wmi_services."'",
|
||||||
|
$output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
exec($wmi_services, $output);
|
exec($wmi_services, $output);
|
||||||
}
|
}
|
||||||
@ -145,12 +164,22 @@ if ($wmiexplore) {
|
|||||||
|
|
||||||
if (enterprise_installed() && (int) $server_to_exec != 0) {
|
if (enterprise_installed() && (int) $server_to_exec != 0) {
|
||||||
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
||||||
exec(
|
|
||||||
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
if (empty($server_data['port'])) {
|
||||||
'".$wmi_disks."'",
|
exec(
|
||||||
$output,
|
'ssh pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
$rc
|
'".$wmi_disks."'",
|
||||||
);
|
$output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
exec(
|
||||||
|
'ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address']."
|
||||||
|
'".$wmi_disks."'",
|
||||||
|
$output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
exec($wmi_disks, $output);
|
exec($wmi_disks, $output);
|
||||||
}
|
}
|
||||||
@ -469,7 +498,7 @@ if (enterprise_installed()) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$table->data[2][0] = '<b>'.__('Server to execute command').'</b>';
|
$table->data[2][0] = '<b>'.__('Server to execute command').'</b>'.ui_print_help_icon('agent_snmp_explorer_tab', true);
|
||||||
$table->data[2][1] = html_print_select(
|
$table->data[2][1] = html_print_select(
|
||||||
$servers_to_exec,
|
$servers_to_exec,
|
||||||
'server_to_exec',
|
'server_to_exec',
|
||||||
|
@ -32,7 +32,7 @@ if (isset($_GET['server'])) {
|
|||||||
$id_server = get_parameter_get('server');
|
$id_server = get_parameter_get('server');
|
||||||
// Headers
|
// Headers
|
||||||
ui_print_page_header(__('Update Server'), 'images/gm_servers.png', false, 'servers', true);
|
ui_print_page_header(__('Update Server'), 'images/gm_servers.png', false, 'servers', true);
|
||||||
$sql = sprintf('SELECT name, ip_address, description, server_type, exec_proxy FROM tserver WHERE id_server = %d', $id_server);
|
$sql = sprintf('SELECT name, ip_address, description, server_type, exec_proxy, port FROM tserver WHERE id_server = %d', $id_server);
|
||||||
$row = db_get_row_sql($sql);
|
$row = db_get_row_sql($sql);
|
||||||
echo '<form name="servers" method="POST" action="index.php?sec=gservers&sec2=godmode/servers/modificar_server&update=1">';
|
echo '<form name="servers" method="POST" action="index.php?sec=gservers&sec2=godmode/servers/modificar_server&update=1">';
|
||||||
html_print_input_hidden('server', $id_server);
|
html_print_input_hidden('server', $id_server);
|
||||||
@ -75,6 +75,14 @@ if (isset($_GET['server'])) {
|
|||||||
__('Exec Server'),
|
__('Exec Server'),
|
||||||
html_print_checkbox('exec_proxy', 1, $row['exec_proxy'], true),
|
html_print_checkbox('exec_proxy', 1, $row['exec_proxy'], true),
|
||||||
];
|
];
|
||||||
|
|
||||||
|
$port_number = empty($row['port']) ? '' : $row['port'];
|
||||||
|
|
||||||
|
$table->data[] = [
|
||||||
|
__('Port'),
|
||||||
|
html_print_input_text('port', $port_number, '', 10, 0, true).ui_print_help_tip(__('Leave blank to use SSH default port (22)'), true),
|
||||||
|
];
|
||||||
|
|
||||||
if ($row['exec_proxy']) {
|
if ($row['exec_proxy']) {
|
||||||
$table->data[] = [
|
$table->data[] = [
|
||||||
__('Check Exec Server'),
|
__('Check Exec Server'),
|
||||||
@ -136,11 +144,15 @@ if (isset($_GET['server'])) {
|
|||||||
$description = get_parameter_post('description');
|
$description = get_parameter_post('description');
|
||||||
$id_server = get_parameter_post('server');
|
$id_server = get_parameter_post('server');
|
||||||
$exec_proxy = get_parameter_post('exec_proxy');
|
$exec_proxy = get_parameter_post('exec_proxy');
|
||||||
|
$port = get_parameter_post('port');
|
||||||
|
|
||||||
|
$port_number = empty($port) ? 0 : $port;
|
||||||
|
|
||||||
$values = [
|
$values = [
|
||||||
'ip_address' => $address,
|
'ip_address' => $address,
|
||||||
'description' => $description,
|
'description' => $description,
|
||||||
'exec_proxy' => $exec_proxy,
|
'exec_proxy' => $exec_proxy,
|
||||||
|
'port' => $port_number,
|
||||||
];
|
];
|
||||||
$result = db_process_sql_update('tserver', $values, ['id_server' => $id_server]);
|
$result = db_process_sql_update('tserver', $values, ['id_server' => $id_server]);
|
||||||
if ($result !== false) {
|
if ($result !== false) {
|
||||||
|
@ -101,6 +101,10 @@ foreach ($servers as $server) {
|
|||||||
$data[2] .= ui_print_help_tip(__('This is a master server'), true);
|
$data[2] .= ui_print_help_tip(__('This is a master server'), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($server['exec_proxy'] == 1) {
|
||||||
|
$data[2] .= html_print_image('images/star.png', true, ['title' => __('Exec server enabled')]);
|
||||||
|
}
|
||||||
|
|
||||||
// $data[2] .= '</span> <span style="font-size:8px;"> v' .. '</span>';
|
// $data[2] .= '</span> <span style="font-size:8px;"> v' .. '</span>';
|
||||||
switch ($server['type']) {
|
switch ($server['type']) {
|
||||||
case 'snmp':
|
case 'snmp':
|
||||||
|
@ -956,7 +956,11 @@ if ($perform_event_response) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
system('ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$timeout_bin.' '.$command_timeout.' '.io_safe_output($command).' 2>&1"', $ret_val);
|
if (empty($server_data['port'])) {
|
||||||
|
system('ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$timeout_bin.' '.$command_timeout.' '.io_safe_output($command).' 2>&1"', $ret_val);
|
||||||
|
} else {
|
||||||
|
system('ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address'].' "'.$timeout_bin.' '.$command_timeout.' '.io_safe_output($command).' 2>&1"', $ret_val);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
switch (PHP_OS) {
|
switch (PHP_OS) {
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
/**
|
/**
|
||||||
* Pandora build version and version
|
* Pandora build version and version
|
||||||
*/
|
*/
|
||||||
$build_version = 'PC200116';
|
$build_version = 'PC200119';
|
||||||
$pandora_version = 'v7.0NG.742';
|
$pandora_version = 'v7.0NG.742';
|
||||||
|
|
||||||
// Do not overwrite default timezone set if defined.
|
// Do not overwrite default timezone set if defined.
|
||||||
|
@ -1994,7 +1994,12 @@ function get_snmpwalk(
|
|||||||
if (enterprise_installed()) {
|
if (enterprise_installed()) {
|
||||||
if ($server_to_exec != 0) {
|
if ($server_to_exec != 0) {
|
||||||
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
$server_data = db_get_row('tserver', 'id_server', $server_to_exec);
|
||||||
exec('ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_str.'"', $output, $rc);
|
|
||||||
|
if (empty($server_data['port'])) {
|
||||||
|
exec('ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_str.'"', $output, $rc);
|
||||||
|
} else {
|
||||||
|
exec('ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_str.'"', $output, $rc);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
exec($command_str, $output, $rc);
|
exec($command_str, $output, $rc);
|
||||||
}
|
}
|
||||||
|
@ -409,11 +409,20 @@ function snmp_browser_get_oid(
|
|||||||
|
|
||||||
if ($server_to_exec != 0) {
|
if ($server_to_exec != 0) {
|
||||||
$command_output = $snmptranslate_bin.' -m ALL -M +'.escapeshellarg($config['homedir'].'/attachment/mibs').' -Td '.escapeshellarg($oid);
|
$command_output = $snmptranslate_bin.' -m ALL -M +'.escapeshellarg($config['homedir'].'/attachment/mibs').' -Td '.escapeshellarg($oid);
|
||||||
exec(
|
|
||||||
'ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_output.'"',
|
if (empty($server_data['port'])) {
|
||||||
$translate_output,
|
exec(
|
||||||
$rc
|
'ssh pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_output.'"',
|
||||||
);
|
$translate_output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
exec(
|
||||||
|
'ssh -p '.$server_data['port'].' pandora_exec_proxy@'.$server_data['ip_address'].' "'.$command_output.'"',
|
||||||
|
$translate_output,
|
||||||
|
$rc
|
||||||
|
);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
exec(
|
exec(
|
||||||
$snmptranslate_bin.' -m ALL -M +'.escapeshellarg($config['homedir'].'/attachment/mibs').' -Td '.escapeshellarg($oid),
|
$snmptranslate_bin.' -m ALL -M +'.escapeshellarg($config['homedir'].'/attachment/mibs').' -Td '.escapeshellarg($oid),
|
||||||
|
@ -129,7 +129,7 @@
|
|||||||
<div style='height: 10px'>
|
<div style='height: 10px'>
|
||||||
<?php
|
<?php
|
||||||
$version = '7.0NG.742';
|
$version = '7.0NG.742';
|
||||||
$build = '200116';
|
$build = '200119';
|
||||||
$banner = "v$version Build $build";
|
$banner = "v$version Build $build";
|
||||||
|
|
||||||
error_reporting(0);
|
error_reporting(0);
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
# User and Group under which Apache is running
|
# User and Group under which Apache is running
|
||||||
%define httpd_name httpd
|
%define httpd_name httpd
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
# User and Group under which Apache is running
|
# User and Group under which Apache is running
|
||||||
%define httpd_name httpd
|
%define httpd_name httpd
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_console
|
%define name pandorafms_console
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
%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
|
||||||
|
@ -1020,6 +1020,7 @@ CREATE TABLE IF NOT EXISTS `tserver` (
|
|||||||
`server_keepalive` int(11) NOT NULL default 0,
|
`server_keepalive` int(11) NOT NULL default 0,
|
||||||
`stat_utimestamp` bigint(20) NOT NULL default '0',
|
`stat_utimestamp` bigint(20) NOT NULL default '0',
|
||||||
`exec_proxy` tinyint(1) UNSIGNED NOT NULL default 0,
|
`exec_proxy` tinyint(1) UNSIGNED NOT NULL default 0,
|
||||||
|
`port` int(5) unsigned NOT NULL default 0,
|
||||||
PRIMARY KEY (`id_server`),
|
PRIMARY KEY (`id_server`),
|
||||||
KEY `name` (`name`)
|
KEY `name` (`name`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
package: pandorafms-server
|
package: pandorafms-server
|
||||||
Version: 7.0NG.742-200116
|
Version: 7.0NG.742-200119
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Section: admin
|
Section: admin
|
||||||
|
@ -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.742-200116"
|
pandora_version="7.0NG.742-200119"
|
||||||
|
|
||||||
package_cpan=0
|
package_cpan=0
|
||||||
package_pandora=1
|
package_pandora=1
|
||||||
|
@ -163,7 +163,12 @@ wmiserver 1
|
|||||||
network_timeout 4
|
network_timeout 4
|
||||||
|
|
||||||
# Network timeout (in seconds) for timeout in remote execution commands (PANDORA FMS ENTERPRISE ONLY).
|
# 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).
|
# Remote execution modules, ssh_launcher extra option (PANDORA FMS ENTERPRISE ONLY).
|
||||||
ssh_launcher /usr/share/pandora_server/util/ssh_launcher.sh
|
ssh_launcher /usr/share/pandora_server/util/ssh_launcher.sh
|
||||||
|
@ -148,6 +148,14 @@ wmiserver 0
|
|||||||
|
|
||||||
network_timeout 5
|
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 (in seconds)
|
||||||
|
|
||||||
server_keepalive 45
|
server_keepalive 45
|
||||||
|
@ -45,7 +45,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.742";
|
my $pandora_version = "7.0NG.742";
|
||||||
my $pandora_build = "200116";
|
my $pandora_build = "200119";
|
||||||
our $VERSION = $pandora_version." ".$pandora_build;
|
our $VERSION = $pandora_version." ".$pandora_build;
|
||||||
|
|
||||||
# Setup hash
|
# Setup hash
|
||||||
@ -275,7 +275,8 @@ sub pandora_load_config {
|
|||||||
$pa_config->{"alert_recovery"} = 0; # Introduced on 1.3.1
|
$pa_config->{"alert_recovery"} = 0; # Introduced on 1.3.1
|
||||||
$pa_config->{"snmp_checks"} = 1; # 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->{"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->{"snmp_trapd"} = '/usr/sbin/snmptrapd'; # 3.0
|
||||||
$pa_config->{"tcp_checks"} = 1; # Introduced on 1.3.1
|
$pa_config->{"tcp_checks"} = 1; # Introduced on 1.3.1
|
||||||
$pa_config->{"tcp_timeout"} = 20; # 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) {
|
elsif ($parametro =~ m/^rcmd_timeout\s+([0-9]*)/i) {
|
||||||
$pa_config->{"rcmd_timeout"} = clean_blank($1);
|
$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) {
|
elsif ($parametro =~ m/^tcp_checks\s+([0-9]*)/i) {
|
||||||
$pa_config->{"tcp_checks"} = clean_blank($1);
|
$pa_config->{"tcp_checks"} = clean_blank($1);
|
||||||
}
|
}
|
||||||
|
@ -32,7 +32,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.742";
|
my $pandora_version = "7.0NG.742";
|
||||||
my $pandora_build = "200116";
|
my $pandora_build = "200119";
|
||||||
our $VERSION = $pandora_version." ".$pandora_build;
|
our $VERSION = $pandora_version." ".$pandora_build;
|
||||||
|
|
||||||
our %EXPORT_TAGS = ( 'all' => [ qw() ] );
|
our %EXPORT_TAGS = ( 'all' => [ qw() ] );
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_server
|
%define name pandorafms_server
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
Summary: Pandora FMS Server
|
Summary: Pandora FMS Server
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#
|
#
|
||||||
%define name pandorafms_server
|
%define name pandorafms_server
|
||||||
%define version 7.0NG.742
|
%define version 7.0NG.742
|
||||||
%define release 200116
|
%define release 200119
|
||||||
|
|
||||||
Summary: Pandora FMS Server
|
Summary: Pandora FMS Server
|
||||||
Name: %{name}
|
Name: %{name}
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
# **********************************************************************
|
# **********************************************************************
|
||||||
|
|
||||||
PI_VERSION="7.0NG.742"
|
PI_VERSION="7.0NG.742"
|
||||||
PI_BUILD="200116"
|
PI_BUILD="200119"
|
||||||
|
|
||||||
MODE=$1
|
MODE=$1
|
||||||
if [ $# -gt 1 ]; then
|
if [ $# -gt 1 ]; then
|
||||||
|
@ -34,7 +34,7 @@ use PandoraFMS::Config;
|
|||||||
use PandoraFMS::DB;
|
use PandoraFMS::DB;
|
||||||
|
|
||||||
# version: define current version
|
# version: define current version
|
||||||
my $version = "7.0NG.742 PS200116";
|
my $version = "7.0NG.742 PS200119";
|
||||||
|
|
||||||
# Pandora server configuration
|
# Pandora server configuration
|
||||||
my %conf;
|
my %conf;
|
||||||
|
@ -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.742 PS200116";
|
my $version = "7.0NG.742 PS200119";
|
||||||
|
|
||||||
# save program name for logging
|
# save program name for logging
|
||||||
my $progname = basename($0);
|
my $progname = basename($0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user