AnsweredAssumed Answered

Reliability about DB Hot backup

Question asked by zomurn on Feb 22, 2010
Hello,

After restoring a hot bakup of the database, users now have one time over 2, an LockAcquisitionException:

14:42:53,272 User:numeriseur DEBUG [action.executer.MscImporterCourrierEntrantExecuter] Moving 22021085639.pdf to folder Editer
org.alfresco.module.msc_core.action.exception.MscActionException: org.springframework.dao.CannotAcquireLockException: could not execute query using scroll; nested exception is org.hibernate.exception.LockAcquisitionException: could not execute query using scroll
   at org.alfresco.module.msc_core.web.bean.dialog.MscAbstractEditerWebDialog$1.execute(MscAbstractEditerWebDialog.java:174)
   at org.alfresco.module.msc_core.web.bean.dialog.MscAbstractEditerWebDialog$1.execute(MscAbstractEditerWebDialog.java:142)
   at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:322)
   at org.alfresco.module.msc_core.web.bean.dialog.MscAbstractEditerWebDialog.boutonArchiver(MscAbstractEditerWebDialog.java:189)
   at sun.reflect.GeneratedMethodAccessor1357.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:132)
   at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:61)
   at javax.faces.component.UICommand.broadcast(UICommand.java:109)
   at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:97)
   at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:171)
   at org.apache.myfaces.lifecycle.InvokeApplicationExecutor.execute(InvokeApplicationExecutor.java:32)
   at org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:95)
   at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:70)
   at javax.faces.webapp.FacesServlet.service(FacesServlet.java:139)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
   at org.alfresco.web.app.servlet.AuthenticationFilter.doFilter(AuthenticationFilter.java:81)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
   at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
   at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
   at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
   at java.lang.Thread.run(Thread.java:619)
Caused by: org.springframework.dao.CannotAcquireLockException: could not execute query using scroll; nested exception is org.hibernate.exception.LockAcquisitionException: could not execute query using scroll
   at org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:618)
   at org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412)
   at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:377)
   at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:338)
   at org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl.getChildAssocs(HibernateNodeDaoServiceImpl.java:2197)
   at org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl.setFixedAcls(HibernateNodeDaoServiceImpl.java:2126)
   at org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl.updateChildAssoc(HibernateNodeDaoServiceImpl.java:2051)
   at sun.reflect.GeneratedMethodAccessor1004.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
   at org.alfresco.repo.transaction.TransactionalDaoInterceptor.invoke(TransactionalDaoInterceptor.java:68)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.alfresco.repo.domain.hibernate.DirtySessionMethodInterceptor.invoke(DirtySessionMethodInterceptor.java:381)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
   at $Proxy2.updateChildAssoc(Unknown Source)
   at org.alfresco.repo.node.db.DbNodeServiceImpl.moveNode(DbNodeServiceImpl.java:2012)
   at sun.reflect.GeneratedMethodAccessor846.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
   at org.alfresco.repo.transaction.SingleEntryTransactionResourceInterceptor.invokeInternal(SingleEntryTransactionResourceInterceptor.java:163)
   at org.alfresco.repo.transaction.SingleEntryTransactionResourceInterceptor.invoke(SingleEntryTransactionResourceInterceptor.java:138)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
   at $Proxy7.moveNode(Unknown Source)
   at sun.reflect.GeneratedMethodAccessor846.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
   at org.alfresco.repo.tenant.MultiTNodeServiceInterceptor.invoke(MultiTNodeServiceInterceptor.java:110)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
   at $Proxy7.moveNode(Unknown Source)
   at sun.reflect.GeneratedMethodAccessor846.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.alfresco.repo.service.StoreRedirectorProxyFactory$RedirectorInvocationHandler.invoke(StoreRedirectorProxyFactory.java:221)
   at $Proxy8.moveNode(Unknown Source)
   at sun.reflect.GeneratedMethodAccessor846.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
   at java.lang.reflect.Method.invoke(Method.java:597)
   at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:304)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
   at org.alfresco.repo.node.MLPropertyInterceptor.invoke(MLPropertyInterceptor.java:306)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.alfresco.repo.node.MLPropertyInterceptor.invoke(MLPropertyInterceptor.java:306)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.alfresco.repo.node.NodeRefPropertyMethodInterceptor.invoke(NodeRefPropertyMethodInterceptor.java:274)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.alfresco.repo.node.NodeRefPropertyMethodInterceptor.invoke(NodeRefPropertyMethodInterceptor.java:274)
   at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
   at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
   at $Proxy7.moveNode(Unknown Source)
   at org.alfresco.repo.model.filefolder.FileFolderServiceImpl.moveOrCopy(FileFolderServiceImpl.java:633)
   at org.alfresco.repo.model.filefolder.FileFolderServiceImpl.move(FileFolderServiceImpl.java:539)
   at org.alfresco.module.msc_core.action.MscAbstractMoveDocumentAction.moveDocument(MscAbstractMoveDocumentAction.java:168)
   at org.alfresco.module.msc_core.action.MscAbstractMoveDocumentAction.run(MscAbstractMoveDocumentAction.java:58)
   at org.alfresco.module.msc_core.action.MscAbstractAction$1.execute(MscAbstractAction.java:117)
   at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:322)
   at org.alfresco.module.msc_core.action.MscAbstractAction.execute(MscAbstractAction.java:123)
   at org.alfresco.module.msc_core.web.bean.dialog.MscAbstractEditerWebDialog$1.execute(MscAbstractEditerWebDialog.java:167)
   … 30 more
