Welcome to Pandora FMS Community › Forums › Soporte de la comunidad › Error crear HOST ALIVE Network Module
-
-
::
Si activo las General Variables del Mysql, cuando creo el modulo veo el siguiente FAIL en las querys de MysQL, por si os dice algo
Ā Ā Ā Ā Ā Ā Ā Ā ORDER BY name ASC Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT COUNT(*) FROM tupdate Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT COUNT(*) FROM tupdate WHERE data_rollback LIKE '%"admin":1%' Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT id_grupo FROM tagente WHERE id_agente = 1 LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT count(*) FROM tincidencia WHERE id_agent = 1 LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT nombre FROM tagente WHERE id_agente = 1 LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT * FROM `tagente` WHERE `id_agente` = 1 LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT id_agente_modulo FROM tagente_modulo WHERE `nombre` = 'Host Alive' AND `id_agente` = 1 LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā INSERT INTO `tagente_modulo` (`id_tipo_modulo`, `descripcion`, `max`, `min`, `snmp_oid`, `snmp_community`, `id_module_group`, `module_interval`, `module_ff_interval`, `ip_target`, `tcp_port`, `tcp_rcv`, `tcp_send`, `id_export`, `plugin_user`, `plugin_pass`, `plugin_parameter`, `id_plugin`, `post_process`, `prediction_module`, `max_timeout`, `max_retries`, `disabled`, `id_modulo`, `custom_id`, `history_data`, `min_warning`, `max_warning`, `str_warning`, `min_critical`, `max_critical`, `str_critical`, `custom_string_1`, `custom_string_2`, `custom_string_3`, `custom_integer_1`, `custom_integer_2`, `min_ff_event`, `min_ff_event_normal`, `min_ff_event_warning`, `min_ff_event_critical`, `each_ff`, `ff_timeout`, `unit`, `macros`, `quiet`, `critical_instructions`, `warning_instructions`, `unknown_instructions`, `critical_inverse`, `warning_inverse`, `cron_interval`, `id_category`, `disabled_types_event`, `module_macros`, `nombre`, `id_agente`) VALUES (6,'Check if host is alive using ICMP ping check.',0,0,'0','',2,300,0,'',NULL,'','',0,'','','',0,'0',NULL,0,0,0,2,'',1,0.000000,0.000000,'',0.000000,0.000000,'','','','',0,0,0,0,0,0,0,0,'','',0,'','','',0,0,'* * * * *',0,'{"going_unknown":1}','W10=','Host Alive',1) Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā INSERT INTO `tsesion` (`id_usuario`, `accion`, `ip_origen`, `descripcion`, `fecha`, `utimestamp`) VALUES ('admin','Agent management','172.20.3.111','Fail to try added module 'Host Alive' for agent pandora','2016-12-01 08:50:23',1480578623) Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT policy_linked FROM tagente_modulo WHERE id_agente_modulo = '' LIMIT 1 Ā Ā Ā Ā Ā Ā Ā Ā Ā 138 QueryĀ Ā SELECT id_tipo, descripcion Ā Ā Ā Ā Ā Ā Ā Ā FROM ttipo_modulo Ā Ā Ā Ā Ā Ā Ā Ā WHERE categoria IN (3,4,5) Ā Ā Ā Ā Ā Ā Ā Ā ORDER BY descripcion
2016-12-01 10:01:02 11666 [Warning] Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statements writing to a table with an auto-increment column after selecting from another table are unsafe because the order in which rows are retrieved determines what (if any) rows will be written. This order cannot be predicted and may differ on master and the slave. Statement: DELETE FROM treport_content Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā WHERE id_agent != 0 Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā AND id_agent NOT IN (SELECT id_agente FROM tagente) Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā AND `type` NOT IN ('SLA_services','custom_graph','sql_graph_vbar','sql_graph_hbar','sql_graph_pie','database_serialized','sql','inventory','inventory_changes','netflow_area','netflow_pie','netflow_data','netflow_statistics','netflow_summary') 2016-12-01 10:01:02 11666 [Warning] Unsafe statement written to the binary log using statement format since BINLOG_FORMAT = STATEMENT. Statements writing to a table with an auto-increment column after selecting from another table are unsafe because the order in which rows are retrieved determines what (if any) rows will be written. This order cannot be predicted and may differ on master and the slave. Statement: DELETE FROM treport_content Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā WHERE `type` LIKE 'exception' Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā Ā AND id_rc NOT IN (SELECT id_report_content FROM treport_content_item)
Si miro la tabla que se queja, la tsesion, veo los fails
root@localhost [pandora]> select * from tsesionG *************************** 37. row *************************** Ā id_sesion: 37 id_usuario: admin Ā ip_origen: 172.20.3.111 Ā Ā accion: Agent management descripcion: Fail to try added module 'Host Alive' for agent VIEW00 Ā Ā Ā fecha: 2016-11-30 16:35:36 utimestamp: 1480520136 *************************** 38. row *************************** Ā id_sesion: 38 id_usuario: admin Ā ip_origen: 172.20.3.111 Ā Ā accion: Agent management descripcion: Fail to try added module 'Host Alive' for agent VIEW00 Ā Ā Ā fecha: 2016-11-30 16:40:40 utimestamp: 1480520440 *************************** 39. row ***************************
Los permisos en MySQL estan correctos, porque sino no podrĆa entrar en Pandora ni poder generar agentes por lo que ya no se que mĆ”s logs puedo extraer.
Esto os dice algo mƔS? -
::
[HISTORY]
Hago un repaso de lo que he instalado y probado
CentOS 7.3 con MySQL 5.7.15 con PandoraServer 6.03 -> no consigo instalar el pandora, se queja de insert tables en la instalaciĆ³n de la web
CentOS 7.3 con MySQL 5.7.15 con PandoraServer 6.04 -> no consigo instalar el pandora, se queja de insert tables en la instalaciĆ³n de la web
CentOS 7.3 con MySQL 5.6.33 con PandoraServer 6.03Ā -> No puedo crear ningun modulo
CentOS 7.3 con MySQL 5.6.33 con PandoraServer 6.04Ā -> No puedo crear ningun moduloCentOS 6.6 con MySQL 5.7.15 con PandoraServer 6.03 -> No puedo crear ningun modulo
CentOS 6.6 con MySQL 5.7.15 con PandoraServer 6.04 -> No puedo crear ningun modulo
CentOS 6.6 con MySQL 5.6.33 con PandoraServer 6.03 -> No puedo crear ningun modulo
CentOS 6.6 con MySQL 5.6.33 con PandoraServer 6.04 -> No puedo crear ningun moduloCentOS 6.8 con MySQL 5.5.32 con PandoraServer 6.04 -> FUNCIONA OK
Indicar que siempre he usado un CentOS MINIMAL y el MySQL lo he instalado mediante binarios y usando un my.cnf generado por percona a mi gusto
La instalaciĆ³n del Pandora_console y Pandora_server 6.03 se ha hecho siempre mediante YUM y la 6.04 mediante rpm directamente descargados desde la web de pandorafms[UPDATE]
Despues de probar lo innombrable, he bajado el pandora appliance que hay en la web y que essta configurado bajo CentOS y he visto que usais la versiĆ³n 6.8 con un MySQL 5.5.32 asĆ que si esa versiĆ³n os VA, tenia que ir si o si mediante un CentOS 6.8 MINIMAL con un MySQL 5.5.32 mediante binarios…..y asĆ ha sido.
Lo que me hace pensar que posiblemente con un CentOS 7.3 y un MysQL 5.5.32 deberĆa funcionar….ya que el problema parece estar en la consola a la hora de hacer el insert en el MySQL
Ahora solo me queda probar a ver si puedo hacer un export del MySQL con los schemas e intentar pasarlo a un MySQL 5.7.15, ya que en este mismo foro me han comentado que si que funciona. Cuando haga esta prueba os lo comento por si os interesa
-
::
Actualizo con mis ultimas pruebas
CentOS 7.3 con MySQL 5.5.32 con PandoraServer 6.04 -> Funciona OK
UPDATE Minor -> CentOS 7.3 con MySQL 5.5.52 con PandoraServer 6.04 -> Funciona OK
UPDATE Major -> CentOS 7.3 con MySQL 5.6.33 con PandoraServer 6.04 -> Funciona OK
He hecho un update mediante binarios de la 5.5.32 a la 5.5.52 y funciona OK. He pasado despuƩs a binarios 5.6.33 y me ha funcionado todo OK tambiƩn.
Me quedarĆa probar la 5.7, pero ya lo voy a dejar aqui, porque se ha quejado de algunas tablas a la hora de pasar de la 5.5 a la 5.6, que he solucionado con el
mysql_upgrade -u root -h127.0.0.1 --force
YĀ me temo que en la 5.7, tendrĆ© mĆ”s problemas de schemas y demĆ”s, por lo que lo voy a dejar aqui.
Al final he conseguido poder montar un Pandora 6S04 (mediante RPM, no YUM) sobre un CentOS 7.3 Minimal con MySQL 5.6.33 mediante binarios.
Eso si, he tenido que pasar por la 5.5, ya que montarlo de golpe en estar versiĆ³n no funcionaba la creaciĆ³n de modulos.
saludos
-
::
Hola gairhald,
Muchas gracias por compartir todo el proceso, resulta de mucha utilidad para descubrir incompatibilidades y compatibilidades, ya que nosotros solemos ceƱirnos al estĆ”ndar que recomendamos (serĆa imposible probar todas las combinaciones de distros, versiones de MySQL, php…). Gracias!
Un saludo,
Antonio.