Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-145019

Upgrade process error on create unique index IX_7CDD4FB0 on Oracle 19c

Details

    • 4
    • Azul Zulu JDK 8
    • Apache Tomcat 9.0.x
    • Oracle Database 19c
    • Regression Bug

    Description

      At the startup of the Liferay portal from version 7.4 GA4 to version 7.4 GA6 and 7.4.13 DXP U1, during the upgrade process phase, the following SQL statement goes into error causing the portal to not start correctly.

       

      create unique index IX_7CDD4FB0 on RemoteAppEntry (companyId, iFrameURL)

       

       Below is the stack trace of the error (Liferay 7.4 GA6).

      Caused by: com.liferay.portal.kernel.log.LogSanitizerException: com.liferay.portal.kernel.upgrade.UpgradeException: Bundle com.liferay.remote.app.service_2.0.15 [1115] has invalid content in indexes.sql:_create unique index IX_7CDD4FB0 on RemoteAppEntry (companyId, iFrameURL[$COLUMN_LENGTH:4000$]);_create index IX_5F8F9C11 on RemoteAppEntry (uuid_[$COLUMN_LENGTH:75$], companyId); [Sanitized] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep._upgrade(InitialUpgradeExtender.java:311) ~[?:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.lambda$upgrade$0(InitialUpgradeExtender.java:236) ~[?:?] at com.liferay.portal.db.partition.DBPartitionUtil.forEachCompanyId(DBPartitionUtil.java:114) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.process(BaseDB.java:308) ~[portal-impl.jar:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.upgrade(InitialUpgradeExtender.java:225) ~[?:?] ... 148 more Caused by: com.liferay.portal.kernel.log.LogSanitizerException: java.sql.SQLException: ORA-01450: maximum key length (6398) exceeded_ [Sanitized] at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:509) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:461) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1104) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:550) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:268) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:655) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:229) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:41) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:928) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1205) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1747) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeLargeUpdate(OracleStatement.java:1712) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1699) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:285) ~[ojdbc8.jar:19.3.0.0.0] at com.zaxxer.hikari.pool.ProxyStatement.executeUpdate(ProxyStatement.java:117) ~[hikaricp.jar:?] at com.zaxxer.hikari.pool.HikariProxyStatement.executeUpdate(HikariProxyStatement.java) ~[hikaricp.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:349) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:315) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQLTemplateString(BaseDB.java:496) ~[portal-impl.jar:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep._upgrade(InitialUpgradeExtender.java:307) ~[?:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.lambda$upgrade$0(InitialUpgradeExtender.java:236) ~[?:?] at com.liferay.portal.db.partition.DBPartitionUtil.forEachCompanyId(DBPartitionUtil.java:114) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.process(BaseDB.java:308) ~[portal-impl.jar:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.upgrade(InitialUpgradeExtender.java:225) ~[?:?] ... 148 more Caused by: com.liferay.portal.kernel.log.LogSanitizerException: Error : 1450, Position : 35, Sql = create unique index IX_7CDD4FB0 on RemoteAppEntry (companyId, iFrameURL), OriginalSql = create unique index IX_7CDD4FB0 on RemoteAppEntry (companyId, iFrameURL), Error Msg = ORA-01450: maximum key length (6398) exceeded_ [Sanitized] at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:513) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIoer11.processError(T4CTTIoer11.java:461) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1104) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:550) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:268) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:655) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:229) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:41) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:928) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1205) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeUpdateInternal(OracleStatement.java:1747) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeLargeUpdate(OracleStatement.java:1712) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatement.executeUpdate(OracleStatement.java:1699) ~[ojdbc8.jar:19.3.0.0.0] at oracle.jdbc.driver.OracleStatementWrapper.executeUpdate(OracleStatementWrapper.java:285) ~[ojdbc8.jar:19.3.0.0.0] at com.zaxxer.hikari.pool.ProxyStatement.executeUpdate(ProxyStatement.java:117) ~[hikaricp.jar:?] at com.zaxxer.hikari.pool.HikariProxyStatement.executeUpdate(HikariProxyStatement.java) ~[hikaricp.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:349) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:315) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.runSQLTemplateString(BaseDB.java:496) ~[portal-impl.jar:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep._upgrade(InitialUpgradeExtender.java:307) ~[?:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.lambda$upgrade$0(InitialUpgradeExtender.java:236) ~[?:?] at com.liferay.portal.db.partition.DBPartitionUtil.forEachCompanyId(DBPartitionUtil.java:114) ~[portal-impl.jar:?] at com.liferay.portal.dao.db.BaseDB.process(BaseDB.java:308) ~[portal-impl.jar:?] at com.liferay.portal.spring.extender.internal.upgrade.InitialUpgradeExtender$InitialUpgradeStep.upgrade(InitialUpgradeExtender.java:225) ~[?:?] ... 148 more

       

      For more info about Oracle error, read this Oracle post How to Fix ORA-01450: Maximum Key Length (6398) Exceeded Errors

      I have used your Docker images for all versions of Liferay where I have encountered the problem.

      The oracle database is version 19c and specifically Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production.

      As for the Oracle Database, I used one of the VMs released by Oracle itself and configured via VirtualBox using this guide, https://bit.ly/332hGFQ

      For the community version of Liferay I used the driver https://github.com/amusarra/liferay-portal-database-all-in-one-support version 1.2.1. You can download the latest version binary jar from Maven Central Repository liferay-portal-database-all-in-one-support

      I found the Oracle side workaround, which consists of using the 32k Buffer Cache and created the tablespace using the 32k block. For more info read this issue https://github.com/amusarra/liferay-portal-database-all-in-one-support/issues/11 

      Attachments

        Issue Links

          Activity

            People

              support-lep@liferay.com SE Support
              amusarra Antonio Musarra
              Felipe Lins Felipe Lins
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                45 weeks, 3 days ago

                Packages

                  Version Package