[odb-users] Problem connecting a mysql server

Boris Kolpackov boris at codesynthesis.com
Tue May 15 14:05:13 EDT 2012


Hi Peter,

niermann at informatik.uni-tuebingen.de <niermann at informatik.uni-tuebingen.de> writes:

> ./driver --options-file ../../db.options
> BEGIN
> INSERT INTO `auto_object` (`id`,`str`) VALUES (?,?)
> INSERT INTO `auto_object` (`id`,`str`) VALUES (?,?)
> INSERT INTO `auto_object` (`id`,`str`) VALUES (?,?)
> COMMIT
> BEGIN
> SELECT `auto_object`.`id`,`auto_object`.`str` FROM `auto_object` WHERE
> `auto_object`.`id`=?
> ROLLBACK
> ./../../tester: line 35: 28986 Segmentation fault      (core dumped)

I assume you modified the driver to trace the SQL statement execution.
Based on that last ROLLBACK line, I think that an exception is thrown
(this ROLLBACK is caused by the transaction object's destructor being
called when the stack is unwound).

Can you run gdb on the driver and core file (the actual executable is
.libs/lt-driver) and send the stack trace (once in gdb, run the 'bt'
command):

gdb .libs/lt-driver core


> I tried it for a 64bit linux machine with a 2.6.18-238.5.1.el5 kernel and
> compiled the odb-tests with gcc (GCC) 4.6.1.

I assume you installed unixODBC-2.3.1 and Microsoft's Native Client driver
for Linux? See this blog post for more information:

http://www.codesynthesis.com/~boris/blog/2011/12/02/microsoft-sql-server-odbc-driver-linux/

> May this be related to the old kernel?

No, I don't think it is related to the kernel version. One thing that would
be helpful to know is the version of SQL Server you are connecting to.

Boris



More information about the odb-users mailing list