2007-10-12 18:27:50 +02:00
< ? PHP
2008-07-25 20:37:32 +02:00
// Pandora FMS - the Flexible Monitoring System
// ============================================
2008-04-01 15:53:11 +02:00
// Copyright (c) 2008 Artica Soluciones Tecnológicas, http://www.artica.es
2008-01-10 17:40:00 +01:00
// Please see http://pandora.sourceforge.net for full contribution list
2006-03-27 05:37:27 +02:00
2008-04-01 15:53:11 +02:00
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation for version 2.
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
2006-03-27 05:37:27 +02:00
require ( " include/config.php " );
2008-06-19 02:24:05 +02:00
check_login ();
2006-03-27 05:37:27 +02:00
2008-06-19 02:24:05 +02:00
if ( isset ( $_GET [ " id_agente " ])){
$id_agente = $_GET [ " id_agente " ];
}
2006-03-27 05:37:27 +02:00
2008-06-19 02:24:05 +02:00
// View last data packet
// Get timestamp of last packet
$sql_t = 'SELECT * FROM tagente WHERE id_agente = ' . $id_agente ;
$result_t = mysql_query ( $sql_t );
$row_t = mysql_fetch_array ( $result_t );
$timestamp_ref = $row_t [ " ultimo_contacto_remoto " ];
$timestamp_lof = $row_t [ " ultimo_contacto " ];
$intervalo_agente = $row_t [ " intervalo " ];
2006-03-27 05:37:27 +02:00
2008-06-19 02:24:05 +02:00
// Get last packet
2008-08-05 13:42:08 +02:00
$sql3 = 'SELECT * FROM tagente_modulo, tagente_estado WHERE tagente_modulo.disabled = 0 AND tagente_modulo.id_agente = ' . $id_agente . ' AND tagente_estado.utimestamp != 0 AND tagente_modulo.id_agente_modulo = tagente_estado.id_agente_modulo ORDER BY id_module_group, nombre' ;
$label_group = 0 ;
2008-06-19 02:24:05 +02:00
$last_label = " " ;
2008-08-05 13:42:08 +02:00
// Title
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
echo " <h2> " . __ ( 'ag_title' ) . " > " ;
echo __ ( 'last_data_chunk' );
2008-08-05 13:42:08 +02:00
echo " <a href='index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente= $id_agente &tab=data'><img src='images/refresh.png'></A> " ;
echo " </h2> " ;
2008-06-19 02:24:05 +02:00
$result3 = mysql_query ( $sql3 );
if ( mysql_num_rows ( $result3 )) {
2007-05-18 14:56:05 +02:00
echo " <table width='750' cellpadding='3' cellspacing='3' class='databox'> " ;
echo " <th></th> " ;
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
echo " <th> " . __ ( 'module_name' ) . " </th> " ;
echo " <th> " . __ ( 'type' ) . " </th> " ;
echo " <th> " . __ ( 'int' ) . " </th> " ;
echo " <th> " . __ ( 'description' ) . " </th> " ;
echo " <th> " . __ ( 'data' ) . " </th> " ;
echo " <th> " . __ ( 'graph' ) . " </th> " ;
echo " <th> " . __ ( 'raw_data' ) . " </th> " ;
echo " <th> " . __ ( 'timestamp' ) . " </th> " ;
2007-03-28 18:07:29 +02:00
$texto = '' ; $last_modulegroup = 0 ;
2006-07-01 03:48:56 +02:00
$color = 1 ;
2006-03-27 05:37:27 +02:00
while ( $row3 = mysql_fetch_array ( $result3 )){
2008-06-19 02:24:05 +02:00
// Calculate table line color
if ( $color == 1 ){
$tdcolor = " datos " ;
$color = 0 ;
}
else {
$tdcolor = " datos2 " ;
$color = 1 ;
}
if ( $row3 [ " id_module_group " ] != $last_modulegroup ){
// Render module group names (fixed code)
2006-03-27 05:37:27 +02:00
$nombre_grupomodulo = dame_nombre_grupomodulo ( $row3 [ " id_module_group " ]);
2008-06-19 02:24:05 +02:00
$last_modulegroup = $row3 [ " id_module_group " ];
echo " <tr><td class='datos3' align='center' colspan='9'>
< b > " . $nombre_grupomodulo . " </ b ></ td ></ tr > " ;
}
// Begin to render data ...
echo " <tr><td class=' $tdcolor '> " ;
// Render network exec module button, only when
// Agent Write for this module and group, is given
// Is a network module
// Has flag = 0
$id_grupo = $row_t [ " id_grupo " ];
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
if ( give_acl ( $config [ 'id_user' ], $id_grupo , " AW " )) {
2008-06-19 02:24:05 +02:00
if (( $row3 [ " id_modulo " ] > 1 ) AND ( $row3 [ " id_tipo_modulo " ] < 100 )) {
if ( $row3 [ " flag " ] == 0 ){
echo " <a href='index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente= " . $id_agente . " &id_agente_modulo= " . $row3 [ " id_agente_modulo " ] . " &flag=1&tab=data&refr=60'><img src='images/target.png' border='0'></a> " ;
} else {
echo " <a href='index.php?sec=estado&sec2=operation/agentes/ver_agente&id_agente= " . $id_agente . " &id_agente_modulo= " . $row3 [ " id_agente_modulo " ] . " &tab=data&refr=60'><img src='images/refresh.png' border='0'></a> " ;
2006-03-27 05:37:27 +02:00
}
2008-06-19 02:24:05 +02:00
}
}
echo " </td> " ;
$nombre_grupomodulo = dame_nombre_grupomodulo ( $row3 [ " id_module_group " ]);
if ( $nombre_grupomodulo != " " ){
if (( $label_group == 0 ) || ( $last_label != $nombre_grupomodulo )){ // Show label module group
$label_group = - 1 ;
$last_label = $nombre_grupomodulo ;
$texto = $texto . "
< td class = '$tdcolor' align = 'center' colspan = '7' >
< b > " . $nombre_grupomodulo . " </ b ></ td > " ;
2006-03-27 05:37:27 +02:00
}
2008-06-19 02:24:05 +02:00
}
$nombre_tipo_modulo = dame_nombre_tipo_modulo ( $row3 [ " id_tipo_modulo " ]);
echo " <td class=' " . $tdcolor . " _id' title=' " . salida_limpia ( $row3 [ " nombre " ]) . " '> " ;
echo salida_limpia ( substr ( $row3 [ " nombre " ], 0 , 15 ));
echo " </td><td class=' " . $tdcolor . " '> " ;
echo " <img src='images/ " . show_icon_type ( $row3 [ " id_tipo_modulo " ]) . " ' border=0> " ;
echo " </td><td class=' " . $tdcolor . " '> " ;
if ( $row3 [ " module_interval " ] != 0 ){
echo $row3 [ " module_interval " ];
$real_interval = $row3 [ " module_interval " ];
} else {
echo $intervalo_agente ;
$real_interval = $intervalo_agente ;
}
if (( $row3 [ " id_tipo_modulo " ] != 3 )
AND ( $row3 [ " id_tipo_modulo " ] != 10 )
AND ( $row3 [ " id_tipo_modulo " ] != 17 )
AND ( $row3 [ " id_tipo_modulo " ] != 23 )){
echo " </td><td class=' " . $tdcolor . " f9' title=' " . salida_limpia ( $row3 [ " descripcion " ]) . " '> " ;
echo salida_limpia ( substr ( $row3 [ " descripcion " ], 0 , 32 ));
2006-03-27 05:37:27 +02:00
if ( strlen ( $row3 [ " descripcion " ]) > 32 ){
echo " ... " ;
}
2008-06-19 02:24:05 +02:00
echo " </td> " ;
}
if ( $row3 [ " id_tipo_modulo " ] == 100 ) {
echo " <td class=' " . $tdcolor . " f9' colspan='2' title=' " . $row3 [ " datos " ] . " '> " ;
echo substr ( salida_limpia ( $row3 [ " datos " ]), 0 , 12 );
} else {
// String uses colspan2 and different graphtype
if (( $row3 [ " id_tipo_modulo " ] == 3 )
OR ( $row3 [ " id_tipo_modulo " ] == 10 )
OR ( $row3 [ " id_tipo_modulo " ] == 17 )
OR ( $row3 [ " id_tipo_modulo " ] == 23 )){
$graph_type = " string " ;
echo " <td class=' " . $tdcolor . " f9' colspan=2 title=' " . salida_limpia ( $row3 [ " datos " ]) . " '> " ;
}
elseif (( $row3 [ " id_tipo_modulo " ] == 2 )
OR ( $row3 [ " id_tipo_modulo " ] == 6 )
OR ( $row3 [ " id_tipo_modulo " ] == 21 )
OR ( $row3 [ " id_tipo_modulo " ] == 18 )
OR ( $row3 [ " id_tipo_modulo " ] == 9 )) {
$graph_type = " boolean " ;
echo " <td class= " . $tdcolor . " > " ;
}
else {
$graph_type = " sparse " ;
2006-11-22 19:26:23 +01:00
echo " <td class= " . $tdcolor . " > " ;
2008-06-19 02:24:05 +02:00
}
2007-04-18 11:58:26 +02:00
2008-06-19 02:24:05 +02:00
// Kind of data
if ( is_numeric ( $row3 [ " datos " ])) {
$mytempdata = fmod ( $row3 [ " datos " ], 1 );
if ( $mytempdata == 0 )
$myvalue = intval ( $row3 [ " datos " ]);
2007-08-06 13:44:49 +02:00
else
2008-06-19 02:24:05 +02:00
$myvalue = $row3 [ " datos " ];
echo format_for_graph ( $myvalue );
} else
echo substr ( salida_limpia ( $row3 [ " datos " ]), 0 , 42 );
2006-03-27 05:37:27 +02:00
2008-06-19 02:24:05 +02:00
$handle = " stat " . $nombre_tipo_modulo . " _ " . $row3 [ " id_agente_modulo " ];
$url = 'reporting/procesos.php?agente=' . $row3 [ " id_agente_modulo " ];
$win_handle = dechex ( crc32 ( $row3 [ " id_agente_modulo " ] . $row3 [ " nombre " ]));
echo " <td class= " . $tdcolor . " width='78'> " ;
$graph_label = output_clean_strict ( $row3 [ " nombre " ]);
2006-03-27 05:37:27 +02:00
2008-06-19 02:24:05 +02:00
echo " <a href='javascript:winopeng( \" reporting/stat_win.php?type= $graph_type &period=2419200&id= " . $row3 [ " id_agente_modulo " ] . " &label= " . $graph_label . " refresh=180000 \" , \" month_ " . $win_handle . " \" )'><img src='images/grafica_m.png' border=0></a> " ;
$link = " winopeng('reporting/stat_win.php?type= $graph_type &period=604800&id= " . $row3 [ " id_agente_modulo " ] . " &label= " . $graph_label . " &refresh=6000','week_ " . $win_handle . " ') " ;
echo '<a href="javascript:' . $link . '"><img src="images/grafica_w.png" border=0></a> ' ;
$link = " winopeng('reporting/stat_win.php?type= $graph_type &period=86400&id= " . $row3 [ " id_agente_modulo " ] . " &label= " . $graph_label . " &refresh=600','day_ " . $win_handle . " ') " ;
echo '<a href="javascript:' . $link . '"><img src="images/grafica_d.png" border=0></a> ' ;
$link = " winopeng('reporting/stat_win.php?type= $graph_type &period=3600&id= " . $row3 [ " id_agente_modulo " ] . " &label= " . $graph_label . " &refresh=60','hour_ " . $win_handle . " ') " ;
echo '<a href="javascript:' . $link . '"><img src="images/grafica_h.png" border=0></a>' ;
}
// RAW Table data
echo " <td class= " . $tdcolor . " width=70> " ;
echo " <a href='index.php?sec=estado&sec2=operation/agentes/datos_agente&tipo=mes&id= " . $row3 [ " id_agente_modulo " ] . " '><img border=0 src='images/data_m.png'></a> " ;
echo " <a href='index.php?sec=estado&sec2=operation/agentes/datos_agente&tipo=semana&id= " . $row3 [ " id_agente_modulo " ] . " '><img border=0 src='images/data_w.png'></a> " ;
echo " <a href='index.php?sec=estado&sec2=operation/agentes/datos_agente&tipo=dia&id= " . $row3 [ " id_agente_modulo " ] . " '><img border=0 src='images/data_d.png'></a> " ;
echo " <td class=' " . $tdcolor . " f9'> " ;
if ( $row3 [ " timestamp " ] == " 0000-00-00 00:00:00 " ){
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
echo __ ( 'never' );
2008-06-19 02:24:05 +02:00
} else {
$ahora = time ();
2008-07-25 20:37:32 +02:00
// Async modules
2008-07-08 22:30:15 +02:00
if (( $row3 [ " id_tipo_modulo " ] > 20 ) AND ( $row3 [ " id_tipo_modulo " ] < 100 )){
echo human_time_comparation ( $row3 [ " timestamp " ]);
} else {
if ( ( $ahora - $row3 [ " utimestamp " ]) > ( $real_interval * 2 )) {
echo " <font color='red'> " ;
echo human_time_comparation ( $row3 [ " timestamp " ]);
echo " </font> " ;
} else
echo human_time_comparation ( $row3 [ " timestamp " ]);
}
2008-06-19 02:24:05 +02:00
}
echo " </td></tr> " ;
}
echo '</table>' ;
2006-03-27 05:37:27 +02:00
}
2006-12-08 17:57:43 +01:00
else {
2008-08-11 Esteban Sanchez <estebans@artica.es>
* include/functions_db.php: Added __ as an alias of lang_string().
* include/functions_reporting_pdf.php,
include/functions_reporting.php, include/functions.php,
include/functions_visual_map.php, index.php,
operation/incidents/incident.php,
operation/incidents/incident_detail.php,
operation/incidents/incident_note.php,
operation/incidents/incident_search.php,
operation/incidents/incident_statistics.php,
operation/snmpconsole/snmp_alert.php,
operation/snmpconsole/snmp_view.php, operation/users/user.php,
operation/users/user_edit.php, operation/users/user_statistics.php,
operation/events/event_statistics.php, operation/events/events.php,
operation/visual_console/render_view.php,
operation/visual_console/index.php, operation/extensions.php,
operation/agentes/estado_alertas.php,
operation/agentes/status_monitor.php,
operation/agentes/estado_grupo.php, operation/agentes/export_csv.php,
operation/agentes/datos_agente.php,
operation/agentes/estado_ultimopaquete.php,
operation/agentes/estado_generalagente.php,
operation/agentes/estado_agente.php, operation/agentes/bulbs.php,
operation/agentes/status_events.php, operation/agentes/sla_view.php,
operation/agentes/exportdata.php,
operation/agentes/estado_monitores.php,
operation/agentes/ver_agente.php, operation/agentes/estadisticas.php,
operation/agentes/tactical.php, operation/agentes/networkmap.php,
operation/messages/message.php,
operation/reporting/reporting_viewer.php,
operation/reporting/graph_viewer.php,
operation/reporting/custom_reporting.php,
operation/servers/view_server.php,
operation/servers/view_server_detail.php, operation/menu.php,
reporting/fgraph.php, reporting/stat_win.php, ajax.php,
general/logoff.php, general/pandora_help.php, general/footer.php,
general/noaccess.php, general/logon_failed.php,
general/links_menu.php, general/login_page.php, general/logon_ok.php,
general/header.php, general/main_menu.php,
godmode/groups/configure_group.php, godmode/groups/group_list.php,
godmode/setup/news.php, godmode/setup/links.php,
godmode/setup/setup.php, godmode/users/user_list.php,
godmode/users/configure_user.php, godmode/profiles/profile_list.php,
godmode/admin_access_logs.php, godmode/db/db_info_data.php,
godmode/db/db_main.php, godmode/db/db_audit.php,
godmode/db/db_sanity.php, godmode/db/db_refine.php,
godmode/db/db_info.php, godmode/db/db_event.php,
godmode/db/db_purge.php, godmode/extensions.php,
godmode/agentes/agent_template.php,
godmode/agentes/module_manager_editor_network.php,
godmode/agentes/module_manager_editor_wmi.php,
godmode/agentes/alert_manager.php,
godmode/agentes/module_manager_editor_plugin.php,
godmode/agentes/module_manager_editor_prediction.php,
godmode/agentes/alert_manager_editor.php,
godmode/agentes/manage_config.php,
godmode/agentes/module_manager_editor_data.php,
godmode/agentes/module_manager.php,
godmode/agentes/modificar_agente.php,
godmode/agentes/configurar_agente.php,
godmode/agentes/agent_disk_conf_editor.php,
godmode/agentes/planned_downtime.php,
godmode/agentes/manage_config_remote.php,
godmode/agentes/agent_manager.php,
godmode/modules/manage_network_components_form.php,
godmode/modules/manage_nc_groups_form.php,
godmode/modules/manage_network_templates.php,
godmode/modules/module_list.php,
godmode/modules/manage_network_templates_form.php,
godmode/modules/manage_network_components_form_network.php,
godmode/modules/manage_network_components_form_wmi.php,
godmode/modules/manage_network_components.php,
godmode/modules/manage_nc_groups.php,
godmode/reporting/reporting_builder.php,
godmode/reporting/map_builder.php,
godmode/reporting/graph_builder.php, godmode/servers/plugin.php,
godmode/servers/manage_recontask.php,
godmode/servers/modificar_server.php,
godmode/servers/manage_recontask_form.php,
godmode/alerts/modify_alert.php, godmode/alerts/configure_alert.php,
godmode/menu.php: Replaced $id_user with $config['id_user']. Use __a
instead of $lang_label to future use of gettext. Style
corrections.
* godmode/agentes/planned_downtime.php: Rewritten to use Pandora
functions and adopt the UI style. Replaced lang_string with __().
* pandoradb.sql: Fields in tplanned_downtime renamed to fit
guidelines.
git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1005 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2008-08-11 12:59:07 +02:00
echo " <div class='nf'> " . __ ( 'no_modules' ) . " </div> " ;
2006-12-08 17:57:43 +01:00
}
2008-06-19 02:24:05 +02:00
2006-07-09 01:32:38 +02:00
?>