List:MySQL++« Previous MessageNext Message »
From:Manikandan Shanmugam Date:October 22 2008 7:49pm
Subject:Reconnection after commands out of sync results in core
View as plain text  
Hi,

 

MySQL Server version: 5.0.64-enterprise-log MySQL Enterprise Server
(Commercial)

MySQL ++ version: 2.0.7

 

We are using a db connection pool and trying to recover from a scenario
where a db connection is corrupted,  due to “Commands out of sync” error in
a previous thread. See the pseudo code below,

 

<code>

Mysqlpp::Connection& conn = <get from pool>;

 

If (conn.ping()) {

                //Ping failed

                If (<due to commands out of sync error>) {

                                conn.close();

 
conn.set_option(mysqlpp::Connection::opt_multi_statements, true);

                                conn.connect(db, host, user, pass, 0, 0, 60,
0, CLIENT_FOUND_ROWS);     à cores at this point   

                                …

                }

}

</code>

 

Core back trace:

 

(gdb) where

#0  0x00138584 in my_strtod () from /usr/lib/libmysqlclient_r.so.15

#1  0x0012e55c in free_defaults () from /usr/lib/libmysqlclient_r.so.15

#2  0x0012e37b in free_defaults () from /usr/lib/libmysqlclient_r.so.15

#3  0x0012daf3 in my_search_option_files () from
/usr/lib/libmysqlclient_r.so.15

#4  0x0012df5d in load_defaults () from /usr/lib/libmysqlclient_r.so.15

#5  0x0014ce4d in mysql_free_result () from /usr/lib/libmysqlclient_r.so.15

#6  0x0014de41 in mysql_init_character_set () from
/usr/lib/libmysqlclient_r.so.15

#7  0x0037fa5a in ?? ()

#8  0x08aef5f0 in ?? ()

#9  0x08ae2844 in ?? ()

#10 0x08ae27e4 in ?? ()

#11 0x08ae2814 in ?? ()

#12 0x08ae282c in ?? ()

#13 0x00000000 in ?? ()

 

 

Is this a known issue? Is there any way to recover from a corrupted
connection?

 

Thanks for your time,

 

Thanks,

Mani.


Thread
Reconnection after commands out of sync results in coreManikandan Shanmugam22 Oct
Re: Reconnection after commands out of sync results in coreWarren Young23 Oct