Merge branch 'develop' of https://github.com/pandorafms/pandorafms into develop
This commit is contained in:
commit
892f14794d
|
@ -1,5 +1,5 @@
|
|||
package: pandorafms-agent-unix
|
||||
Version: 6.0dev-150623
|
||||
Version: 6.0dev-150624
|
||||
Architecture: all
|
||||
Priority: optional
|
||||
Section: admin
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
pandora_version="6.0dev-150623"
|
||||
pandora_version="6.0dev-150624"
|
||||
|
||||
echo "Test if you has the tools for to make the packages."
|
||||
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null
|
||||
|
|
|
@ -41,7 +41,7 @@ my $Sem = undef;
|
|||
my $ThreadSem = undef;
|
||||
|
||||
use constant AGENT_VERSION => '6.0dev';
|
||||
use constant AGENT_BUILD => '150623';
|
||||
use constant AGENT_BUILD => '150624';
|
||||
|
||||
# Commands to retrieve total memory information in kB
|
||||
use constant TOTALMEMORY_CMDS => {
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_agent_unix
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
|
||||
Summary: Pandora FMS Linux agent, PERL version
|
||||
Name: %{name}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_agent_unix
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
|
||||
Summary: Pandora FMS Linux agent, PERL version
|
||||
Name: %{name}
|
||||
|
|
|
@ -186,7 +186,7 @@ UpgradeApplicationID
|
|||
{}
|
||||
|
||||
Version
|
||||
{150623}
|
||||
{150624}
|
||||
|
||||
ViewReadme
|
||||
{Yes}
|
||||
|
|
|
@ -30,7 +30,7 @@ using namespace Pandora;
|
|||
using namespace Pandora_Strutils;
|
||||
|
||||
#define PATH_SIZE _MAX_PATH+1
|
||||
#define PANDORA_VERSION ("6.0dev(Build 150623)")
|
||||
#define PANDORA_VERSION ("6.0dev(Build 150624)")
|
||||
|
||||
string pandora_path;
|
||||
string pandora_dir;
|
||||
|
|
|
@ -11,7 +11,7 @@ BEGIN
|
|||
VALUE "LegalCopyright", "Artica ST"
|
||||
VALUE "OriginalFilename", "PandoraAgent.exe"
|
||||
VALUE "ProductName", "Pandora FMS Windows Agent"
|
||||
VALUE "ProductVersion", "(6.0dev(Build 150623))"
|
||||
VALUE "ProductVersion", "(6.0dev(Build 150624))"
|
||||
VALUE "FileVersion", "1.0.0.0"
|
||||
END
|
||||
END
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
package: pandorafms-console
|
||||
Version: 6.0dev-150623
|
||||
Version: 6.0dev-150624
|
||||
Architecture: all
|
||||
Priority: optional
|
||||
Section: admin
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
pandora_version="6.0dev-150623"
|
||||
pandora_version="6.0dev-150624"
|
||||
|
||||
package_pear=0
|
||||
package_pandora=1
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -112,7 +112,8 @@ if ($update) {
|
|||
$module_name = array();
|
||||
}
|
||||
foreach($module_name as $mod_name) {
|
||||
$result = process_manage_edit($mod_name['nombre'], $id_agent);
|
||||
$result = process_manage_edit($mod_name['nombre'],
|
||||
$id_agent);
|
||||
$count ++;
|
||||
$success += (int)$result;
|
||||
}
|
||||
|
@ -123,6 +124,8 @@ if ($update) {
|
|||
$agents_ = array();
|
||||
}
|
||||
|
||||
|
||||
|
||||
foreach ($agents_ as $agent_) {
|
||||
|
||||
if ($modules_ == false) {
|
||||
|
@ -141,12 +144,15 @@ if ($update) {
|
|||
"(" . $success . "/" . $count . ")",
|
||||
__('Could not be updated'));
|
||||
|
||||
$info = 'Modules: ' . json_encode($modules_) . ' Agents: ' . json_encode($agents_);
|
||||
$info = 'Modules: ' . json_encode($modules_) .
|
||||
' Agents: ' . json_encode($agents_);
|
||||
if ($success > 0) {
|
||||
db_pandora_audit("Massive management", "Edit module", false, false, $info);
|
||||
db_pandora_audit("Massive management", "Edit module", false,
|
||||
false, $info);
|
||||
}
|
||||
else {
|
||||
db_pandora_audit("Massive management", "Fail try to edit module", false, false, $info);
|
||||
db_pandora_audit("Massive management",
|
||||
"Fail try to edit module", false, false, $info);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -173,7 +179,8 @@ if (! $module_type) {
|
|||
$table->rowstyle['edit6'] = 'display: none';
|
||||
$table->rowstyle['edit7'] = 'display: none';
|
||||
}
|
||||
$agents = agents_get_group_agents (array_keys (users_get_groups ()), false, "none");
|
||||
$agents = agents_get_group_agents (array_keys (users_get_groups ()),
|
||||
false, "none");
|
||||
switch ($config["dbtype"]) {
|
||||
case "mysql":
|
||||
case "oracle":
|
||||
|
@ -216,10 +223,12 @@ $table->data = array ();
|
|||
|
||||
$table->data['selection_mode'][0] = __('Selection mode');
|
||||
$table->data['selection_mode'][1] = __('Select modules first') . ' ' .
|
||||
html_print_radio_button_extended ("selection_mode", 'modules', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true);
|
||||
html_print_radio_button_extended ("selection_mode", 'modules', '',
|
||||
$selection_mode, false, '', 'style="margin-right: 40px;"', true);
|
||||
$table->data['selection_mode'][2] = '';
|
||||
$table->data['selection_mode'][3] = __('Select agents first') . ' ' .
|
||||
html_print_radio_button_extended ("selection_mode", 'agents', '', $selection_mode, false, '', 'style="margin-right: 40px;"', true);
|
||||
html_print_radio_button_extended ("selection_mode", 'agents', '',
|
||||
$selection_mode, false, '', 'style="margin-right: 40px;"', true);
|
||||
|
||||
|
||||
|
||||
|
@ -235,7 +244,8 @@ $table->data['form_modules_1'][1] = html_print_select ($types,
|
|||
'module_type', '', false, __('Select'), -1, true, false, true);
|
||||
|
||||
$table->data['form_modules_1'][3] = __('Select all modules of this type') . ' ' .
|
||||
html_print_checkbox_extended ("force_type", 'type', '', '', false, '', 'style="margin-right: 40px;"', true);
|
||||
html_print_checkbox_extended ("force_type", 'type', '', '', false,
|
||||
'', 'style="margin-right: 40px;"', true);
|
||||
|
||||
$modules = array ();
|
||||
if ($module_type != '') {
|
||||
|
@ -263,7 +273,8 @@ $table->data['form_agents_1'][1] = html_print_select ($groups, 'groups_select',
|
|||
' ' . __('Group recursion') . ' ' .
|
||||
html_print_checkbox ("recursion", 1, false, true, false);
|
||||
$table->data['form_agents_1'][3] = __('Select all modules of this group') . ' ' .
|
||||
html_print_checkbox_extended ("force_group", 'group', '', '', false, '', 'style="margin-right: 40px;"', true);
|
||||
html_print_checkbox_extended ("force_group", 'group', '', '', false,
|
||||
'', 'style="margin-right: 40px;"', true);
|
||||
|
||||
|
||||
|
||||
|
@ -327,8 +338,8 @@ $table->data['edit1'][1] = '<table width="100%">';
|
|||
$table->data['edit1'][1] .= '<em>' . __('Min.') . '</em>';
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '<td align="right">';
|
||||
$table->data['edit1'][1] .= html_print_input_text('min_warning',
|
||||
'', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= html_print_input_text(
|
||||
'min_warning', '', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '</tr>';
|
||||
$table->data['edit1'][1] .= '<tr>';
|
||||
|
@ -336,25 +347,29 @@ $table->data['edit1'][1] = '<table width="100%">';
|
|||
$table->data['edit1'][1] .= '<em>' . __('Max.') . '</em>';
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '<td align="right">';
|
||||
$table->data['edit1'][1] .= html_print_input_text ('max_warning', '', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= html_print_input_text (
|
||||
'max_warning', '', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '</tr>';
|
||||
$table->data['edit1'][1] .= '<tr>';
|
||||
$table->data['edit1'][1] .= '<td>';
|
||||
$table->data['edit1'][1] .= '<em>'.__('Str.').'</em>';
|
||||
$table->data['edit1'][1] .= '<em>' . __('Str.') . '</em>';
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '<td align="right">';
|
||||
$table->data['edit1'][1] .= html_print_input_text ('str_warning', '', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= html_print_input_text (
|
||||
'str_warning', '', '', 5, 15, true);
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '</tr>';
|
||||
$table->data['edit1'][1] .= '<tr>';
|
||||
$table->data['edit1'][1] .= '<td>';
|
||||
$table->data['edit1'][1] .= '<em>'.__('Inverse interval').'</em>';
|
||||
$table->data['edit1'][1] .= '<em>' .
|
||||
__('Inverse interval') . '</em>';
|
||||
$table->data['edit1'][1] .= '</td>';
|
||||
$table->data['edit1'][1] .= '<td align="right">';
|
||||
$table->data['edit1'][1] .=
|
||||
html_print_select(
|
||||
array('' => __('No change'),
|
||||
array(
|
||||
'' => __('No change'),
|
||||
'1' => __('Yes'),
|
||||
'0' => __('No')),
|
||||
'warning_inverse','','','', '', true);
|
||||
|
@ -369,8 +384,8 @@ $table->data['edit1'][3] = '<table width="100%">';
|
|||
$table->data['edit1'][3] .= '<em>' . __('Min.') . '</em>';
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '<td align="right">';
|
||||
$table->data['edit1'][3] .= html_print_input_text('min_critical',
|
||||
'', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= html_print_input_text(
|
||||
'min_critical', '', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '</tr>';
|
||||
$table->data['edit1'][3] .= '<tr>';
|
||||
|
@ -378,7 +393,8 @@ $table->data['edit1'][3] = '<table width="100%">';
|
|||
$table->data['edit1'][3] .= '<em>' . __('Max.') . '</em>';
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '<td align="right">';
|
||||
$table->data['edit1'][3] .= html_print_input_text ('max_critical', '', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= html_print_input_text(
|
||||
'max_critical', '', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '</tr>';
|
||||
$table->data['edit1'][3] .= '<tr>';
|
||||
|
@ -386,12 +402,14 @@ $table->data['edit1'][3] = '<table width="100%">';
|
|||
$table->data['edit1'][3] .= '<em>'.__('Str.').'</em>';
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '<td align="right">';
|
||||
$table->data['edit1'][3] .= html_print_input_text ('str_critical', '', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= html_print_input_text(
|
||||
'str_critical', '', '', 5, 15, true);
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '</tr>';
|
||||
$table->data['edit1'][3] .= '<tr>';
|
||||
$table->data['edit1'][3] .= '<td>';
|
||||
$table->data['edit1'][3] .= '<em>'.__('Inverse interval').'</em>';
|
||||
$table->data['edit1'][3] .= '<em>' .
|
||||
__('Inverse interval') . '</em>';
|
||||
$table->data['edit1'][3] .= '</td>';
|
||||
$table->data['edit1'][3] .= '<td align="right">';
|
||||
$table->data['edit1'][3] .=
|
||||
|
@ -405,27 +423,40 @@ $table->data['edit1'][3] = '<table width="100%">';
|
|||
$table->data['edit1'][3] .= '</table>';
|
||||
|
||||
$table->data['edit1_1'][0] = '<b>'.__('Description'). '</b>';
|
||||
$table->data['edit1_1'][1] = html_print_textarea ('descripcion', 2, 50, '', '', true);
|
||||
$table->data['edit1_1'][1] = html_print_textarea ('descripcion', 2, 50,
|
||||
'', '', true);
|
||||
$table->colspan['edit1_1'][1] = 3;
|
||||
|
||||
$table->data['edit2'][0] = __('Interval');
|
||||
$table->data['edit2'][1] = html_print_extended_select_for_time ('module_interval', 0, '', __('No change'), '0', 10, true, 'width: 150px');
|
||||
$table->data['edit2'][1] = html_print_extended_select_for_time(
|
||||
'module_interval', 0, '', __('No change'), '0', 10, true, 'width: 150px');
|
||||
$table->data['edit2'][2] = __('Disabled');
|
||||
$table->data['edit2'][3] = html_print_select(array('' => __('No change'), '1' => __('Yes'), '0' => __('No')),'disabled','','','', '', true);
|
||||
$table->data['edit2'][3] = html_print_select(
|
||||
array(
|
||||
'' => __('No change'),
|
||||
'1' => __('Yes'),
|
||||
'0' => __('No')),
|
||||
'disabled', '', '', '', '', true);
|
||||
|
||||
$table->data['edit3'][0] = __('Post process') .
|
||||
ui_print_help_icon ('postprocess', true);
|
||||
$table->data['edit3'][1] = html_print_input_text ('post_process', '', '', 10, 15, true);
|
||||
$table->data['edit3'][1] = html_print_input_text ('post_process', '',
|
||||
'', 10, 15, true);
|
||||
$table->data['edit3'][2] = __('SMNP community');
|
||||
$table->data['edit3'][3] = html_print_input_text ('snmp_community', '', '', 10, 15, true);
|
||||
$table->data['edit3'][3] = html_print_input_text ('snmp_community', '',
|
||||
'', 10, 15, true);
|
||||
|
||||
$table->data['edit35'][0] = __('Target IP');
|
||||
$table->data['edit35'][1] = html_print_input_text ('ip_target', '', '', 15, 60, true);
|
||||
$table->data['edit35'][1] = html_print_input_text ('ip_target', '', '',
|
||||
15, 60, true);
|
||||
$table->data['edit35'][2] = __('SNMP version');
|
||||
$table->data['edit35'][3] = html_print_select ($snmp_versions, 'tcp_send', '', '', __('No change'), '', true, false, false, '');
|
||||
$table->data['edit35'][3] = html_print_select ($snmp_versions,
|
||||
'tcp_send', '', '', __('No change'), '', true, false, false, '');
|
||||
$table->data['edit36'][0] = __('Auth user');
|
||||
$table->data['edit36'][1] = html_print_input_text ('plugin_user_snmp', '', '', 15, 60, true);
|
||||
$table->data['edit36'][2] = __('Auth password') . ui_print_help_tip(__("The pass length must be eight character minimum."), true);
|
||||
$table->data['edit36'][1] = html_print_input_text ('plugin_user_snmp',
|
||||
'', '', 15, 60, true);
|
||||
$table->data['edit36'][2] = __('Auth password') .
|
||||
ui_print_help_tip(__("The pass length must be eight character minimum."), true);
|
||||
$table->data['edit36'][3] = html_print_input_text ('plugin_pass_snmp', '', '', 15, 60, true);
|
||||
$table->data['edit37'][0] = __('Privacy method');
|
||||
$table->data['edit37'][1] = html_print_select(array('DES' => __('DES'), 'AES' => __('AES')), 'custom_string_1', '', '', __('No change'), '', true);
|
||||
|
@ -922,6 +953,7 @@ $(document).ready (function () {
|
|||
</script>
|
||||
<?php
|
||||
function process_manage_edit ($module_name, $agents_select = null) {
|
||||
|
||||
if (is_int ($module_name) && $module_name < 0) {
|
||||
ui_print_error_message(__('No modules selected'));
|
||||
|
||||
|
@ -1026,7 +1058,7 @@ function process_manage_edit ($module_name, $agents_select = null) {
|
|||
else {
|
||||
$modules = db_get_all_rows_filter ('tagente_modulo',
|
||||
array ('id_agente' => $agents_select,
|
||||
'nombre' => io_safe_input($module_name)),
|
||||
'nombre' => $module_name),
|
||||
array ('id_agente_modulo'));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -140,25 +140,33 @@ if ($option == '') {
|
|||
$option = array_shift(array_keys($options));
|
||||
}
|
||||
|
||||
$alertstab = array('text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_alerts">'
|
||||
. html_print_image ('images/op_alerts.png', true,
|
||||
array ('title' => __('Alerts operations')))
|
||||
. '</a>', 'active' => $tab == 'massive_alerts');
|
||||
$alertstab = array(
|
||||
'text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_alerts">'
|
||||
. html_print_image ('images/op_alerts.png', true,
|
||||
array ('title' => __('Alerts operations')))
|
||||
. '</a>',
|
||||
'active' => $tab == 'massive_alerts');
|
||||
|
||||
$userstab = array('text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_users">'
|
||||
. html_print_image ('images/op_workspace.png', true,
|
||||
array ('title' => __('Users operations')))
|
||||
. '</a>', 'active' => $tab == 'massive_users');
|
||||
$userstab = array(
|
||||
'text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_users">'
|
||||
. html_print_image ('images/op_workspace.png', true,
|
||||
array ('title' => __('Users operations')))
|
||||
. '</a>',
|
||||
'active' => $tab == 'massive_users');
|
||||
|
||||
$agentstab = array('text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_agents">'
|
||||
. html_print_image ('images/bricks.png', true,
|
||||
array ('title' => __('Agents operations')))
|
||||
. '</a>', 'active' => $tab == 'massive_agents');
|
||||
$agentstab = array(
|
||||
'text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_agents">'
|
||||
. html_print_image ('images/bricks.png', true,
|
||||
array ('title' => __('Agents operations')))
|
||||
. '</a>',
|
||||
'active' => $tab == 'massive_agents');
|
||||
|
||||
$modulestab = array('text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_modules">'
|
||||
. html_print_image ('images/brick.png', true,
|
||||
array ('title' => __('Modules operations')))
|
||||
. '</a>', 'active' => $tab == 'massive_modules');
|
||||
$modulestab = array(
|
||||
'text' => '<a href="index.php?sec=gmassive&sec2=godmode/massive/massive_operations&tab=massive_modules">'
|
||||
. html_print_image ('images/brick.png', true,
|
||||
array ('title' => __('Modules operations')))
|
||||
. '</a>',
|
||||
'active' => $tab == 'massive_modules');
|
||||
|
||||
|
||||
|
||||
|
@ -213,7 +221,8 @@ $submit_template_standby = get_parameter('id_alert_template_standby');
|
|||
$submit_add = get_parameter('crtbutton');
|
||||
|
||||
echo '<div id="loading" display="none">';
|
||||
echo html_print_image("images/wait.gif", true, array("border" => '0')) . '<br />';
|
||||
echo html_print_image("images/wait.gif", true, array("border" => '0')) .
|
||||
'<br />';
|
||||
echo '<strong>' . __('Please wait...') . '</strong>';
|
||||
echo '</div>';
|
||||
?>
|
||||
|
@ -245,14 +254,19 @@ echo '</div>';
|
|||
<?php
|
||||
echo "<br />";
|
||||
echo '<form method="post" id="form_options" action="index.php?sec=gmassive&sec2=godmode/massive/massive_operations">';
|
||||
echo '<table border="0"><tr><td>';
|
||||
echo '<table border="0">';
|
||||
echo '<tr>';
|
||||
echo '<td>';
|
||||
echo __("Action");
|
||||
echo '</td><td>';
|
||||
echo '</td>';
|
||||
echo '<td>';
|
||||
html_print_select($options, 'option', $option, 'this.form.submit()', '',
|
||||
0, false, false, false);
|
||||
if ($option == 'edit_agents' || $option == 'edit_modules')
|
||||
ui_print_help_tip(__("The blank fields will not be updated"));
|
||||
echo '</td></tr></table>';
|
||||
echo '</td>';
|
||||
echo '</tr>';
|
||||
echo '</table>';
|
||||
echo '</form>';
|
||||
echo "<br />";
|
||||
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
global $config;
|
||||
|
||||
require_once ($config['homedir'] . '/include/functions_custom_graphs.php');
|
||||
require_once ($config['homedir'] . '/include/db/oracle.php');
|
||||
|
||||
// Login check
|
||||
check_login ();
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
/**
|
||||
* Pandora build version and version
|
||||
*/
|
||||
$build_version = 'PC150623';
|
||||
$build_version = 'PC150624';
|
||||
$pandora_version = 'v6.0dev';
|
||||
|
||||
// Do not overwrite default timezone set if defined.
|
||||
|
|
|
@ -465,7 +465,7 @@ function config_update_config () {
|
|||
if (!config_update_value ('type_module_charts', (string) get_parameter('type_module_charts', 'area')))
|
||||
$error_update[] = __('Default type of module charts.');
|
||||
if (!config_update_value ('render_proc', (bool) get_parameter('render_proc', false)))
|
||||
$error_update[] = __('Render data of module type is proc.');
|
||||
$error_update[] = __('Display proc modules in binary format (OK/FAIL)');
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -63,7 +63,7 @@
|
|||
<div style='height: 10px'>
|
||||
<?php
|
||||
$version = '6.0dev';
|
||||
$build = '150623';
|
||||
$build = '150624';
|
||||
$banner = "v$version Build $build";
|
||||
|
||||
error_reporting(0);
|
||||
|
@ -562,6 +562,9 @@ function install_step2() {
|
|||
else if (PHP_OS == "NetBSD") {
|
||||
$res += check_exists ("/usr/pkg/bin/twopi","Graphviz Binary");
|
||||
}
|
||||
else if ( substr(PHP_OS, 0, 3) == 'WIN' ) {
|
||||
$res += check_exists ("..\\..\\..\\Graphviz\\bin\\twopi.exe", "Graphviz Binary");
|
||||
}
|
||||
else {
|
||||
$res += check_exists ("/usr/bin/twopi","Graphviz Binary");
|
||||
}
|
||||
|
|
|
@ -109,8 +109,16 @@ else {
|
|||
io_safe_output($config['graphviz_bin_dir'] . "/")
|
||||
:
|
||||
"";
|
||||
$is_windows = strtoupper(substr(PHP_OS, 0, 3)) == 'WIN';
|
||||
if ($is_windows) {
|
||||
$graphviz_path = str_replace("/", "\\", $graphviz_path );
|
||||
$filter = $filter . '.exe';
|
||||
}
|
||||
|
||||
$cmd = escapeshellarg($graphviz_path.$filter) . " -Tcmapx " . escapeshellarg("-o$filename_map") . " -Tpng ". escapeshellarg("-o$filename_img") . " " . escapeshellarg($filename_dot);
|
||||
$cmd = escapeshellarg($graphviz_path.$filter) . " -Tcmapx " .
|
||||
escapeshellarg("-o$filename_map") . " -Tpng ".
|
||||
escapeshellarg("-o$filename_img") . " " .
|
||||
escapeshellarg($filename_dot);
|
||||
$result = system ($cmd);
|
||||
fclose ($fh);
|
||||
unlink ($filename_dot);
|
||||
|
@ -128,7 +136,10 @@ if ($result !== false) {
|
|||
return;
|
||||
}
|
||||
echo "<div style='text-align:center'>";
|
||||
$image_url = str_replace(realpath(io_safe_output($config['homedir'])), "", realpath($filename_img));
|
||||
if ($is_windows)
|
||||
$image_url = str_replace('\\',"/",str_replace($config['homedir'], "", $filename_img));
|
||||
else
|
||||
$image_url = str_replace(realpath(io_safe_output($config['homedir'])), "", realpath($filename_img));
|
||||
html_print_image ($image_url, false, array ("alt" => __('Network map'), "usemap" => "#networkmap"));
|
||||
echo "</div>";
|
||||
require ($filename_map);
|
||||
|
|
|
@ -114,13 +114,20 @@ else {
|
|||
io_safe_output($config['graphviz_bin_dir'] . "/")
|
||||
:
|
||||
"";
|
||||
|
||||
$is_windows = strtoupper(substr(PHP_OS, 0, 3)) == 'WIN';
|
||||
if ($is_windows) {
|
||||
$graphviz_path = str_replace("/", "\\", $graphviz_path );
|
||||
$filename_map = str_replace("/", "\\", $filename_map );
|
||||
$filename_img = str_replace("/", "\\", $filename_img );
|
||||
$filename_dot = str_replace("/", "\\", $filename_dot );
|
||||
$filter = $filter . '.exe';
|
||||
}
|
||||
$cmd = escapeshellarg($graphviz_path . $filter) .
|
||||
" -Tcmapx " . escapeshellarg("-o$filename_map") .
|
||||
" -Tpng ". escapeshellarg("-o$filename_img") .
|
||||
" " . escapeshellarg($filename_dot);
|
||||
|
||||
$result = system ($cmd);
|
||||
|
||||
fclose ($fh);
|
||||
unlink ($filename_dot);
|
||||
//~ html_debug_print($cmd);
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_console
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
|
||||
# User and Group under which Apache is running
|
||||
%define httpd_name httpd
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_console
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
%define httpd_name httpd
|
||||
# User and Group under which Apache is running
|
||||
%define httpd_name apache2
|
||||
|
|
|
@ -38,7 +38,7 @@ INSERT INTO `tconfig` (`token`, `value`) VALUES
|
|||
('graph_res','5'),
|
||||
('step_compact','1'),
|
||||
('db_scheme_version','6.0dev'),
|
||||
('db_scheme_build','PD150623'),
|
||||
('db_scheme_build','PD150624'),
|
||||
('show_unknown','0'),
|
||||
('show_lastalerts','1'),
|
||||
('style','pandora'),
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
package: pandorafms-server
|
||||
Version: 6.0dev-150623
|
||||
Version: 6.0dev-150624
|
||||
Architecture: all
|
||||
Priority: optional
|
||||
Section: admin
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
pandora_version="6.0dev-150623"
|
||||
pandora_version="6.0dev-150624"
|
||||
|
||||
package_cpan=0
|
||||
package_pandora=1
|
||||
|
|
|
@ -43,7 +43,7 @@ our @EXPORT = qw(
|
|||
|
||||
# version: Defines actual version of Pandora Server for this module only
|
||||
my $pandora_version = "6.0dev";
|
||||
my $pandora_build = "150623";
|
||||
my $pandora_build = "150624";
|
||||
our $VERSION = $pandora_version." ".$pandora_build;
|
||||
|
||||
# Setup hash
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_server
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
|
||||
Summary: Pandora FMS Server
|
||||
Name: %{name}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#
|
||||
%define name pandorafms_server
|
||||
%define version 6.0dev
|
||||
%define release 150623
|
||||
%define release 150624
|
||||
|
||||
Summary: Pandora FMS Server
|
||||
Name: %{name}
|
||||
|
|
|
@ -33,7 +33,7 @@ use PandoraFMS::Tools;
|
|||
use PandoraFMS::DB;
|
||||
|
||||
# version: define current version
|
||||
my $version = "6.0dev PS150623";
|
||||
my $version = "6.0dev PS150624";
|
||||
|
||||
# Pandora server configuration
|
||||
my %conf;
|
||||
|
|
|
@ -35,7 +35,7 @@ use Encode::Locale;
|
|||
Encode::Locale::decode_argv;
|
||||
|
||||
# version: define current version
|
||||
my $version = "6.0dev PS150623";
|
||||
my $version = "6.0dev PS150624";
|
||||
|
||||
# save program name for logging
|
||||
my $progname = basename($0);
|
||||
|
|
Loading…
Reference in New Issue