Ad Widget

Collapse

[Z3001] connection to database '//localhost:1521/zabbix' failed: [-1]

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • yanxiaolu
    Junior Member
    • May 2014
    • 11

    #1

    [Z3001] connection to database '//localhost:1521/zabbix' failed: [-1]

    my configure options like this:
    ./configure --prefix=/home/zabbix/zserver --enable-server --enable-agent --with-net-snmp --with-libcurl --with-libxml2 --with-ssh2 --with-oracle=$ORACLE_HOME --with-oracle-include=usr/lib/oracle/11.2/client --with-oracle-lib=/usr/lib/oracle/11.2/client/lib

    i already install oci8,zabbix and oracle are installed on same server

    when i start zabbix,the log display

    7430:20150622:004527.159 ****** Enabled features ******
    7430:20150622:004527.159 SNMP monitoring: YES
    7430:20150622:004527.159 IPMI monitoring: NO
    7430:20150622:004527.159 WEB monitoring: YES
    7430:20150622:004527.159 VMware monitoring: YES
    7430:20150622:004527.159 Jabber notifications: NO
    7430:20150622:004527.159 Ez Texting notifications: YES
    7430:20150622:004527.160 ODBC: NO
    7430:20150622:004527.160 SSH2 support: YES
    7430:20150622:004527.160 IPv6 support: NO
    7430:20150622:004527.160 ******************************
    7430:20150622:004527.160 using configuration file: /home/zabbix/zserver/etc/zabbix_server.conf
    7430:20150622:004527.168 [Z3001] connection to database '//localhost:1521/zabbix' failed: [-1]
    7430:20150622:004527.169 Cannot connect to the database. Exiting...

    what's the code [-1] means ? how can i fix this problem ??

    thank you all~
  • Atsushi
    Senior Member
    • Aug 2013
    • 2028

    #2
    It may not have read the library for Oracle.

    Please check this issue.


    Are you set LD_LIBRARY_PATH?

    Comment

    • yanxiaolu
      Junior Member
      • May 2014
      • 11

      #3
      Originally posted by Atsushi
      It may not have read the library for Oracle.

      Please check this issue.


      Are you set LD_LIBRARY_PATH?
      i set it already

      export ORACLE_BASE=/home/oracle/oracle11g
      export ORACLE_HOME=$ORACLE_BASE/product/11.2.0
      export ORACLE_SID=zabbix
      export PATH=$ORACLE_HOME/bin:/usr/sbin:$PATH
      export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib

      Comment

      • Atsushi
        Senior Member
        • Aug 2013
        • 2028

        #4
        Your configured oracle lib path for Zabbix:
        /usr/lib/oracle/11.2/client/lib

        Your set oracle lib path to LD_LIBRARY_PATH:
        /home/oracle/oracle11g/product/11.2.0/lib

        not matched.

        Comment

        • yanxiaolu
          Junior Member
          • May 2014
          • 11

          #5
          Originally posted by Atsushi
          Your configured oracle lib path for Zabbix:
          /usr/lib/oracle/11.2/client/lib

          Your set oracle lib path to LD_LIBRARY_PATH:
          /home/oracle/oracle11g/product/11.2.0/lib

          not matched.
          thank you! it works

          Comment

          Working...