I ran into a problem upgrading from an OSE syslog-ng 3.1.1 to OSE syslog 3.2.4 on a CentOS 64-bit box running under a VM. When starting 3.2.4, here is what I got: Starting syslog-ng... /usr/lib64/dbd/libdbdpgsql.so: undefined symbol: _dbd_parse_datetime libdbi: Failed to load driver: /usr/lib64/dbd/libdbdpgsql.so The database access library (DBI) reports no usable SQL drivers, perhaps DBI drivers are not installed properly; Error initializing dest driver; dest='d_foo', id='d_foo#0' Error initializing message pipeline; The following relevant packages are installed: libdbi-dbd-pgsql.x86_64 0.8.1a-1.2.2 libdbi-devel.i386 0.8.1-2.1 libdbi-devel.x86_64 0.8.1-2.1 It looks like I have an libdbi that is probably just too old? Not an unheard of issue when using CentOS and RedHat, but if there is an easy work around, I'd be interested in hearing about any ideas. Thanks, John
On Mon, 2011-05-16 at 12:48 -0500, John Kristoff wrote:
I ran into a problem upgrading from an OSE syslog-ng 3.1.1 to OSE syslog 3.2.4 on a CentOS 64-bit box running under a VM. When starting 3.2.4, here is what I got:
Starting syslog-ng... /usr/lib64/dbd/libdbdpgsql.so: undefined symbol: _dbd_parse_datetime libdbi: Failed to load driver: /usr/lib64/dbd/libdbdpgsql.so The database access library (DBI) reports no usable SQL drivers, perhaps DBI drivers are not installed properly; Error initializing dest driver; dest='d_foo', id='d_foo#0' Error initializing message pipeline;
The following relevant packages are installed:
libdbi-dbd-pgsql.x86_64 0.8.1a-1.2.2 libdbi-devel.i386 0.8.1-2.1 libdbi-devel.x86_64 0.8.1-2.1
It looks like I have an libdbi that is probably just too old? Not an unheard of issue when using CentOS and RedHat, but if there is an easy work around, I'd be interested in hearing about any ideas. Thanks,
Seems like a compilation issue to me. If both the pgsql driver and libdbi core is the same version, such undefined symbol errors shouldn't happen. Getting a workable DBI can be tricky, since there was no official release for a long time now. Distributions usually carry quite outdated packages, and we're considering to abandon DBI for that reason, and use our own stuff instead. It's not difficult to compile from sources however, and the exact libdbi version that we use in PE binary packages can be found on git.balabit.hu/bazsi/libdbi.git and libdbi-drivers.git. We do have some unofficial patches against DBI, and I might be guilty of not pushing them upstream hard enough (and they may not work in all DBI use-cases), but they are at least published :) -- Bazsi
On Sun, 22 May 2011 13:32:31 +0200 Balazs Scheidler <bazsi@balabit.hu> wrote:
It's not difficult to compile from sources however, and the exact libdbi version that we use in PE binary packages can be found on git.balabit.hu/bazsi/libdbi.git and libdbi-drivers.git.
From my notes, here are the steps used to build a recent version of syslog-ng on a CentOS box with libdbi and specifically pgsql support. # ld.so.conf might need to contain: /usr/local/lib /usr/local/lib/dbd /usr/local/pgsql/lib sudo yum install gtk2-devel sudo yum install libdbi-devel sudo yum install libdbi-dbd-pgsql cd ~/workdir wget http://www.balabit.com/downloads/files/eventlog/0.2/eventlog_0.2.12.tar.gz tar zxvf eventlog_0.2.12.tar.gz cd eventlog-0.2.12 ./configure make sudo make install cd ~/workdir # syslog-ng 3.2.x needs newer libdbi than what CentOS has, build from source # get http://sourceforge.net/projects/libdbi/files/libdbi/libdbi-0.8.3/ cd libdb-0.8.3 ./configure --disable-docs && make && sudo make install make sudo make install cd ~/workdir # syslog-ng 3.2.x needs newer libdbi-drivers than what CentOS has, build from source # get http://sourceforge.net/projects/libdbi-drivers/files/libdbi-drivers/libdbi-d... tar zxvf libdb-drivers-0.8.3-1.tar.gz cd libdbi-drivers-0.8.3-1 ./configure --with-dbi-incdir=/usr/local/include/dbi --with-dbi-libdir=/usr/local/lib --with-pgsql-dir=/usr/local/pgsql --with-pgsql --disable-docs make sudo make install cd ~/workdir PKG_CONFIG_PATH=/usr/lib64/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/ssl/lib/pkgconfig:/usr/lib/pkgconfig:/usr/share/pkgconfig export PKG_CONFIG_PATH wget http://www.balabit.com/downloads/files/syslog-ng/sources/3.2.4/source/syslog... tar zxvf syslog-ng_3.2.4.tar.gz cd syslog-ng-3.2.4 LIBDBI_LIBS="-L/usr/local/lib -ldbi" LIBDBI_CFLAGS="-I/usr/local/include -I/usr/local/include/dbi" ./configure --enable-ssl --enable-sql # NOTE: there is a bug in syslog-ng 3.2.4 and below and it should be patched. For details, see this bug_id: https://bugzilla.balabit.com/show_bug.cgi?id=120 make sudo make install John
participants (2)
-
Balazs Scheidler
-
John Kristoff