Hi, In my application running h2 for years, i just updated : - h2 from 1.2.128 to 1.3.160 - hibernate from 3.3.2 to 3.6.5
I'm trying to restore a database from runscript command using query: RUNSCRIPT FROM 'xxx/data-backup.sql.gz' COMPRESSION GZIP Execution fails with error : Caused by: org.hibernate.exception.GenericJDBCException: could not execute native bulk manipulation query at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:140) at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:128) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66) at org.hibernate.engine.query.NativeSQLQueryPlan.performExecuteUpdate(NativeSQLQueryPlan.java:219) at org.hibernate.impl.SessionImpl.executeNativeUpdate(SessionImpl.java:1300) at org.hibernate.impl.SQLQueryImpl.executeUpdate(SQLQueryImpl.java:365) at org.nuiton.topia.framework.TopiaContextImpl.restore(TopiaContextImpl.java:1338) ... 3 more Caused by: org.h2.jdbc.JdbcSQLException: Timeout trying to lock table "SYS"; SQL statement: SET CLUSTER '' [50200-160] at org.h2.message.DbException.getJdbcSQLException(DbException.java:329) at org.h2.message.DbException.get(DbException.java:169) at org.h2.message.DbException.get(DbException.java:146) at org.h2.table.RegularTable.doLock(RegularTable.java:500) at org.h2.table.RegularTable.lock(RegularTable.java:434) at org.h2.engine.Database.lockMeta(Database.java:748) at org.h2.engine.Database.addDatabaseObject(Database.java:862) at org.h2.command.dml.Set.addOrUpdateSetting(Set.java:401) at org.h2.command.dml.Set.update(Set.java:101) at org.h2.command.dml.RunScriptCommand.execute(RunScriptCommand.java:66) at org.h2.command.dml.RunScriptCommand.update(RunScriptCommand.java:45) at org.h2.command.CommandContainer.update(CommandContainer.java:73) at org.h2.command.Command.executeUpdate(Command.java:219) at org.h2.jdbc.JdbcPreparedStatement.executeUpdateInternal(JdbcPreparedStatement.java:143) at org.h2.jdbc.JdbcPreparedStatement.executeUpdate(JdbcPreparedStatement.java:129) at org.hibernate.engine.query.NativeSQLQueryPlan.performExecuteUpdate(NativeSQLQueryPlan.java:210) ... 6 more But, running the same query in h2 web server works well. Database is has beean tested with url : - jdbc:h2:file:/xxx/DemoRegion/data/data;FILE_LOCK=file;LOG=1;DEFAULT_LOCK_TIMEOUT=1000;DB_CLOSE_DELAY=0;LOCK_MODE=3;TRACE_LEVEL_FILE=0;TRACE_LEVEL_SYSTEM_OUT=0 - jdbc:h2:file:/xxx/DemoRegion/data/data;FILE_LOCK=no;LOG=1;DEFAULT_LOCK_TIMEOUT=1000;DB_CLOSE_DELAY=0;LOCK_MODE=3;TRACE_LEVEL_FILE=0;TRACE_LEVEL_SYSTEM_OUT=0 - jdbc:h2:file:/xxx/DemoRegion/data/data - jdbc:h2:file:/xxx/DemoRegion/data/data;MVCC=1 without success. I thinks the problem may be related to hibernate update, but i can't find any clue on this. Any idea ? Regards. -- Éric Chatellier -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to h2-database@googlegroups.com. To unsubscribe from this group, send email to h2-database+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/h2-database?hl=en.
data-backup.sql.gz
Description: GNU Zip compressed data