Pandora FMS Community

[Solved] Server crash notifications

chathura · 5 nov 2020, 9:54 · 5 mensajes · 74 visitas

  1. Inicio del debate

    Hi, I'm getting following notifications time to time (every 10-15 minutes) and goes away. but there are no errors logged in pandora_server.error. server service seems to run fine. There are no restarts or stops in the service. i'm running Pandorafms v7.0NG.749 - Build PC200909 - MR 41 on Ubuntu 16.04.7 LTS Any help will be appreciated. Thanks.

  2. ¡Hi! I am reading this function, it seems to me (maybe) ¿a time problem from server? (other reason: old cache at database).  Or maybe I am wrong with this theory.

        public function checkPandoraServers()
        {
            $servers = db_get_all_rows_sql(
                'SELECT
                    id_server,
                    name,
                    server_type,
                    server_keepalive,
                    status,
                    unix_timestamp() - unix_timestamp(keepalive) as downtime
                FROM tserver
                WHERE 
                    unix_timestamp() - unix_timestamp(keepalive) > server_keepalive
                    OR status = 0'
            );
    

    Line 1201:  https://github.com/pandorafms/pandorafms/blob/7b4395c537ec768686410473abf097c771e97bc6/pandora\_console/include/class/ConsoleSupervisor.php

  3. Good Please, check the file /var/log/pandora/pandora_server.log and tell us if you see any related error. You can also send it to us so that we can check it. Greetings Diego

  4. Hello Please, check the file /var/log/pandora/pandora_server.log and tell us if you see any related error. You can also send it to us so that we can check it. Greetings Diego

  5. I was managed to solved the problem. Thank you Jimmy_Olano for pointing me to the code. Below is the DB query how pandorafms check for server status. line 1298

    public function checkPandoraServerMasterAvailable()
        {
            $n_masters = db_get_value_sql(
                'SELECT
                    count(*) as n
                FROM tserver
                WHERE 
                    unix_timestamp() - unix_timestamp(keepalive)  0
                    AND status = 1'
            );
    

    This checks whether last keepalive value is lower than than the defined threshold. If difference of the keepalive more than the defined threshold, it will generate notification. Earlier I had configured server_threshold = 60 intentionally (default value = 5) while server_keepalive 45 (default) in pandora_server.conf which will result server upating tserver table keepalive on every 60 seconds. So, that cause notifications popping up randomly. Now i have reduced server_threshold = 15. so no more false notifications.

Entra en tu cuenta para publicar.