Ad Widget

Collapse

zabbix1.8- dashboard issue, endless querying

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Jenny
    Junior Member
    • Dec 2009
    • 5

    #1

    zabbix1.8- dashboard issue, endless querying

    Hello

    I installed zabbix-1.8 and it worked well.
    but after I converted it to node, when I accessed the dashboard , it would freeze. and I noticed the reason was that the get_dbid method will not return since the old nextid is not ecactly 1 less than the new nextid.
    I tried to add Dbstart and DBend in the beginning and ending of the get_bdid method , It worked. but this method will waste some id. (some nextid is not used.).
    get_bdid should be modified since several web page is trying to get the nextid at the same time.
    whould someone tell me what is the best method to deal with this problem?
    I am using mysql.
    I referencd the following url .http://www.zabbix.jp/modules/newbb/v...4&post_id=1617

    best regards

    Jenny
  • Palmertree
    Senior Member
    • Sep 2005
    • 746

    #2
    I believe this is the same issue we were having. This fixed our issue were it was wasting thousands of ids. Looks like the statement for node switch detection was commented out. Removing the comment made a big difference for us.

    Code:
    diff -ruN /root/zabbix-original/frontends/php/include/nodes.inc.php /root/zabbix/frontends/php/include/nodes.inc.php
    --- /root/zabbix-original/frontends/php/include/nodes.inc.php   2009-12-04 16:05:24.000000000 -0500
    +++ /root/zabbix/frontends/php/include/nodes.inc.php    2009-12-14 23:41:24.000000000 -0500
    
    @@ -98,7 +98,7 @@
                                    $ZBX_CURMASTERID = $ZBX_LOCMASTERID;
                            }
    
    -                       // if(isset($_REQUEST['select_nodes']))
    +                        if(isset($_REQUEST['select_nodes']))
                                    // update_profile('web.nodes.selected', $ZBX_VIEWED_NODES['nodeids'], PROFILE_TYPE_ARRAY_ID);
                            update_node_profile($ZBX_VIEWED_NODES['nodeids']);
                            if(isset($_REQUEST['switch_node']))
    Last edited by Palmertree; 23-12-2009, 07:32.

    Comment

    • Jenny
      Junior Member
      • Dec 2009
      • 5

      #3
      dbstart() and dbend() will end the loop in one or two,three times, or it will loop thousands of times. as long as the loop is not 1, it will waste id. and it will have the risk of getting the same id. ( I guess, it did not occur in my enviroment ) the best method maybe put that source code in a critical section. I still donot know how to do it in php .

      Comment

      • Jenny
        Junior Member
        • Dec 2009
        • 5

        #4
        I donot know if zabbix_server is updating the nextid at the same time. if yes, then the wasted id is unavoidble without locking the table. but at least critical section method can save some id. I guess.

        Comment

        Working...