Re: [sqlite] Tomcat crashes with SQLite
I am just trying the last version of http://www.ch-werner.de/javasqlite/ date: June 26th 2007 Lucy will see if she is ok now... http://lucy.ysalaya.org Cheers Frederic de la Goublaye On 6/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "Frederic de la Goublaye" <[EMAIL PROTECTED]> wrote: > My server is under FreeBSD 5.4 > It is ok ? > I am not aware of any problems with FreeBSD 5.4. -- D. Richard Hipp <[EMAIL PROTECTED]> - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
"Frederic de la Goublaye" <[EMAIL PROTECTED]> wrote: > My server is under FreeBSD 5.4 > It is ok ? > I am not aware of any problems with FreeBSD 5.4. -- D. Richard Hipp <[EMAIL PROTECTED]> - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
My server is under FreeBSD 5.4 It is ok ? Cheers Frederic On 6/25/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "Frederic de la Goublaye" <[EMAIL PROTECTED]> wrote: > My server crashed again. > > I recompiled sqlite3-3-5 with this configure option > --enable-threadsafe =yes > > But I read that sqlite has somebug under Unix with the management of the > THREADS. > Some version so of Linux have a bug. Upgrade to linux kernel series 2.6 and you should be OK. -- D. Richard Hipp <[EMAIL PROTECTED]> - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
"Frederic de la Goublaye" <[EMAIL PROTECTED]> wrote: > My server crashed again. > > I recompiled sqlite3-3-5 with this configure option > --enable-threadsafe =yes > > But I read that sqlite has somebug under Unix with the management of the > THREADS. > Some version so of Linux have a bug. Upgrade to linux kernel series 2.6 and you should be OK. -- D. Richard Hipp <[EMAIL PROTECTED]> - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
My server crashed again. I recompiled sqlite3-3-5 with this configure option --enable-threadsafe =yes But I read that sqlite has somebug under Unix with the management of the THREADS. Can it work with my Java code ? Thanks for attention. Frederic An unexpected exception has been detected in native code outside the VM. Unexpected Signal : 10 occurred at PC=0x712C5D06 Function=sqlite3VdbeExec+0x24D2 Library=/usr/local/lib/libsqlite3.so.8 On 6/24/07, Frederic de la Goublaye <[EMAIL PROTECTED]> wrote: Thanks for your answer. I just recompiled sqlite with *DTHREADSAFE=1* http://www.sqlite.org/cvstrac/wiki?p=MultiThreading I will publish the results. Cheers Frédéric On 6/22/07, Russell Leighton <[EMAIL PROTECTED]> wrote: > > > If you did not compile sqlite as multi-threaded this is exactly what > would happen. > > On Jun 22, 2007, at 9:06 PM, Frederic de la Goublaye wrote: > > > Hi I just tried this driver: > > http://www.zentus.com/sqlitejdbc/ > > > > The result is ten times slower or even more. > > Maybe I am wrong using this new driver. > > > > So for the moment I am still using this one: > > http://www.ch-werner.de/javasqlite/ > > > > BUT I HAVE STILL THE CRASH TROUBLES: > > > > An unexpected exception has been detected in native code outside the > > VM. > > Unexpected Signal : 11 occurred at PC=0x34D8493F > > Function=sqlite3VdbeExec+0x10B > > Library=/usr/local/lib/libsqlite3.so.8 > > > > ANY IDEAR ??? > > > > Thanks for your attention. > > > > Cheers > > Frederic > > > > > > > > > > > > On 6/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> > > wrote: > >> > >> > >> > My project is working with Tomcat, SQLite and javasqlite. > >> > http://www.ch-werner.de/javasqlite/ > >> > > >> > http://www.ysalaya.org > >> > > >> > Since a few weeks Tomcat server crashes very often: error 505 > >> > and I need to restart it manually. It is installed on FreeBSD 5.4. > >> > > >> > Please see the Tomcat log file bellow. > >> > It seems to be an error in SQLite outsite the Java Virtual Machine. > >> > > >> > ANY IDEAR ? > >> > >> I see 2 possible explanations: > >> 1. You use the same connection in different threads at the same time. > >> 2. There are bugs in JDBC driver. If this is the case, try driver > from > >> http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be > >> different and you won't even notice them. You may use pure java > >> version - > >> it will be probably slower than JNI based, but should never crash VM. > > >> > >> > >> > >> > -- > >> Wicie, rozumicie > >> Zobacz >>> http://link.interia.pl/f1a74 > >> > >> > >> > >> > -- > >> --- > >> To unsubscribe, send email to [EMAIL PROTECTED] > >> > >> > -- > >> --- > >> > >> > > > - > > To unsubscribe, send email to [EMAIL PROTECTED] > > - > >
Re: [sqlite] Tomcat crashes with SQLite
Thanks for your answer. I just recompiled sqlite with *DTHREADSAFE=1* http://www.sqlite.org/cvstrac/wiki?p=MultiThreading I will publish the results. Cheers Frédéric On 6/22/07, Russell Leighton <[EMAIL PROTECTED]> wrote: If you did not compile sqlite as multi-threaded this is exactly what would happen. On Jun 22, 2007, at 9:06 PM, Frederic de la Goublaye wrote: > Hi I just tried this driver: > http://www.zentus.com/sqlitejdbc/ > > The result is ten times slower or even more. > Maybe I am wrong using this new driver. > > So for the moment I am still using this one: > http://www.ch-werner.de/javasqlite/ > > BUT I HAVE STILL THE CRASH TROUBLES: > > An unexpected exception has been detected in native code outside the > VM. > Unexpected Signal : 11 occurred at PC=0x34D8493F > Function=sqlite3VdbeExec+0x10B > Library=/usr/local/lib/libsqlite3.so.8 > > ANY IDEAR ??? > > Thanks for your attention. > > Cheers > Frederic > > > > > > On 6/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> > wrote: >> >> >> > My project is working with Tomcat, SQLite and javasqlite. >> > http://www.ch-werner.de/javasqlite/ >> > >> > http://www.ysalaya.org >> > >> > Since a few weeks Tomcat server crashes very often: error 505 >> > and I need to restart it manually. It is installed on FreeBSD 5.4. >> > >> > Please see the Tomcat log file bellow. >> > It seems to be an error in SQLite outsite the Java Virtual Machine. >> > >> > ANY IDEAR ? >> >> I see 2 possible explanations: >> 1. You use the same connection in different threads at the same time. >> 2. There are bugs in JDBC driver. If this is the case, try driver from >> http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be >> different and you won't even notice them. You may use pure java >> version - >> it will be probably slower than JNI based, but should never crash VM. >> >> >> >> -- >> Wicie, rozumicie >> Zobacz >>> http://link.interia.pl/f1a74 >> >> >> >> -- >> --- >> To unsubscribe, send email to [EMAIL PROTECTED] >> >> -- >> --- >> >> - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
If you did not compile sqlite as multi-threaded this is exactly what would happen. On Jun 22, 2007, at 9:06 PM, Frederic de la Goublaye wrote: Hi I just tried this driver: http://www.zentus.com/sqlitejdbc/ The result is ten times slower or even more. Maybe I am wrong using this new driver. So for the moment I am still using this one: http://www.ch-werner.de/javasqlite/ BUT I HAVE STILL THE CRASH TROUBLES: An unexpected exception has been detected in native code outside the VM. Unexpected Signal : 11 occurred at PC=0x34D8493F Function=sqlite3VdbeExec+0x10B Library=/usr/local/lib/libsqlite3.so.8 ANY IDEAR ??? Thanks for your attention. Cheers Frederic On 6/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > My project is working with Tomcat, SQLite and javasqlite. > http://www.ch-werner.de/javasqlite/ > > http://www.ysalaya.org > > Since a few weeks Tomcat server crashes very often: error 505 > and I need to restart it manually. It is installed on FreeBSD 5.4. > > Please see the Tomcat log file bellow. > It seems to be an error in SQLite outsite the Java Virtual Machine. > > ANY IDEAR ? I see 2 possible explanations: 1. You use the same connection in different threads at the same time. 2. There are bugs in JDBC driver. If this is the case, try driver from http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be different and you won't even notice them. You may use pure java version - it will be probably slower than JNI based, but should never crash VM. -- Wicie, rozumicie Zobacz >>> http://link.interia.pl/f1a74 -- --- To unsubscribe, send email to [EMAIL PROTECTED] -- --- - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
Hi I just tried this driver: http://www.zentus.com/sqlitejdbc/ The result is ten times slower or even more. Maybe I am wrong using this new driver. So for the moment I am still using this one: http://www.ch-werner.de/javasqlite/ BUT I HAVE STILL THE CRASH TROUBLES: An unexpected exception has been detected in native code outside the VM. Unexpected Signal : 11 occurred at PC=0x34D8493F Function=sqlite3VdbeExec+0x10B Library=/usr/local/lib/libsqlite3.so.8 ANY IDEAR ??? Thanks for your attention. Cheers Frederic On 6/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > My project is working with Tomcat, SQLite and javasqlite. > http://www.ch-werner.de/javasqlite/ > > http://www.ysalaya.org > > Since a few weeks Tomcat server crashes very often: error 505 > and I need to restart it manually. It is installed on FreeBSD 5.4. > > Please see the Tomcat log file bellow. > It seems to be an error in SQLite outsite the Java Virtual Machine. > > ANY IDEAR ? I see 2 possible explanations: 1. You use the same connection in different threads at the same time. 2. There are bugs in JDBC driver. If this is the case, try driver from http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be different and you won't even notice them. You may use pure java version - it will be probably slower than JNI based, but should never crash VM. -- Wicie, rozumicie Zobacz >>> http://link.interia.pl/f1a74 - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
Hi all. Lucy thanks for your answer :+) http://lucy.ysalaya.org My issue is not closed because the site crashes these days. I do not think I use the same connection in different threads at the same time. I am still using the javasqlite ODBC driver. But I did not but the jdbc into the Tomcat server.xml file. As I did for MySQL because as far as know, the jdbc needs the path to the database file and under my project, all the chatbot databases are different /user_idr/bot_base_type.db Here is my source code for the Java class connection. Maybe you can have a look (it is simple, maybe too much) _ Copyright 2006-2007 Frederic de la Goublaye _ public class SQLite { private static Logger logger = Logger.getLogger(SQLite.class.getName()); private final static String pilote = " SQLite.JDBCDriver"; private Connection con = null; private PreparedStatement s; private static SQLite instance = new SQLite(); public static SQLite getInstance() {return instance;} private static String sDBPath; private SQLite() { try { Class.forName(pilote); con = null; s = null; } catch (Exception e) { logger.error(e.getMessage()); } } public String getDBPath() {return sDBPath;} public void setDBPath(String pDBPath) {sDBPath= pDBPath;} public void connection(String pDBPath) { try { sDBPath = pDBPath; con = DriverManager.getConnection(sDBPath); con.setAutoCommit ( true ); } catch (SQLException e) { logger.error(e.getMessage()); logger.error("sDBPath="+sDBPath); if (con != null) { try { con.close(); } catch (Exception ex) { logger.error(ex.getMessage()); } finally { con = null; } } } } public void deconnection() { if (s != null) { try { s.close(); } catch (Exception e) { logger.error(e.getMessage()); } finally { s = null; } } if (con != null) { try { con.close(); } catch (Exception e) { logger.error(e.getMessage()); } finally { con = null; } } } public ResultSet execQuery(String pRequest) { try { s = con.prepareStatement(pRequest); ResultSet rset = s.executeQuery(); return rset; } catch(SQLException e) { logger.error(e.getMessage()); logger.error("sSql="+pRequest); if (s != null) { try { s.close(); } catch (Exception ex) { logger.error(ex.getMessage()); } finally { s = null; } } return null; } } public void finalize() { try { deconnection(); } catch (Exception e) { logger.error(e.getMessage()); } } public String getStringForSQL(String str) { StringBuffer sb = new StringBuffer(255); if (str == null) return str; char[] cc = str.toCharArray(); for (char i = 0; i < cc.length; i++) { if (cc[i] == '\'') { sb.append('\\'); } else if (cc[i] == '\\') { sb.append('\\'); } sb.append(cc[i]); } return sb.toString(); } } _ Thanks again for your attention. Frederic de la Goublaye On 6/3/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > My project is working with Tomcat, SQLite and javasqlite. > http://www.ch-werner.de/javasqlite/ > > http://www.ysalaya.org > > Since a few weeks Tomcat server crashes very often: error 505 > and I need to restart it manually. It is installed on FreeBSD 5.4. > > Please see the Tomcat log file bellow. > It seems to be an error in SQLite outsite the Java Virtual Machine. > > ANY IDEAR ? I see 2 possible explanations: 1. You use the same connection in different threads at the same time. 2. There are bugs in JDBC driver. If this is the case, try driver from http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be different and you won't even notice them. You may use pure java version - it will be probably slower than JNI based, but should never crash VM. -- Wicie, rozumicie Zobacz >>> http://link.interia.pl/f1a74 - To unsubscribe, send email to [EMAIL PROTECTED] -
Re: [sqlite] Tomcat crashes with SQLite
> My project is working with Tomcat, SQLite and javasqlite. > http://www.ch-werner.de/javasqlite/ > > http://www.ysalaya.org > > Since a few weeks Tomcat server crashes very often: error 505 > and I need to restart it manually. It is installed on FreeBSD 5.4. > > Please see the Tomcat log file bellow. > It seems to be an error in SQLite outsite the Java Virtual Machine. > > ANY IDEAR ? I see 2 possible explanations: 1. You use the same connection in different threads at the same time. 2. There are bugs in JDBC driver. If this is the case, try driver from http://www.zentus.com/sqlitejdbc. It for sure has bugs, but may be different and you won't even notice them. You may use pure java version - it will be probably slower than JNI based, but should never crash VM. -- Wicie, rozumicie Zobacz >>> http://link.interia.pl/f1a74 - To unsubscribe, send email to [EMAIL PROTECTED] -
[sqlite] Tomcat crashes with SQLite
Hi All My project is working with Tomcat, SQLite and javasqlite. http://www.ch-werner.de/javasqlite/ http://www.ysalaya.org Since a few weeks Tomcat server crashes very often: error 505 and I need to restart it manually. It is installed on FreeBSD 5.4. Please see the Tomcat log file bellow. It seems to be an error in SQLite outsite the Java Virtual Machine. ANY IDEAR ? An unexpected exception has been detected in native code outside the VM. Unexpected Signal : 11 occurred at PC=0x34D8493F Function=sqlite3VdbeExec+0x10B Library=/usr/local/lib/libsqlite3.so.8 Current Java thread: at SQLite.Vm.step(Native Method) at SQLite.Database.get_table(Database.java:175) at SQLite.JDBC2x.DatabaseX.get_table(JDBCConnection.java:437) at SQLite.JDBC2x.JDBCStatement.executeQuery(JDBCStatement.java:94) at SQLite.JDBC2x.JDBCPreparedStatement.executeQuery( JDBCPreparedStatement.java:71) at com.ysalaya.db.SQLite.execQuery(SQLite.java:73) at com.ysalaya.data.BotAnswerData.getAnswers(BotAnswerData.java:473) at com.ysalaya.dialog.Dialog.getBotMemDirectAnswer(Dialog.java:521) at com.ysalaya.dialog.Dialog.setAnswer(Dialog.java:331) at com.ysalaya.dialog.Dialog.(Dialog.java:102) at com.ysalaya.control.DialogControl.say(DialogControl.java:299) at com.ysalaya.control.DialogControl.doGet(DialogControl.java:51) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter( ApplicationFilterChain.java:173) at org.apache.catalina.core.ApplicationDispatcher.invoke( ApplicationDispatcher.java:672) at org.apache.catalina.core.ApplicationDispatcher.processRequest( ApplicationDispatcher.java:463) at org.apache.catalina.core.ApplicationDispatcher.doForward( ApplicationDispatcher.java:398) at org.apache.catalina.core.ApplicationDispatcher.forward( ApplicationDispatcher.java:301) at com.ysalaya.control.Control.dialog(Control.java:67) at com.ysalaya.control.Control.doGet(Control.java:30) at javax.servlet.http.HttpServlet.service(HttpServlet.java:689) at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter( ApplicationFilterChain.java:252) at org.apache.catalina.core.ApplicationFilterChain.doFilter( ApplicationFilterChain.java:173) at org.apache.catalina.core.StandardWrapperValve.invoke( StandardWrapperValve.java:213) at org.apache.catalina.core.StandardContextValve.invoke( StandardContextValve.java:178) at org.apache.catalina.core.StandardHostValve.invoke( StandardHostValve.java:126) at org.apache.catalina.valves.ErrorReportValve.invoke( ErrorReportValve.java:105) at org.apache.catalina.core.StandardEngineValve.invoke( StandardEngineValve.java:107) at org.apache.catalina.connector.CoyoteAdapter.service( CoyoteAdapter.java:148) at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:199) at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:282) at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:767) at org.apache.jk.common.ChannelSocket.processConnection( ChannelSocket.java:697) at org.apache.jk.common.ChannelSocket$SocketConnection.runIt( ChannelSocket.java:889) at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run( ThreadPool.java:684) at java.lang.Thread.run(Thread.java:534) Dynamic libraries: 0x8048000 /usr/local/jdk1.4.2/bin/java 0x2807b000 /usr/lib/libpthread.so.1 0x2809f000 /lib/libc.so.5 0x2817a000 /usr/local/jdk1.4.2/jre/lib/i386/client/libjvm.so 0x285ad000 /usr/lib/libstdc++.so.4 0x2867f000 /lib/libm.so.3 0x2869a000 /usr/local/jdk1.4.2/jre/lib/i386/native_threads/libhpi.so 0x286a8000 /usr/local/jdk1.4.2/jre/lib/i386/libverify.so 0x286bd000 /usr/local/jdk1.4.2/jre/lib/i386/libjava.so 0x286db000 /usr/local/jdk1.4.2/jre/lib/i386/libzip.so 0x286e7000 /lib/libz.so.2 0x3475f000 /usr/local/jdk1.4.2/jre/lib/i386/libnet.so 0x34d49000 /usr/local/lib/libsqlite_jni.so.0 0x34d4f000 /usr/local/lib/libsqlite3.so.8 0x2804e000 /libexec/ld-elf.so.1 Heap at VM Abort: Heap def new generation total 1792K, used 413K [0x2c5d, 0x2c7c, 0x2cab) eden space 1600K, 13% used [0x2c5d, 0x2c607418, 0x2c76) from space 192K, 99% used [0x2c79, 0x2c7bfff8, 0x2c7c) to space 192K, 0% used [0x2c76, 0x2c76, 0x2c79) tenured generation total 23484K, used 19025K [0x2cab, 0x2e19f000, 0x305d) the space 23484K, 81% used [0x2cab, 0x2dd44798, 0x2dd44800, 0x2e19f000) compacting perm gen total 9216K, used 9002K [0x305d, 0x30ed, 0x345d) the space 9216K, 97% used [0x305d, 0x30e9a908, 0x30e9aa00, 0x30ed) Local Time = Sat Jun 2 07:13:46 2007 Elapsed Time = 30289 # # The