Ad Widget

Collapse

This version is fantastic, but ...

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • krusty
    Senior Member
    • Oct 2005
    • 222

    #1

    This version is fantastic, but ...

    hi, i really afraid about the version 1.1beta3. This version is great. But i have the following problem. I use the bulkloader to insert many hosts. And i get the following error:
    Code:
    [Host added: xxxxxx]
    
    [Host added: yyyyy]
    
    Added new item xxxxxx:CPU utilization
    Added to linked host xxxxxx
    Added new item xxxxxx:LAN - IN
    Added to linked host xxxxxx
    Added new item xxxxxx:LAN - Out
    Added to linked host xxxxxx
    Added new item xxxxxx:Session active
    Added to linked host xxxxxx
    Added new item xxxxxx:WAN - IN
    Added to linked host xxxxxx
    Added new item xxxxxx:WAN - Out
    Added to linked host xxxxxx
    Added graph LAN statistic of linked host xxxxxx
    Added graph element to graph LAN statistic of linked host xxxxxx
    Added graph element to graph LAN statistic of linked host xxxxxx
    Added graph WAN statistic of linked host xxxxxx
    Added graph element to graph WAN statistic of linked host xxxxxx
    Added graph element to graph WAN statistic of linked host xxxxxx
    Added graph Session of linked host xxxxxx
    Added graph element to graph Session of linked host xxxxxx
    Added graph CPU utilization of linked host xxxxxx
    Added graph element to graph CPU utilization of linked host xxxxxx
    
    SQL error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1
    Query: insert into graphs_items (graphid,itemid,color,drawtype,sortorder,yaxisside) values (5,17217,'Green',2,0,)
    SQL error: You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1
    Query: insert into graphs_items (graphid,itemid,color,drawtype,sortorder,yaxisside) values (6,17220,'Cyan',2,0,)
    For your information, i have created a template and i use this for all hosts in the csv file. Foreach host i want to create 6 items. This items i want to display in graphs and in a screen. But it do not really work. Can anybody help me?

    My csv file looks like this:

    Code:
    HOST,XXXXXX,192.168.0.1,161,Monitored,netscreen,localhost,Router,
    Thanks
  • pdwalker
    Senior Member
    • Dec 2005
    • 166

    #2
    Code:
    insert into graphs_items
      (graphid,itemid,color,drawtype,sortorder,yaxisside  ) 
    values 
      (5,17217,'Green',2,0,)
    That's an easy problem to see.

    The addition of the "yaxisside" parameter was added to the sql, but the data does not exist and is not being included in the SQL in this part:

    ...values (5,17217,'Green',2,0,<yaxisside data is missing here>)

    Comment

    • krusty
      Senior Member
      • Oct 2005
      • 222

      #3
      Originally posted by pdwalker
      Code:
      insert into graphs_items
        (graphid,itemid,color,drawtype,sortorder,yaxisside  ) 
      values 
        (5,17217,'Green',2,0,)
      That's an easy problem to see.

      The addition of the "yaxisside" parameter was added to the sql, but the data does not exist and is not being included in the SQL in this part:

      ...values (5,17217,'Green',2,0,<yaxisside data is missing here>)
      Thanks for your fast answer. But in the Template i use yaxisside rigth and two times i use yaxisside rigth and left. Maybe this is the error? What do you think?

      Comment

      • krusty
        Senior Member
        • Oct 2005
        • 222

        #4
        Now i have change the yaxis from the items in the graph to one side, but i still get the error. Where is my failure

        I have add a test graph with two items. One item is yaxis rigth and onw is left.
        Above all i have installed phpmyadmin an check the table graph. There i found my testgraph with value in yaxistype equal null. Is this true??? ??? Which value should be insert the table for each yaxistype
        Last edited by krusty; 09-12-2005, 14:58.

        Comment

        • krusty
          Senior Member
          • Oct 2005
          • 222

          #5
          Okay, i found out that yaxisside 1 equal right and 0 equal left. But it seems that the mysql command do not included 0 or 1. Maybe there is a bug in the sql syntax? Please developer could you check this?

          Comment

          • pdwalker
            Senior Member
            • Dec 2005
            • 166

            #6
            It is not yours mistake.

            The problem is with the UI code in include/graphs.inc.php in function add_item_to_graph on line 43

            The database upgrade from beta2 to beta3 adds a new column
            Code:
            alter table graphs_items add  yaxisside     int(1)      DEFAULT '1' NOT NULL;
            for existing records, the values will be null. You can check it by by running these queries against your database
            Code:
            select count(1) from graphs_items;
            select count(1) from graphs_items where yaxisside is null;
            I expect you will find the second query will return a non zero amount. Since the last field is null, no data is returned, thus you get the broken sql query.

            You can do one of the following to fix it:

            1/ fix your database values by setting the null ones to a non null value
            Code:
            update graphs_items set yaxisside = 1 where yaxisside is null;
            2/ make an alteration to include/graphs.inc.php to function add_item_to_graph on line 43 (I am not a php coder, so the code addition I have written is probably incorrect)

            Code:
                function    add_item_to_graph($graphid,$itemid,$color,$drawtype,$sortorder,$yaxisside)
                {
                    [color=red]if ($yaxisside == null) $yaxisside = 1;[/color]
                    $sql="insert into graphs_items (graphid,itemid,color,drawtype,sortorder,yaxisside) values ($graphid,$
            itemid,'$color',$drawtype,$sortorder,$yaxisside)";
                    $result=DBexecute($sql);
                    return DBinsert_id($result,"graphs_items","gitemid");
                }
            I would update the values in the database.
            Last edited by pdwalker; 09-12-2005, 15:39. Reason: fixed a typo

            Comment

            • krusty
              Senior Member
              • Oct 2005
              • 222

              #7
              Hi, thanks for your help.

              I found out a littel mistake into your description.

              Code:
              if ($yaxi[COLOR=Green]s[/COLOR]side == null) $yaxisside = 1;


              I have another question.
              Is there a way to create screen with the bulkloader for each host?

              Comment

              • pdwalker
                Senior Member
                • Dec 2005
                • 166

                #8
                I am sure that is not the only mistake. Like I said, I am not a programmer and just typed in a quick response. In fact, I just installed the software for the first time yesterday.

                I suppose you can direct feature requests to the author. If a feature is really important, it might be worth getting him something from his amazon.com wishlist to help speed the process. Either that, or learn how to make changes in the UI.

                - Paul

                Comment

                • krusty
                  Senior Member
                  • Oct 2005
                  • 222

                  #9
                  I found the next mistake. I have add up to 10 hosts. Only one is monitored and available but the zabbix_server saves no data for example values oder trends into the database. I use mysql 4.?? on a SuSE 9.1 pro Server. Maybe this is a bigger problem

                  The installation was without any problems.
                  Attached Files
                  Last edited by krusty; 09-12-2005, 16:50.

                  Comment

                  • pdwalker
                    Senior Member
                    • Dec 2005
                    • 166

                    #10
                    It works fine here.

                    The key values have changed for some parameters between b2 and b3. monitors I had previously defined no longer work, so I change the key to the new values.

                    Look here: http://www.zabbix.com/manual/v1.1/config_items.php for a list of key parameters and their currently supported values.

                    Unfortunately, unless I see how you have yours setup, I cannot provide more help than that.

                    - Paul

                    Comment

                    • krusty
                      Senior Member
                      • Oct 2005
                      • 222

                      #11
                      I use only MIB´s like this
                      Code:
                      1.3.6.1.4.1.3224.16.1.2
                      or this
                      Code:
                      IF-MIB::ifOutOctets.4
                      The version 1.1beta2 supports this MIB´s

                      And this MIB´s work fine. If i fire this command i get the value

                      Code:
                       snmpwalk -v 2c -c public 192.168.0.1 IF-MIB::ifOutOctets.1
                      Last edited by krusty; 09-12-2005, 16:47.

                      Comment

                      • pdwalker
                        Senior Member
                        • Dec 2005
                        • 166

                        #12
                        sorry,

                        I am out of my depth there. I have no experience with setting up snmp.

                        Comment

                        • krusty
                          Senior Member
                          • Oct 2005
                          • 222

                          #13
                          Originally posted by pdwalker
                          sorry,

                          I am out of my depth there. I have no experience with setting up snmp.
                          It's a great pity. Thanks.

                          Can anyone else help me with this problem?

                          Comment

                          • krusty
                            Senior Member
                            • Oct 2005
                            • 222

                            #14
                            I have changed the version from 1.1beta3 to 1.1beta4 and know my MIB´s are working fine. But i have another questions to the developers. Is there an alternative to create with the bulkloader for each host one screen? If i create one Template with six items (LAN in/out, WAN in/out, Session, CPU utilization) and for each one graph (LAN, WAN, Session, CPU utilization). This works. But if i create for it one screen where all graphs shown i got only one screen without any graphs. What should i do to get for each host one screen with the bulkloader? Please help.

                            I forgot something

                            With phpMyAdmin i see in the table host_templates the following entry:
                            Code:
                            hosttemplateid 	  hostid  templateid  items  triggers  actions	 graphs  screens
                            1                 10009   10008       7      7         7         7       7
                            What is the meaning of "7"? Can somebody explain it?
                            Last edited by krusty; 12-12-2005, 10:18.

                            Comment

                            • krusty
                              Senior Member
                              • Oct 2005
                              • 222

                              #15
                              Problem with template in 1.1beta4

                              Hi,
                              i found out that the template function was damaged. If i create one template with different items and then use this template for including some new hosts I got no items to the new hosts.
                              Please note this. Thanks.

                              Comment

                              Working...