2008-06-24 Sancho Lerena <slerena@gmail.com>
* include/functions_db.php: Fixed typo. * include/languages/language_es_es.php: Too long string fixed. * operation/agentes/tactical.php: Div0 fixed. * godmode/agentes/agent_disk_conf_editor.php: Check should be done after reading (when updating file, because binary reads don't be afected by magic_quotes. This SHOULD fix the problem. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@898 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
9493c19c14
commit
77e88d3ebb
|
@ -1,3 +1,15 @@
|
||||||
|
2008-06-24 Sancho Lerena <slerena@gmail.com>
|
||||||
|
|
||||||
|
* include/functions_db.php: Fixed typo.
|
||||||
|
|
||||||
|
* include/languages/language_es_es.php: Too long string fixed.
|
||||||
|
|
||||||
|
* operation/agentes/tactical.php: Div0 fixed.
|
||||||
|
|
||||||
|
* godmode/agentes/agent_disk_conf_editor.php: Check should be done
|
||||||
|
after reading (when updating file, because binary reads don't be afected
|
||||||
|
by magic_quotes. This SHOULD fix the problem.
|
||||||
|
|
||||||
2008-06-23 Esteban Sanchez <estebans@artica.es>
|
2008-06-23 Esteban Sanchez <estebans@artica.es>
|
||||||
|
|
||||||
* include/functions_reporting.php: Do not show alert tables if there's
|
* include/functions_reporting.php: Do not show alert tables if there's
|
||||||
|
|
|
@ -27,7 +27,7 @@ function display_config () {
|
||||||
// Read configuration file
|
// Read configuration file
|
||||||
$file_name = $config["remote_config"] . "/" . $agent_md5 . ".conf";
|
$file_name = $config["remote_config"] . "/" . $agent_md5 . ".conf";
|
||||||
$file = fopen($file_name, "rb");
|
$file = fopen($file_name, "rb");
|
||||||
$agent_config = unsafe_string (fread($file, filesize($file_name)));
|
$agent_config = fread($file, filesize($file_name));
|
||||||
fclose($file);
|
fclose($file);
|
||||||
|
|
||||||
// Display it
|
// Display it
|
||||||
|
@ -48,7 +48,7 @@ function display_config () {
|
||||||
echo '<tr>';
|
echo '<tr>';
|
||||||
echo '<td class="datos2" colspan="2">';
|
echo '<td class="datos2" colspan="2">';
|
||||||
echo '<textarea class="conf_editor" name="disk_conf">';
|
echo '<textarea class="conf_editor" name="disk_conf">';
|
||||||
echo entrada_limpia($agent_config);
|
echo $agent_config;
|
||||||
echo '</textarea>';
|
echo '</textarea>';
|
||||||
echo '</td>';
|
echo '</td>';
|
||||||
echo '</tr>';
|
echo '</tr>';
|
||||||
|
@ -66,7 +66,8 @@ function display_config () {
|
||||||
// Saves the configuration and the md5 hash
|
// Saves the configuration and the md5 hash
|
||||||
function save_config ($agent_config) {
|
function save_config ($agent_config) {
|
||||||
global $agent_md5, $config;
|
global $agent_md5, $config;
|
||||||
|
|
||||||
|
$agent_config = unsafe_string ($agent_config);
|
||||||
// Save configuration
|
// Save configuration
|
||||||
$file = fopen($config["remote_config"] . "/" . $agent_md5 . ".conf", "wb");
|
$file = fopen($config["remote_config"] . "/" . $agent_md5 . ".conf", "wb");
|
||||||
fwrite($file, $agent_config);
|
fwrite($file, $agent_config);
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
// Begin of automatic config file
|
// Begin of automatic config file
|
||||||
$config["dbname"]="pandora"; // MySQL DataBase name
|
$config["dbname"]="pandora"; // MySQL DataBase name
|
||||||
$config["dbuser"]="pandora"; // DB User
|
$config["dbuser"]="pandora"; // DB User
|
||||||
$config["dbpass"]="pandora"; // DB Password
|
$config["dbpass"]="wrvjsevp"; // DB Password
|
||||||
$config["dbhost"]="localhost"; // DB Host
|
$config["dbhost"]="localhost"; // DB Host
|
||||||
$config["homedir"]="/var/www/pandora_console/"; // Config homedir
|
$config["homedir"]="/var/www/pandora_console/"; // Config homedir
|
||||||
$config["homeurl"]="http://localhost/pandora_console"; // Base URL
|
$config["homeurl"]="http://192.168.13.211/pandora_console"; // Base URL
|
||||||
|
|
||||||
// End of automatic config file
|
// End of automatic config file
|
||||||
?><?php
|
?><?php
|
||||||
|
|
|
@ -1571,7 +1571,7 @@ function return_moduledata_sum_value ($id_agent_module, $period, $date = 0) {
|
||||||
$last_data = "";
|
$last_data = "";
|
||||||
$total_badtime = 0;
|
$total_badtime = 0;
|
||||||
$module_interval = get_module_interval ($id_agent_module);
|
$module_interval = get_module_interval ($id_agent_module);
|
||||||
$timestamp_begin = $datelimit + module_interval;
|
$timestamp_begin = $datelimit + $module_interval;
|
||||||
$timestamp_end = 0;
|
$timestamp_end = 0;
|
||||||
$sum = 0;
|
$sum = 0;
|
||||||
$data_value = 0;
|
$data_value = 0;
|
||||||
|
|
|
@ -148,7 +148,7 @@ $lang_label["log_filter"]="Tipo de filtro de Log";
|
||||||
$lang_label["not_connected"]="No estás conectado/a";
|
$lang_label["not_connected"]="No estás conectado/a";
|
||||||
$lang_label["administrator"]="Administrador";
|
$lang_label["administrator"]="Administrador";
|
||||||
$lang_label["normal_user"]="Usuario estándar";
|
$lang_label["normal_user"]="Usuario estándar";
|
||||||
$lang_label["has_connected"]="Estás conectado/a como";
|
$lang_label["has_connected"]="Conectado";
|
||||||
$lang_label["logged_out"]="Desconectado/a";
|
$lang_label["logged_out"]="Desconectado/a";
|
||||||
$lang_label["logout_msg"]="La sesión ha finalizado. Cierre la ventana del navegador para cerrar la sesión de Pandora.<br><br>";
|
$lang_label["logout_msg"]="La sesión ha finalizado. Cierre la ventana del navegador para cerrar la sesión de Pandora.<br><br>";
|
||||||
$lang_label["user_last_activity"]="Última actividad en Pandora";
|
$lang_label["user_last_activity"]="Última actividad en Pandora";
|
||||||
|
|
|
@ -59,6 +59,8 @@
|
||||||
$data_health = format_numeric ( (($data_checks -($data_unknown + $data_alert)) / $data_checks ) * 100,1);;
|
$data_health = format_numeric ( (($data_checks -($data_unknown + $data_alert)) / $data_checks ) * 100,1);;
|
||||||
} else
|
} else
|
||||||
$data_health = 100;
|
$data_health = 100;
|
||||||
|
if ($data_health < 0)
|
||||||
|
$data_health =0;
|
||||||
if (($data_checks != 0) OR ($data_checks != 0)){
|
if (($data_checks != 0) OR ($data_checks != 0)){
|
||||||
$global_health = format_numeric ((($data_health * $data_checks) + ($monitor_health * $monitor_checks)) / $total_checks);
|
$global_health = format_numeric ((($data_health * $data_checks) + ($monitor_health * $monitor_checks)) / $total_checks);
|
||||||
} else
|
} else
|
||||||
|
|
Loading…
Reference in New Issue