Ad Widget

Collapse

DBforBIX

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dalle
    Senior Member
    Zabbix Certified Specialist
    • Mar 2009
    • 402

    #166
    Originally posted by salzkrebs
    Hallo Dalle,

    I think you have done a great Job so far dbforbix is incredible and i am trying to get everything out of it.

    So far I installed DBforBIX (0.6) on my Zabbix Server (RedHat 6.3, Zabbix 2.2, Postgres 9.2.4) and added some Queries to the pgsqlquery.props.
    Thank you!


    I will try to leave it again over night on our testsystem, but i think this is quite critical.

    Is this a known Problem/Issue, is it fixed in 0.6.1?

    Br Manuel
    Unfortunately it is not a known issue. Please try to use the last one as I did a bit of refactoring... But really a bit. And let me know you can put the daemon in DEBUG level too and let me know if that happen again.
    Andrea Dalle Vacche
    website:http://www.smartmarmot.com/
    e-mail:
    Author of:Mastering Zabbix Book - second edition
    Zabbix Network Monitoring Essentials

    Comment

    • salzkrebs
      Junior Member
      • Nov 2013
      • 14

      #167
      Unfortunately I can't download the latest Version (0.6.1) cause of some login problems to the SmartMarmot Site.
      It says I can only download the newest Software with a login, so I registered and now I can't login ("Max failed logins. Please wait 30 minutes and try again." Before I even tried to login once).

      Further, the DBforBix was stuck again when i left it over the weekend. When I restarted the Application it took a while until i had refreshed Values on my Zabbix Interface.

      Br Manuel

      Edit: Today I didn't have a Problem to download the latest Version (0.6.1). I installed it and i will leave it running to test the Problem again.
      I also noticed, that although i get polls from my SELECT Statements sometimes i don't get any updated values in my Zabbix Interface.

      How can I switch the logging into Debug mode?

      Br Manuel
      Last edited by salzkrebs; 28-01-2014, 09:17.

      Comment

      • dalle
        Senior Member
        Zabbix Certified Specialist
        • Mar 2009
        • 402

        #168
        Originally posted by salzkrebs
        Unfortunately I can't download the latest Version (0.6.1) cause of some login problems to the SmartMarmot Site.
        It says I can only download the newest Software with a login, so I registered and now I can't login ("Max failed logins. Please wait 30 minutes and try again." Before I even tried to login once).

        Further, the DBforBix was stuck again when i left it over the weekend. When I restarted the Application it took a while until i had refreshed Values on my Zabbix Interface.

        Br Manuel

        Edit: Today I didn't have a Problem to download the latest Version (0.6.1). I installed it and i will leave it running to test the Problem again.
        I also noticed, that although i get polls from my SELECT Statements sometimes i don't get any updated values in my Zabbix Interface.

        How can I switch the logging into Debug mode?

        Br Manuel
        Yes please switch it to debug, and download the last version from here

        I removed the registration an all the login etc.. as was only boring for users and I don't use the mail address, don't send spam etc.. then I simplified the download process
        Please let me know!
        Andrea Dalle Vacche
        website:http://www.smartmarmot.com/
        e-mail:
        Author of:Mastering Zabbix Book - second edition
        Zabbix Network Monitoring Essentials

        Comment

        • salzkrebs
          Junior Member
          • Nov 2013
          • 14

          #169
          Thanks for removing the login process, it worked like a charm.

          Today I see again that the polling stopped after 12 hours and 27 minutes at 2014-01-28 21:37:45,085!
          How can I switch the DBforBix into debug mode? Is there a tag in the config file like "Debuglevel=[1-4]"?

          Comment

          • fd80132
            Junior Member
            • Feb 2014
            • 1

            #170
            Hi,
            I'm on Ubuntu server 13.10 and i try to run dbforbix for ORACLE, but something is wrong when i try to run /etc/init.d/dbforbix but i don't know what, can you help me ?

            This is my conf.props :
            Code:
            ZabbixServerList=ZabbixServer1
            
            ZabbixServer1.Address=150.1.5.1
            ZabbixServer1.Port=10051
            
            
            #pidFile
            DBforBIX.PidFile=./logs/dbforbix.pid
            #frequency of item's refresh
            DBforBIX.Sleep=30
            #MaxThreadNumber should be >= than the number of your databases
            DBforBIX.MaxThreadNumber=100
            
            #put here your databases in a comma separated list
            DatabaseList=ORACLEDB1
            
            #Configuration of Connection pool
            #if not specified Orabbis is going to use default values (hardcoded)
            #Maximum number of active connection inside pool
            DatabaseList.MaxActive=10
            #The maximum number of milliseconds that the pool will wait
            #(when there are no available connections) for a connection to be returned
            #before throwing an exception, or <= 0 to wait indefinitely.
            DatabaseList.MaxWait=100
            DatabaseList.MaxIdle=1
            ###Oracle
            #define here your connection string for each database
            #on the following example we are treating Oracle
            ORACLEDB1.Url=jdbc:oracle:thin:@150.1.5.1:10050:ORACLEDB1
            ORACLEDB1.User=zabbix
            ORACLEDB1.Password=Admin123
            ORACLEDB1.DatabaseType=oracle
            ORACLEDB1.QueryListFile=./conf/oraclequery.props
            #Those values are optionals if not specified DBforBIX is going to use the general values
            ORACLEDB1.MaxActive=10
            ORACLEDB1.MaxWait=100
            ORACLEDB1.MaxIdle=1
            And the log's errors :
            Code:
            2014-02-04 10:34:08,646 [main] INFO  DBforBIX - Starting DBforBIX Version 0.6.1
             2014-02-04 10:34:08,655 [main] INFO  DBforBIX - DBforBIX started with pid:1042
             2014-02-04 10:34:08,655 [main] INFO  DBforBIX - PidFile -> ./logs/dbforbix.pid
             2014-02-04 10:34:08,805 [main] ERROR DBforBIX - Error on Configurator for database ORACLEDB1 -->Got minus one from a read call
             2014-02-04 10:34:08,805 [main] INFO  DBforBIX - This Database ORACLEDB1 removed
             2014-02-04 10:34:08,805 [main] ERROR DBforBIX - ERROR on main - Connections is empty
            Thanks for your help :/

            Comment

            • dalle
              Senior Member
              Zabbix Certified Specialist
              • Mar 2009
              • 402

              #171
              Readers would be pleased to know that I have teamed up with Packt Publishing to organize a Giveaway of the Mastering Zabbix

              And three lucky winners stand a chance to win ecopy of their new book. Keep reading to find out how you can be one of the Lucky Winners.
              More information are available here

              Andrea Dalle Vacche
              website:http://www.smartmarmot.com/
              e-mail:
              Author of:Mastering Zabbix Book - second edition
              Zabbix Network Monitoring Essentials

              Comment

              • dalle
                Senior Member
                Zabbix Certified Specialist
                • Mar 2009
                • 402

                #172
                Originally posted by salzkrebs
                Thanks for removing the login process, it worked like a charm.

                Today I see again that the polling stopped after 12 hours and 27 minutes at 2014-01-28 21:37:45,085!
                How can I switch the DBforBix into debug mode? Is there a tag in the config file like "Debuglevel=[1-4]"?
                you need to change the log4j.properties file

                # Set root logger level to DEBUG and its only appender to DBforBIX.
                log4j.rootLogger=DEBUG, DBforBIX

                # DBforBIX is set to be a ConsoleAppender.
                log4j.appender.DBforBIX=org.apache.log4j.RollingFi leAppender
                log4j.appender.DBforBIX.File=logs/dbforbix.log

                # DBforBIX uses PatternLayout.
                log4j.appender.DBforBIX.layout=org.apache.log4j.Pa tternLayout
                log4j.appender.DBforBIX.layout.ConversionPattern=% d [%t] %-5p %c - %m%n
                Andrea Dalle Vacche
                website:http://www.smartmarmot.com/
                e-mail:
                Author of:Mastering Zabbix Book - second edition
                Zabbix Network Monitoring Essentials

                Comment

                • johansen
                  Member
                  • Oct 2009
                  • 38

                  #173
                  Hello,

                  I have orabix running on our zabbix 1.8 server directly and it's working perfectly for a few numbers of oracle databases.

                  Now we were looking into monitoring db2 (and later informix) as well. For db2 I downloaded dbforbix (knowing that it's probably not stable) and setting it up.

                  Basically it's running fine but we get [no data] in zabbix...
                  here is the config and debug information:

                  Code:
                  config.props
                  
                  #comma separed list of Zabbix servers here are only 2 but you can add how many you want
                  ZabbixServerList=ZabbixServer1
                  
                  ZabbixServer1.Address=localhost
                  ZabbixServer1.Port=10051
                  
                  #pidFile
                  DBforBIX.PidFile=./logs/dbforbix.pid
                  
                  #frequency of item's refresh
                  DBforBIX.Sleep=30
                  
                  #MaxThreadNumber should be >= than the number of your databases
                  DBforBIX.MaxThreadNumber=2
                  
                  #put here your databases in a comma separated list
                  DatabaseList=PACSI_D
                  
                  #Configuration of Connection pool
                  #if not specified Orabbis is going to use default values (hardcoded)
                  #Maximum number of active connection inside pool
                  DatabaseList.MaxActive=10
                  
                  #The maximum number of milliseconds that the pool will wait
                  #(when there are no available connections) for a connection to be returned
                  #before throwing an exception, or <= 0 to wait indefinitely.
                  DatabaseList.MaxWait=100
                  DatabaseList.MaxIdle=1
                  
                  ###DB2
                  #define here your connection string for each database
                  #on the following example we are treating DB2
                  PACSI_D.Url=jdbc:db2://*****:50000/pacsi_d
                  PACSI_D.User=zabbix
                  PACSI_D.Password=******
                  PACSI_D.DatabaseType=db2
                  PACSI_D.QueryListFile=./conf/db2query.props

                  Code:
                  db2query.props
                  
                  DefaultQueryPeriod=60
                  QueryList=db_size,db_used
                  
                  db_size.Query=select sum(tbsp_total_size_kb/1024) from sysibmadm.tbsp_utilization
                  db_size.NoDataFound=none
                  
                  db_used.Query=select sum((tbsp_total_size_kb-tbsp_free_size_kb)/1024) from sysibmadm.tbsp_utilization
                  db_used.NoDataFound=none


                  Code:
                  debug log first run
                  
                  2014-03-17 15:31:08,197 [main] INFO  DBforBIX - Starting DBforBIX Version 0.6.1
                   2014-03-17 15:31:08,207 [main] INFO  DBforBIX - DBforBIX started with pid:18856
                   2014-03-17 15:31:08,207 [main] INFO  DBforBIX - PidFile -> ./logs/dbforbix.pid
                   2014-03-17 15:31:08,209 [main] DEBUG DBforBIX - getConnection for database PACSI_D
                   2014-03-17 15:31:08,211 [main] DEBUG DBforBIX - Note: PACSI_D.MaxActive null
                   2014-03-17 15:31:08,399 [main] DEBUG DBforBIX - Trying to connect to database...
                   2014-03-17 15:31:08,410 [main] DEBUG DBforBIX - Connection attempt to database succeeded.
                   2014-03-17 15:31:08,933 [main] INFO  DBforBIX - Connected as ZABBIX
                   2014-03-17 15:31:09,095 [main] INFO  DBforBIX - --------- on Database -> PACSI_D
                   2014-03-17 15:31:09,103 [main] DEBUG DBforBIX - Loaded the properties from ./conf/db2query.props
                   2014-03-17 15:31:09,116 [main] DEBUG DBforBIX - Ready to run DBJob for dbname ->PACSI_D
                   2014-03-17 15:31:09,118 [pool-1-thread-1] DEBUG DBforBIX - Starting dbJob on database PACSI_D
                   2014-03-17 15:31:09,297 [pool-1-thread-1] DEBUG DBforBIX - Actual query is db_sizeNextrun 2014/03/17 15:33:09 on database=PACSI               _D Period=2
                   2014-03-17 15:31:09,589 [pool-1-thread-1] DEBUG DBforBIX - I'm going to return 21804 for query db_size on database=PACSI_D
                   2014-03-17 15:31:09,589 [pool-1-thread-1] DEBUG DBforBIX - Actual query is db_usedNextrun 2014/03/17 15:33:09 on database=PACSI               _D Period=2
                   2014-03-17 15:31:09,898 [pool-1-thread-1] DEBUG DBforBIX - I'm going to return 12561 for query db_used on database=PACSI_D
                   2014-03-17 15:31:09,898 [pool-1-thread-1] DEBUG DBforBIX - Poolinfo PACSI_D:
                   2014-03-17 15:31:09,898 [pool-1-thread-1] DEBUG DBforBIX - NumActive: 1
                   2014-03-17 15:31:09,898 [pool-1-thread-1] DEBUG DBforBIX - NumIdle: 1
                   2014-03-17 15:31:09,899 [pool-1-thread-1] DEBUG DBforBIX - Item retrieved 2 on database PACSI_D
                   2014-03-17 15:31:09,899 [pool-1-thread-1] DEBUG DBforBIX - dbname PACSI_D sending item  DBforBIX.DB2.db_size value 21804
                   2014-03-17 15:31:09,899 [pool-1-thread-1] DEBUG DBforBIX - dbname PACSI_D sending item  DBforBIX.DB2.db_used value 12561
                   2014-03-17 15:31:09,909 [pool-1-thread-1] INFO  DBforBIX - Done with dbJob on database PACSI_D elapsed time 791 ms


                  Code:
                  debug log any further runs
                  
                  
                   2014-03-17 15:50:09,211 [main] DEBUG DBforBIX - Waking up Goood Morning
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Loaded the properties from ./conf/db2query.props
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.WhenNotAlive null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.RaceConditionQuery null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.RaceConditionValue null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.Period null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.ExcludeColumnsList error null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_size.RaceConditionQueryExcludeColumnsList error null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_used.WhenNotAlive null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_used.RaceConditionQuery null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_used.RaceConditionValue null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_used.Period null or not present null
                   2014-03-17 15:50:09,212 [main] DEBUG DBforBIX - Note: db_used.ExcludeColumnsList error null
                   2014-03-17 15:50:09,213 [main] DEBUG DBforBIX - Note: db_used.RaceConditionQueryExcludeColumnsList error null
                   2014-03-17 15:50:09,213 [main] DEBUG DBforBIX - Ready to run DBJob for dbname ->PACSI_D
                   2014-03-17 15:50:09,213 [pool-1-thread-2] DEBUG DBforBIX - Starting dbJob on database PACSI_D
                   2014-03-17 15:50:09,217 [pool-1-thread-2] DEBUG DBforBIX - Poolinfo PACSI_D:
                   2014-03-17 15:50:09,217 [pool-1-thread-2] DEBUG DBforBIX - NumActive: 1
                   2014-03-17 15:50:09,217 [pool-1-thread-2] DEBUG DBforBIX - NumIdle: 1
                   2014-03-17 15:50:09,219 [pool-1-thread-2] INFO  DBforBIX - Done with dbJob on database PACSI_D elapsed time 6 ms

                  But we have nothing on our zabbix server and yes, the zabbix host is called "PACSI_D" and has two trapper items db_used and db_size (numberic unsigned). Does anybody knows how to solve that?

                  Comment

                  • johansen
                    Member
                    • Oct 2009
                    • 38

                    #174
                    anybody able to help?

                    Comment

                    • zeds
                      Junior Member
                      Zabbix Certified Specialist
                      • Jan 2009
                      • 20

                      #175
                      DBforBix database polling interval

                      Is it possible to alter a way how DBforBix polls databases ? Currently it seems it simply loops through databases list one by one not in parallel.

                      I have about 150 DBs and it takes 18 minutes while dbforbix gets to databases on a bottom of config file!
                      2014-04-03 11:29:35,880 [main] INFO DBforBIX - Starting DBforBIX Version 0.6
                      ...
                      2014-04-03 11:47:37,923 [pool-1-thread-10] INFO DBforBIX - Done with dbJob on database DZTEST.LT_TEST elapsed time 44 ms 2014-04-03


                      I suspect part of the probleam are that some databases currently are blocked by FW , so dbforbix wait too long for them. In log file:
                      Error on Configurator for database GEIST -->IO Error: The Network Adapter could not establish the connection

                      It is very critical that I can check if data for database is not received in a due time - 5 minutes max and it is wrong that one item to monitor affect response times of other items.

                      Currently I run DBforbix -0.6 amd settings are:
                      DBforBIX.MaxThreadNumber=1000
                      ..
                      DatabaseList.MaxActive=-1
                      DatabaseList.MaxWait=-1
                      DatabaseList.Maxidle=-1

                      Comment

                      • dalle
                        Senior Member
                        Zabbix Certified Specialist
                        • Mar 2009
                        • 402

                        #176
                        Originally posted by zeds
                        Is it possible to alter a way how DBforBix polls databases ? Currently it seems it simply loops through databases list one by one not in parallel.

                        I have about 150 DBs and it takes 18 minutes while dbforbix gets to databases on a bottom of config file!
                        2014-04-03 11:29:35,880 [main] INFO DBforBIX - Starting DBforBIX Version 0.6
                        ...
                        2014-04-03 11:47:37,923 [pool-1-thread-10] INFO DBforBIX - Done with dbJob on database DZTEST.LT_TEST elapsed time 44 ms 2014-04-03


                        I suspect part of the probleam are that some databases currently are blocked by FW , so dbforbix wait too long for them. In log file:
                        Error on Configurator for database GEIST -->IO Error: The Network Adapter could not establish the connection

                        It is very critical that I can check if data for database is not received in a due time - 5 minutes max and it is wrong that one item to monitor affect response times of other items.

                        Currently I run DBforbix -0.6 amd settings are:
                        DBforBIX.MaxThreadNumber=1000
                        ..
                        DatabaseList.MaxActive=-1
                        DatabaseList.MaxWait=-1
                        DatabaseList.Maxidle=-1
                        You need to define the Maxidle to something less than 5 minutes, this will avoid your firewall issue
                        Andrea Dalle Vacche
                        website:http://www.smartmarmot.com/
                        e-mail:
                        Author of:Mastering Zabbix Book - second edition
                        Zabbix Network Monitoring Essentials

                        Comment

                        • steffen_b
                          Junior Member
                          • Sep 2014
                          • 1

                          #177
                          Hi !

                          I vote for the threaded DB query - and add the request to have configurable query intervall per connection.

                          I have another question:
                          Is there a discovery key, which i can use for LLD (Low Level discovery) ? If i understand it correct, it needs to send json list of the configured queries. I would like to add LLD for the queries configured, so i add a new query and item and trigger and graph get created automatically after the next run.
                          If my understanding is correct, this should be possible also with trapper:


                          It should be possible with a script too - but if dbforbix provides it, it might come in handy for all of us

                          Thanks!

                          Comment

                          • pantera
                            Member
                            • Dec 2014
                            • 39

                            #178
                            Originally posted by zaicnupagadi
                            Hi everyone, especially Dalle

                            I have a little bit problem with dbforbix, I dunno what I am doing wrong, I have configured mine server with orabbix and dbforbix, as I monitor my database with orabbix - I have the data - it's fine, but as I monitor the database with dbforbix, the data are not refreshing on zabbix frontend, what I receive in my dbforbix log is:

                            2012-02-02 07:17:00,780 [main] INFO DBforBIX - Starting DBforBIX Version 0.5
                            2012-02-02 07:17:00,801 [main] INFO DBforBIX - DBforBIX started with pid:26416
                            2012-02-02 07:17:00,801 [main] INFO DBforBIX - PidFile -> ./logs/dbforbix.pid
                            2012-02-02 07:17:01,713 [main] INFO DBforBIX - Connected as ZABBIX
                            2012-02-02 07:17:01,715 [main] INFO DBforBIX - --------- on Database -> atmodb
                            2012-02-02 07:17:07,141 [pool-1-thread-1] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 5363 ms
                            2012-02-02 07:18:01,800 [pool-1-thread-2] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 9 ms
                            2012-02-02 07:19:02,892 [pool-1-thread-3] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 1090 ms
                            2012-02-02 07:20:01,824 [pool-1-thread-4] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 10 ms
                            2012-02-02 07:21:02,954 [pool-1-thread-5] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 1115 ms
                            2012-02-02 07:22:01,858 [pool-1-thread-6] INFO DBforBIX - Done with dbJob on database atmodb elapsed time 8 ms


                            and so on, it presents the same as my orabbix log, so it seemes fine, where I can search for the problem?

                            I am very interested in dbforbix because in nearly days we gonna upgrade our TSM and I wanted to monitor it with dbforbix

                            My OS is RHEL 6.1

                            Thank you kindly for any help,
                            Pawel
                            Same problem for me. I think it is related with /etc/init.d/dbforbix , line which gets config
                            Help please

                            Comment

                            • OriginNG
                              Junior Member
                              • Dec 2014
                              • 15

                              #179
                              I'm having the same problem as other people seem to have. I'm running dbforbix-0.61 on a windows workstation monitoring 11 oracle databases. The problem I have and is also reported by other people is that after X hours of running very smoothly it (dbforbix) just stops sending data to zabbix. Turning up logging to DEBUG doesn't reveal anything. It just stops logging and sending data, no warning or error on the last logline, nothing. Looking at memory consumption on that workstation doesn't reveal anything special, seems more or less the same from start to finish.
                              Just restarted it but when it stops again I'll run a wireshark trace to see if it still does something or if its completely dead.

                              Regards,

                              Joop

                              Comment

                              • dalle
                                Senior Member
                                Zabbix Certified Specialist
                                • Mar 2009
                                • 402

                                #180
                                there is a new version of DBforBIX available is currently in beta testing but it looks stable.
                                This new version manage even the discovery item and all the new features anyway the configuration is quite different and is not compatible with the previous one as it has been completely re-factored.
                                Well if you would like to give it a try the software and the source code are available as always on sourceforge.
                                Andrea Dalle Vacche
                                website:http://www.smartmarmot.com/
                                e-mail:
                                Author of:Mastering Zabbix Book - second edition
                                Zabbix Network Monitoring Essentials

                                Comment

                                Working...