Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.8.2, 1.9.0 (alpha)
    • Component/s: Proxy (P)
    • Labels:
      None

      Description

      broken in rev 10667

      make[3]: Entering directory `/home/zabbix/svn/1.8/src/libs/zbxdb'gcc -DHAVE_CONFIG_H -I. -I../../../include -g -O2 -L/usr/lib -I/usr/local/include -I/usr/lib/perl/5.8/CORE -I. -I/usr/include -MT db.o -MD -MP -MF .deps/db.Tpo -c -o db.o db.cdb.c: In function 'zbx_db_connect':db.c:291: error: 'SQLITE_OPEN_READWRITE' undeclared (first use in this function)db.c:291: error: (Each undeclared identifier is reported only oncedb.c:291: error: for each function it appears in.)make[3]: *** [db.o] Error 1

        Activity

        richlv created issue -
        Alexei Vladishev made changes -
        Field Original Value New Value
        Assignee Alexander Vladishev [ sasha ]
        Fix Version/s 1.8.2 [ 10060 ]
        Alexei Vladishev made changes -
        Assignee Alexander Vladishev [ sasha ] Aleksandrs Saveljevs [ asaveljevs ]
        Hide
        Aleksandrs Saveljevs added a comment -

        Fixed in r10718 in svn://svn.zabbix.com/branches/dev/zbx-2143-sqlite-compilation .

        The reason sqlite3_open() was replaced by sqlite3_open_v2(..., SQLITE_OPEN_READWRITE, ...) was that sqlite3_open() creates an empty database file if it does not exist and there seems to be no way to override this behavior. Now that we reverted back to using sqlite3_open(), the server will not complain about the missing database file, but will then write lots of "query failed" messages to the log, like so:

        19328:20100311:114424.186 [Z3005] Query failed: [0] no such table: escalations [select escalationid,actionid,triggerid,eventid,r_eventid,esc_step,status from escalations where status in (0,1) and nextcheck<=1268300664 and escalationid between 000000000000000 and 099999999999999]

        Show
        Aleksandrs Saveljevs added a comment - Fixed in r10718 in svn://svn.zabbix.com/branches/dev/zbx-2143-sqlite-compilation . The reason sqlite3_open() was replaced by sqlite3_open_v2(..., SQLITE_OPEN_READWRITE, ...) was that sqlite3_open() creates an empty database file if it does not exist and there seems to be no way to override this behavior. Now that we reverted back to using sqlite3_open(), the server will not complain about the missing database file, but will then write lots of "query failed" messages to the log, like so: 19328:20100311:114424.186 [Z3005] Query failed: [0] no such table: escalations [select escalationid,actionid,triggerid,eventid,r_eventid,esc_step,status from escalations where status in (0,1) and nextcheck<=1268300664 and escalationid between 000000000000000 and 099999999999999]
        Aleksandrs Saveljevs made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Assignee Aleksandrs Saveljevs [ asaveljevs ] Alexei Vladishev [ alexei ]
        Fix Version/s 1.8.2 [ 10060 ]
        Resolution Fixed [ 1 ]
        Alexei Vladishev made changes -
        Assignee Alexei Vladishev [ alexei ] richlv [ richlv ]
        Fix Version/s 1.8.2 [ 10060 ]
        Hide
        Aleksandrs Saveljevs added a comment -

        For future reference, sqlite3_open_v2() and SQLITE_OPEN_READWRITE are absent from sqlite3.h version 3.4.2, but are present in sqlite3.h version 3.5.9.

        Show
        Aleksandrs Saveljevs added a comment - For future reference, sqlite3_open_v2() and SQLITE_OPEN_READWRITE are absent from sqlite3.h version 3.4.2, but are present in sqlite3.h version 3.5.9.
        Hide
        richlv added a comment -

        could server check whether _v2 is available and use it if so ?

        Show
        richlv added a comment - could server check whether _v2 is available and use it if so ?
        Hide
        richlv added a comment -

        confirming the fix in dev branch, rev 10733

        Show
        richlv added a comment - confirming the fix in dev branch, rev 10733
        richlv made changes -
        Status Resolved [ 5 ] Tested [ 10002 ]
        Assignee richlv [ richlv ] Aleksandrs Saveljevs [ asaveljevs ]
        Aleksandrs Saveljevs made changes -
        Status Tested [ 10002 ] Done [ 10003 ]
        Hide
        Aleksandrs Saveljevs added a comment -

        Will implement detection of sqlite_open_v2() in configure.

        Show
        Aleksandrs Saveljevs added a comment - Will implement detection of sqlite_open_v2() in configure.
        Aleksandrs Saveljevs made changes -
        Status Done [ 10003 ] Reopened [ 4 ]
        Aleksandrs Saveljevs made changes -
        Status Reopened [ 4 ] Resolved [ 5 ]
        Assignee Aleksandrs Saveljevs [ asaveljevs ] Alexander Vladishev [ sasha ]
        Fix Version/s 1.8.2 [ 10060 ]
        Alexander Vladishev made changes -
        Status Resolved [ 5 ] Tested [ 10002 ]
        Assignee Alexander Vladishev [ sasha ] Aleksandrs Saveljevs [ asaveljevs ]
        Hide
        Aleksandrs Saveljevs added a comment -

        Available in pre-1.8.2 in r10868.

        Show
        Aleksandrs Saveljevs added a comment - Available in pre-1.8.2 in r10868.
        Aleksandrs Saveljevs made changes -
        Status Tested [ 10002 ] Closed [ 6 ]
        Fix Version/s 1.8.2 [ 10060 ]
        Fix Version/s 1.9 (trunk) [ 10046 ]
        Alexei Vladishev made changes -
        Workflow Zabbix workflow [ 17581 ] Zabbix workflow - new [ 43408 ]

          People

          • Assignee:
            Aleksandrs Saveljevs
            Reporter:
            richlv
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: