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

ERROR: relation * already exists - during migrating from MySQL to PostgreSQL

    Details

      Description

      Steps to reproduce:

      1. Start portal with MySQL.
      2. Migrate to PostgreSQL.

      Actual results:
      Many errors like relation already exists:

      03:47:59,367 ERROR [liferay/convert_process-1][ModelMigratorImpl:189] org.postgresql.util.PSQLException: ERROR: relation "group_" already exists
      org.postgresql.util.PSQLException: ERROR: relation "group_" already exists
      	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2270)
      	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1998)
      	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:570)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:406)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:334)
      	at com.zaxxer.hikari.pool.ProxyStatement.executeUpdate(ProxyStatement.java:120)
      	at com.zaxxer.hikari.pool.HikariProxyStatement.executeUpdate(HikariProxyStatement.java)
      	at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:281)
      	at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:251)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrateTable(ModelMigratorImpl.java:184)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrateModel(ModelMigratorImpl.java:152)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrate(ModelMigratorImpl.java:77)
      	at com.liferay.portal.convert.database.PortalDatabaseConverter.convert(PortalDatabaseConverter.java:37)
      	at com.liferay.portal.convert.database.DatabaseConvertProcess.doConvert(DatabaseConvertProcess.java:82)
      	at com.liferay.portal.convert.BaseConvertProcess.convert(BaseConvertProcess.java:43)
      	at com.liferay.portal.convert.messaging.ConvertProcessMessageListener.doReceive(ConvertProcessMessageListener.java:48)
      	at com.liferay.portal.convert.messaging.ConvertProcessMessageListener.receive(ConvertProcessMessageListener.java:33)
      	at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:72)
      	at com.liferay.portal.kernel.messaging.SerialDestination$1.run(SerialDestination.java:58)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:756)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:667)
      	at java.lang.Thread.run(Thread.java:724)
      
      03:47:59,381 ERROR [liferay/convert_process-1][ModelMigratorImpl:189] org.postgresql.util.PSQLException: ERROR: relation "groups_orgs" already exists
      org.postgresql.util.PSQLException: ERROR: relation "groups_orgs" already exists
      	at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2270)
      	at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1998)
      	at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:570)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:406)
      	at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:334)
      	at com.zaxxer.hikari.pool.ProxyStatement.executeUpdate(ProxyStatement.java:120)
      	at com.zaxxer.hikari.pool.HikariProxyStatement.executeUpdate(HikariProxyStatement.java)
      	at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:281)
      	at com.liferay.portal.dao.db.BaseDB.runSQL(BaseDB.java:251)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrateTable(ModelMigratorImpl.java:184)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrateModel(ModelMigratorImpl.java:152)
      	at com.liferay.portal.convert.util.ModelMigratorImpl.migrate(ModelMigratorImpl.java:77)
      	at com.liferay.portal.convert.database.PortalDatabaseConverter.convert(PortalDatabaseConverter.java:37)
      	at com.liferay.portal.convert.database.DatabaseConvertProcess.doConvert(DatabaseConvertProcess.java:82)
      	at com.liferay.portal.convert.BaseConvertProcess.convert(BaseConvertProcess.java:43)
      	at com.liferay.portal.convert.messaging.ConvertProcessMessageListener.doReceive(ConvertProcessMessageListener.java:48)
      	at com.liferay.portal.convert.messaging.ConvertProcessMessageListener.receive(ConvertProcessMessageListener.java:33)
      	at com.liferay.portal.kernel.messaging.InvokerMessageListener.receive(InvokerMessageListener.java:72)
      	at com.liferay.portal.kernel.messaging.SerialDestination$1.run(SerialDestination.java:58)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask._runTask(ThreadPoolExecutor.java:756)
      	at com.liferay.portal.kernel.concurrent.ThreadPoolExecutor$WorkerTask.run(ThreadPoolExecutor.java:667)
      	at java.lang.Thread.run(Thread.java:724)
      

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  3 years, 36 weeks, 4 days ago

                  Packages

                  Version Package
                  7.0.0 Beta 3