Ad Widget

Collapse

Can't select database type in step 3 - Zabbix 2.0

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • hson89
    Junior Member
    • Jun 2012
    • 2

    #1

    Can't select database type in step 3 - Zabbix 2.0

    Hi everyone,

    I'm installing Zabbix 2.0 frontend however I can't select database type in step 3. It has only option "No". I tried to download the latest source from zabbix.com but I still had the same problem when I came to this step. I also attached the image of this error.

    Please help me solve this problem.

    Thank you very much
    Attached Files
  • scheuri
    Junior Member
    • Jun 2012
    • 7

    #2
    Sorry, I am not that experienced, but...

    What OS do you use? Was it newly installed?
    Maybe you lack of the proper parts of PHP to connect to databases (such as php-pg or php-mysql and so forth)?

    I am only familiar with ubuntu and debian, therefore I would suggest you use apt-get to install the appropriate php and libapache packages to ensure you have full php and database connection (drivers) availabilty.

    But if you already done that, then I have no idea. Sorry.

    Cheers
    Stefan

    Comment

    • nnewberry
      Junior Member
      • Oct 2012
      • 2

      #3
      Same issue

      I am experiencing the same issue.

      I am attempting to use Zabbix 2.0.3, compiled from source, on RHEL 6.2 with a couple of CentOS PHP packages (bcmath and mbstring) from pkgs.org.

      The previous screen, Check of pre-requisites, shows this entry:

      PHP databases support SQLite3 OK

      which leads me to believe that all PHP support required for a SQLite3 database is installed. However, as in the screenshot in the OP, my only option for "Database type" is "No".

      The configure command I used to configure the source included the sqlite3 option:

      ./configure --enable-server --enable-agent --with-sqlite3 --with-net-snmp --with-libcurl

      I created the SQLite3 database with the following commands:

      cd database/sqlite3
      sqlite3 /var/lib/sqlite/zabbix.db < schema.sql
      sqlite3 /var/lib/sqlite/zabbix.db < images.sql
      sqlite3 /var/lib/sqlite/zabbix.db < data.sql


      Has anyone else experienced this issue?

      Nick

      Comment

      • nnewberry
        Junior Member
        • Oct 2012
        • 2

        #4
        More information

        It looks like the function "sem_get" is undefined.

        The following check on line 108 in setup.php seems to have been returning false:

        if (class_exists('SQLite3', false) && zbx_is_callable(array('ftok', 'sem_acquire', 'sem_release', 'sem_get'))) {


        I modified setup.php to add "SQLITE3" to the "allowed_db" list outside the above "if" statement, so that SQLITE3 would always be in the list. When I attempted to load the db file I had created earlier at "/var/lib/sqlite/zabbix.db", Apache sent my browser an HTTP 500, and I saw this in the Apache error log:

        PHP Fatal error: Call to undefined function sem_get() in /var/www/html/zabbix/include/db.inc.php on line 1139, referer: http://mgmtvm/zabbix/setup.php

        It appears that the absence of "sem_get" was causing Zabbix not to add SQLite3 to the list of available databases. According to phpinfo(), this build of PHP was compiled with sysvsem:

        '--enable-sysvsem'

        so I have no idea why it would be undefined.

        This guy:



        says sysvsem was missing in an optional Red Hat PHP rpm, but I think the above phpinfo() output negates that possibility in my case. Am I wrong about that?

        Comment

        • stepw
          Junior Member
          • Oct 2012
          • 2

          #5
          Is it --enable-sysvsem or --enable-sysvsem=shared ?
          In the latter case you need to load corresponding module (sysvsem.so).

          Comment

          • aortmann
            Junior Member
            • Apr 2013
            • 1

            #6
            Hello,

            how did you solve the problem?

            I got the same Database type "NO".

            Comment

            • rulo4
              Junior Member
              • Apr 2013
              • 3

              #7
              I got the same error for field &quot;type&quot;

              How you fixed that?
              Thanks

              Comment

              • egaulin
                Junior Member
                • Apr 2013
                • 1

                #8
                You need to install php-process

                I had the same problem in Fedora 18,

                To solve it, you need the php-process package.

                Comment

                • rulo4
                  Junior Member
                  • Apr 2013
                  • 3

                  #9
                  It works, but...

                  I've installed php-process and now appears SQLite3, but I've configured a MySQL database.

                  Do you know what happened?


                  Anyway, I'll start the installation again.

                  Comment

                  • zapp_prefect
                    Junior Member
                    • Dec 2013
                    • 2

                    #10
                    No PHP module mysqli

                    Because the Frontends of zabbix use PHP mysqli to connect to MySQL Server, so if there is no PHP module mysqli, then you can not find the option MySQL Database.
                    use such command to find out if you already installed PHP module mysqli
                    # php -m | grep mysqli

                    if no output, like me, I installed PHP from Source code, and forgot to add the configure option --with-mysqli, so try fix it, restart your apache then you will find the option MySQL Database

                    Comment

                    Working...