Caused by: org.hibernate.exception.LockAcquisitionException: could not execute query using scroll
   at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:82)
   at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
   at org.hibernate.loader.Loader.scroll(Loader.java:2321)
   at org.hibernate.loader.hql.QueryLoader.scroll(QueryLoader.java:441)
   at org.hibernate.hql.ast.QueryTranslatorImpl.scroll(QueryTranslatorImpl.java:390)
   at org.hibernate.engine.query.HQLQueryPlan.performScroll(HQLQueryPlan.java:245)
   at org.hibernate.impl.SessionImpl.scroll(SessionImpl.java:1206)
   at org.hibernate.impl.QueryImpl.scroll(QueryImpl.java:67)
   at org.alfresco.repo.node.db.hibernate.HibernateNodeDaoServiceImpl$16.doInHibernate(HibernateNodeDaoServiceImpl.java:2191)
   at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:372)
   … 97 more
Caused by: java.sql.SQLException: La transaction (ID de processus 52) a été bloquée sur les ressources verrou par un autre processus et a été choisie comme victime. Réexécutez la transaction.
   at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:368)
   at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2816)
   at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2254)
   at net.sourceforge.jtds.jdbc.TdsCore.isDataInResultSet(TdsCore.java:795)
   at net.sourceforge.jtds.jdbc.JtdsResultSet.<init>(JtdsResultSet.java:146)
   at net.sourceforge.jtds.jdbc.JtdsStatement.executeSQLQuery(JtdsStatement.java:483)
   at net.sourceforge.jtds.jdbc.JtdsPreparedStatement.executeQuery(JtdsPreparedStatement.java:777)
   at org.apache.commons.dbcp.DelegatingPreparedStatement.executeQuery(DelegatingPreparedStatement.java:92)
   at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:186)
   at org.hibernate.loader.Loader.getResultSet(Loader.java:1787)
   at org.hibernate.loader.Loader.scroll(Loader.java:2286)
   … 104 more

I've a "heavy" hot backup in the sens, a High Cpu intensive process was executing on the application : a bulk move of thousands of documents from one folder to another.
During this time, a hot backup was executed (MS SQL Server 2005)
Now user have this strange error : LockAcquisitionException

Any idea ?

Outcomes