Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
Database Migration issue in Liferay 7.4u92
while doing the database migration from liferay 7.2 to Liferay 7.4 im facing issue, provding the error log details for reference
2023-12-01 07:51:09.774 INFO [main][LoggingTimer:35] Completed
com.liferay.portal.db.index.IndexUpdaterUtil#lambda$updatePortalIndexes$3#Updating
portal database indexes in 36935 ms
2023-12-01 07:51:10.630 INFO
[main][LoggingTimer:74] Starting
com.liferay.portal.events.StartupHelperUtil#initResourceActions
2023-12-01 07:51:10.820 ERROR [main][BatchingBatch:134] HHH000315:
Exception executing batch [java.sql.BatchUpdateException: Duplicate
entry '6544' for key 'PRIMARY'], SQL: insert into ResourceAction
(mvccVersion, name, actionId, bitwiseValue, resourceActionId) values
(?, ?, ?, ?, ?)
2023-12-01 07:51:10.820 ERROR
[main][SqlExceptionHelper:142] Duplicate entry '6544' for key
'PRIMARY'
2023-12-01 07:51:10.838 INFO [main][LoggingTimer:35]
Completed
com.liferay.portal.events.StartupHelperUtil#initResourceActions in 206
ms
2023-12-01 07:51:10.838 ERROR [main][DBUpgrader:70] null
org.springframework.dao.DataIntegrityViolationException: could not
execute batch; SQL [insert into ResourceAction (mvccVersion, name,
actionId, bitwiseValue, resourceActionId) values (?, ?, ?, ?, ?)];
constraint [PRIMARY]; nested exception is
org.hibernate.exception.ConstraintViolationException: could not
execute batch
at
org.springframework.orm.hibernate5.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:245)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.convertHibernateAccessException(HibernateTransactionManager.java:804)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:639)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:743)
~[spring-tx.jar:5.2.24.RELEASE]
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711)
~[spring-tx.jar:5.2.24.RELEASE]
at
com.liferay.portal.spring.transaction.DefaultTransactionExecutor.commit(DefaultTransactionExecutor.java:32)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:68)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:48)
~[portal-impl.jar:?]
at
com.liferay.change.tracking.internal.aop.CTTransactionAdvice.invoke(CTTransactionAdvice.java:70)
~[?:?]
at
com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:48)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.aop.AopInvocationHandler.invoke(AopInvocationHandler.java:40)
~[portal-impl.jar:?]
at
com.sun.proxy.$Proxy121.checkResourceActions(Unknown Source)
~[?:?]
at
com.liferay.portal.security.permission.ResourceActionsImpl.populateModelResources(ResourceActionsImpl.java:458)
~[portal-impl.jar:?]
at
com.liferay.portal.security.permission.ResourceActionsImpl.populateModelResources(ResourceActionsImpl.java:434)
~[portal-impl.jar:?]
at
com.liferay.portal.kernel.security.permission.ResourceActionsUtil.populateModelResources(ResourceActionsUtil.java:182)
~[portal-kernel.jar:?]
at
com.liferay.portal.events.StartupHelperUtil.initResourceActions(StartupHelperUtil.java:49)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader._checkClassNamesAndResourceActions(DBUpgrader.java:342)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader.upgradePortal(DBUpgrader.java:314)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader.main(DBUpgrader.java:153)
[portal-impl.jar:?]
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
~[?:1.8.0_241]
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~[?:1.8.0_241]
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~[?:1.8.0_241]
at
java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_241]
at
com.liferay.portal.tools.db.upgrade.client.DBUpgraderLauncher.main(DBUpgraderLauncher.java:45)
[com.liferay.portal.tools.db.upgrade.client.jar:?]
Caused by:
org.hibernate.exception.ConstraintViolationException: could not
execute batch
at
org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:109)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:37)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:135)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
Caused by:
java.sql.BatchUpdateException: Duplicate entry '6544' for key
'PRIMARY'
at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
~[?:1.8.0_241]
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
~[?:1.8.0_241]
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
~[?:1.8.0_241]
at
java.lang.reflect.Constructor.newInstance(Constructor.java:423)
~[?:1.8.0_241]
at
com.mysql.cj.util.Util.handleNewInstance(Util.java:191)
~[mysql.jar:8.0.15]
at
com.mysql.cj.util.Util.getInstance(Util.java:166)
~[mysql.jar:8.0.15]
at
com.mysql.cj.util.Util.getInstance(Util.java:173)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLError.createBatchUpdateException(SQLError.java:224)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchedInserts(ClientPreparedStatement.java:772)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchInternal(ClientPreparedStatement.java:443)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.StatementImpl.executeBatch(StatementImpl.java:814)
~[mysql.jar:8.0.15]
at
com.zaxxer.hikari.pool.ProxyStatement.executeBatch(ProxyStatement.java:127)
~[hikaricp.jar:?]
at
com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeBatch(HikariProxyPreparedStatement.java)
~[hikaricp.jar:?]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:125)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
Caused by:
java.sql.SQLIntegrityConstraintViolationException: Duplicate entry
'6544' for key 'PRIMARY'
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:117)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:970)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1109)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1057)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeLargeUpdate(ClientPreparedStatement.java:1377)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchedInserts(ClientPreparedStatement.java:733)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchInternal(ClientPreparedStatement.java:443)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.StatementImpl.executeBatch(StatementImpl.java:814)
~[mysql.jar:8.0.15]
at
com.zaxxer.hikari.pool.ProxyStatement.executeBatch(ProxyStatement.java:127)
~[hikaricp.jar:?]
at
com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeBatch(HikariProxyPreparedStatement.java)
~[hikaricp.jar:?]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:125)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
2023-12-01
07:51:10.900 INFO [main][UpgradeRecorder:153] Major upgrade finished
with result failure
Failed Liferay upgrade process in 242 seconds
Connecting to Gogo
shell because the upgrade failed or is incomplete
Portal upgrade
failed. Fix the issue and retry.
Hello sowjanya,
Make sure the DB schema is pointed to old schema to be upgraded and Re-check the steps from liferay's documentation.
Use this in portal-upgrade-ext.properties
rewriteBatchedStatements=true
liferay.home=[liferay-home]
module.framework.base.dir=[liferay-home]/osgi
dl.store.impl=com.liferay.portal.store.file.system.FileSystemStore
Use this in portal-upgrade-database.properties
jdbc.default.driverClassName=com.mysql.cj.jdbc.Driver
jdbc.default.url=jdbc:mysql://localhost:3306/YOUR_OLD_SCHEMA?characterEncoding=UTF-8&dontTrackOpenResources=true&holdResultsOpenOverStatementClose=true&rewriteBatchedStatements=true&serverTimezone=GMT&useFastDateParsing=false&useUnicode=true
jdbc.default.username=root
jdbc.default.password=root
Use this in app-server.properties
dir=[liferay-home]\tomcat-9.0.75
extra.lib.dirs=/bin
global.lib.dir=/lib
portal.dir=/webapps/ROOT
server.detector.server.id=tomcat
and Start the migration using [liferay-home]\tools\portal-tools-db-upgrade-client\db_upgrade.bat
Thanks,
Vinoth kumar
Thank you Vinoth kumar for your response.. we did follow the steps as you mentioned but still we are getting the same issue.I'm adding the log file for your response.Please let us know if there is any suggestions.
Thank You...
2023-12-13 11:07:50.958 INFO [main][BaseDB:1460] create index
IX_6A3E4238 on VirtualHost (companyId, layoutSetId,
defaultVirtualHost, ctCollectionId);
2023-12-13 11:07:50.989 INFO
[main][BaseDB:1460] create unique index IX_76A64FBE on VirtualHost
(hostname, ctCollectionId);
2023-12-13 11:07:51.027 INFO
[main][BaseDB:1460] create index IX_1079582F on VirtualHost
(layoutSetId, hostname, ctCollectionId);
2023-12-13 11:07:51.054
INFO [main][BaseDB:1460] create index IX_6483FCD4 on
WorkflowDefinitionLink (companyId, ctCollectionId);
2023-12-13
11:07:51.070 INFO [main][BaseDB:1460] create index IX_701BF76D on
WorkflowDefinitionLink (companyId, workflowDefinitionName,
workflowDefinitionVersion, ctCollectionId);
2023-12-13
11:07:51.101 INFO [main][BaseDB:1460] create index IX_B6C5C563 on
WorkflowDefinitionLink (groupId, companyId, classNameId, classPK,
ctCollectionId);
2023-12-13 11:07:51.118 INFO [main][BaseDB:1460]
create index IX_65327B4C on WorkflowDefinitionLink (groupId,
companyId, classNameId, classPK, typePK, ctCollectionId);
2023-12-13 11:07:51.133 INFO [main][BaseDB:1460] create index
IX_5E9866FC on WorkflowDefinitionLink (groupId, companyId,
classNameId, ctCollectionId);
2023-12-13 11:07:51.164 INFO
[main][BaseDB:1460] create index IX_52C09F91 on
WorkflowDefinitionLink (groupId, companyId, classPK,
ctCollectionId);
2023-12-13 11:07:51.195 INFO [main][BaseDB:1460]
create index IX_688A5865 on WorkflowInstanceLink (groupId, companyId,
classNameId, classPK, ctCollectionId);
2023-12-13 11:07:51.226
INFO [main][BaseDB:1460] create index IX_6E4C09BA on
WorkflowInstanceLink (groupId, companyId, classNameId,
ctCollectionId);
2023-12-13 11:07:51.243 INFO
[main][LoggingTimer:35] Completed
com.liferay.portal.db.index.IndexUpdaterUtil#lambda$updatePortalIndexes$3#Updating
portal database indexes in 33540 ms
2023-12-13 11:07:51.621 INFO
[main][LoggingTimer:74] Starting
com.liferay.portal.events.StartupHelperUtil#initResourceActions
2023-12-13 11:07:51.684 ERROR [main][BatchingBatch:134] HHH000315:
Exception executing batch [java.sql.BatchUpdateException: Duplicate
entry '6544' for key 'PRIMARY'], SQL: insert into ResourceAction
(mvccVersion, name, actionId, bitwiseValue, resourceActionId) values
(?, ?, ?, ?, ?)
2023-12-13 11:07:51.684 ERROR
[main][SqlExceptionHelper:142] Duplicate entry '6544' for key
'PRIMARY'
2023-12-13 11:07:51.700 INFO [main][LoggingTimer:35]
Completed
com.liferay.portal.events.StartupHelperUtil#initResourceActions in 79
ms
2023-12-13 11:07:51.700 ERROR [main][DBUpgrader:70] null
org.springframework.dao.DataIntegrityViolationException: could not
execute batch; SQL [insert into ResourceAction (mvccVersion, name,
actionId, bitwiseValue, resourceActionId) values (?, ?, ?, ?, ?)];
constraint [PRIMARY]; nested exception is
org.hibernate.exception.ConstraintViolationException: could not
execute batch
at
org.springframework.orm.hibernate5.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:245)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.convertHibernateAccessException(HibernateTransactionManager.java:804)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:639)
~[spring-orm.jar:5.2.24.RELEASE]
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:743)
~[spring-tx.jar:5.2.24.RELEASE]
at
org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:711)
~[spring-tx.jar:5.2.24.RELEASE]
at
com.liferay.portal.spring.transaction.DefaultTransactionExecutor.commit(DefaultTransactionExecutor.java:32)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:68)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:48)
~[portal-impl.jar:?]
at
com.liferay.change.tracking.internal.aop.CTTransactionAdvice.invoke(CTTransactionAdvice.java:70)
~[?:?]
at
com.liferay.portal.spring.aop.AopMethodInvocationImpl.proceed(AopMethodInvocationImpl.java:48)
~[portal-impl.jar:?]
at
com.liferay.portal.spring.aop.AopInvocationHandler.invoke(AopInvocationHandler.java:40)
~[portal-impl.jar:?]
at
com.sun.proxy.$Proxy140.checkResourceActions(Unknown Source)
~[?:?]
at
com.liferay.portal.security.permission.ResourceActionsImpl.populateModelResources(ResourceActionsImpl.java:458)
~[portal-impl.jar:?]
at
com.liferay.portal.security.permission.ResourceActionsImpl.populateModelResources(ResourceActionsImpl.java:434)
~[portal-impl.jar:?]
at
com.liferay.portal.kernel.security.permission.ResourceActionsUtil.populateModelResources(ResourceActionsUtil.java:182)
~[portal-kernel.jar:?]
at
com.liferay.portal.events.StartupHelperUtil.initResourceActions(StartupHelperUtil.java:49)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader._checkClassNamesAndResourceActions(DBUpgrader.java:342)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader.upgradePortal(DBUpgrader.java:314)
~[portal-impl.jar:?]
at
com.liferay.portal.tools.DBUpgrader.main(DBUpgrader.java:153)
[portal-impl.jar:?]
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
~[?:1.8.0_241]
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
~[?:1.8.0_241]
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
~[?:1.8.0_241]
at
java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_241]
at
com.liferay.portal.tools.db.upgrade.client.DBUpgraderLauncher.main(DBUpgraderLauncher.java:45)
[com.liferay.portal.tools.db.upgrade.client.jar:?]
Caused by:
org.hibernate.exception.ConstraintViolationException: could not
execute batch
at
org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:109)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:37)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:113)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:135)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
Caused by:
java.sql.BatchUpdateException: Duplicate entry '6544' for key
'PRIMARY'
at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
~[?:1.8.0_241]
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
~[?:1.8.0_241]
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
~[?:1.8.0_241]
at
java.lang.reflect.Constructor.newInstance(Constructor.java:423)
~[?:1.8.0_241]
at
com.mysql.cj.util.Util.handleNewInstance(Util.java:191)
~[mysql.jar:8.0.15]
at
com.mysql.cj.util.Util.getInstance(Util.java:166)
~[mysql.jar:8.0.15]
at
com.mysql.cj.util.Util.getInstance(Util.java:173)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLError.createBatchUpdateException(SQLError.java:224)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchedInserts(ClientPreparedStatement.java:772)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchInternal(ClientPreparedStatement.java:443)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.StatementImpl.executeBatch(StatementImpl.java:814)
~[mysql.jar:8.0.15]
at
com.zaxxer.hikari.pool.ProxyStatement.executeBatch(ProxyStatement.java:127)
~[hikaricp.jar:?]
at
com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeBatch(HikariProxyPreparedStatement.java)
~[hikaricp.jar:?]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:125)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
Caused by:
java.sql.SQLIntegrityConstraintViolationException: Duplicate entry
'6544' for key 'PRIMARY'
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:117)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:970)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1109)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeUpdateInternal(ClientPreparedStatement.java:1057)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeLargeUpdate(ClientPreparedStatement.java:1377)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchedInserts(ClientPreparedStatement.java:733)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.ClientPreparedStatement.executeBatchInternal(ClientPreparedStatement.java:443)
~[mysql.jar:8.0.15]
at
com.mysql.cj.jdbc.StatementImpl.executeBatch(StatementImpl.java:814)
~[mysql.jar:8.0.15]
at
com.zaxxer.hikari.pool.ProxyStatement.executeBatch(ProxyStatement.java:127)
~[hikaricp.jar:?]
at
com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeBatch(HikariProxyPreparedStatement.java)
~[hikaricp.jar:?]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.performExecution(BatchingBatch.java:125)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.BatchingBatch.doExecuteBatch(BatchingBatch.java:110)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.batch.internal.AbstractBatchImpl.execute(AbstractBatchImpl.java:153)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.executeBatch(JdbcCoordinatorImpl.java:198)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:633)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.spi.ActionQueue.lambda$executeActions$1(ActionQueue.java:478)
~[hibernate-core.jar:5.6.7.Final]
at
java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
~[?:1.8.0_241]
at
org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:475)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:344)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.event.service.internal.EventListenerGroupImpl.fireEventOnEachListener(EventListenerGroupImpl.java:107)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.doFlush(SessionImpl.java:1407)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:489)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3290)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2425)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:449)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:183)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$300(JdbcResourceLocalTransactionCoordinatorImpl.java:40)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:281)
~[hibernate-core.jar:5.6.7.Final]
at
org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:101)
~[hibernate-core.jar:5.6.7.Final]
at
org.springframework.orm.hibernate5.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:627)
~[spring-orm.jar:5.2.24.RELEASE]
... 21 more
2023-12-13
11:07:51.716 INFO [main][UpgradeRecorder:153] Major upgrade finished
with result failure
Failed Liferay upgrade process in 165 seconds
Connecting to Gogo
shell because the upgrade failed or is incomplete
Type "help" to get available upgrade and verify
commands.
Type "help {command}" to get additional
information about the command. For example, "help
upgrade:list".
Enter "exit" or "quit" to exit.
Powered by Liferay™