Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-8876

DB schema updater should abort if there is a problem executing SQLs

    XMLWordPrintable

Details

    Description

      When Confluence is started for the first time after an upgrade that requires db schema modification, the SQLs are executed one after another, even if one (or all) of the SQLs failed. If a schema update error occurs, the update should abort to avoid any data corruption.

      2007-07-10 15:36:05,751 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table os_user_group add constraint FK93247246F73AEE0F foreign key (user_id) references os_user (id)
      2007-07-10 15:36:05,765 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:05,807 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table EXTRNLNKS add constraint FK97C10FE78DD41734 foreign key (CONTENTID) references CONTENT (CONTENTID)
      2007-07-10 15:36:05,809 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:05,856 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table ATTACHMENTS add constraint FK54475F9017D4A070 foreign key (PREVVER) references ATTACHMENTS (ATTACHMENTID)
      2007-07-10 15:36:05,858 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:05,919 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table ATTACHMENTS add constraint FK54475F908C38FBEA foreign key (PAGEID) references CONTENT (CONTENTID)
      2007-07-10 15:36:05,921 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:05,959 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table CONFANCESTORS add constraint FK9494E23CC45E94DC foreign key (DESCENDENTID) references CONTENT (CONTENTID)
      2007-07-10 15:36:05,961 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:06,012 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table SPACES add constraint FK9228242D16994414 foreign key (SPACEGROUPID) references SPACEGROUPS (SPACEGROUPID)
      2007-07-10 15:36:06,015 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:06,087 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table SPACES add constraint FK9228242D11B7BFEE foreign key (HOMEPAGE) references CONTENT (CONTENTID)
      2007-07-10 15:36:06,089 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:06,149 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table SPACES add constraint FK9228242D2C72D3D2 foreign key (SPACEDESCID) references CONTENT (CONTENTID)
      2007-07-10 15:36:06,151 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      2007-07-10 15:36:06,204 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table external_members add constraint FKD8C8D8A5117D5FDA foreign key (groupid) references groups (id)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,206 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table local_members add constraint FK6B8FB445117D5FDA foreign key (groupid) refer
      ences groups (id)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,241 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table local_members add constraint FK6B8FB445117D5FDA foreign key (groupid) references groups (id)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,242 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT add constraint FK6382C0598C38FBEA foreign key (PAGEID) references C
      ONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,313 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT add constraint FK6382C0598C38FBEA foreign key (PAGEID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,314 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT add constraint FK6382C05974B18345 foreign key (PARENTID) references
      CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,387 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT add constraint FK6382C05974B18345 foreign key (PARENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,389 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT add constraint FK6382C05917D4A070 foreign key (PREVVER) references
      CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,456 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT add constraint FK6382C05917D4A070 foreign key (PREVVER) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,458 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT add constraint FK6382C059B97E9230 foreign key (PARENTCOMMENTID) ref
      erences CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,517 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT add constraint FK6382C059B97E9230 foreign key (PARENTCOMMENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,519 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT add constraint FK6382C059B2DC6081 foreign key (SPACEID) references
      SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,577 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT add constraint FK6382C059B2DC6081 foreign key (SPACEID) references SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,579 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table LINKS add constraint FK45157998DD41734 foreign key (CONTENTID) references C
      ONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,636 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table LINKS add constraint FK45157998DD41734 foreign key (CONTENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,637 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table BODYCONTENT add constraint FKA898D4778DD41734 foreign key (CONTENTID) refer
      ences CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,681 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table BODYCONTENT add constraint FKA898D4778DD41734 foreign key (CONTENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,683 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table SPACEPERMISSIONS add constraint FKD33F23BEB2DC6081 foreign key (SPACEID) re
      ferences SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,724 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table SPACEPERMISSIONS add constraint FKD33F23BEB2DC6081 foreign key (SPACEID) references SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,726 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT_LABEL add constraint FKF0E7436E8DD41734 foreign key (CONTENTID) ref
      erences CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,775 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT_LABEL add constraint FKF0E7436E8DD41734 foreign key (CONTENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,777 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENT_LABEL add constraint FKF0E7436E27072AEF foreign key (LABELID) refer
      ences LABEL (LABELID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,828 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT_LABEL add constraint FKF0E7436E27072AEF foreign key (LABELID) references LABEL (LABELID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,830 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table TRACKBACKLINKS add constraint FKF6977A478DD41734 foreign key (CONTENTID) re
      ferences CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,875 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table TRACKBACKLINKS add constraint FKF6977A478DD41734 foreign key (CONTENTID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,877 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table CONTENTLOCK add constraint FK692CA9046382C059 foreign key (CONTENT) referen
      ces CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,928 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENTLOCK add constraint FK692CA9046382C059 foreign key (CONTENT) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,930 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table PAGETEMPLATES add constraint FKBC7CE96AB2DC6081 foreign key (SPACEID) refer
      ences SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,979 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table PAGETEMPLATES add constraint FKBC7CE96AB2DC6081 foreign key (SPACEID) references SPACES (SPACEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:06,981 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table PAGETEMPLATES add constraint FKBC7CE96A17D4A070 foreign key (PREVVER) refer
      ences PAGETEMPLATES (TEMPLATEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,025 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table PAGETEMPLATES add constraint FKBC7CE96A17D4A070 foreign key (PREVVER) references PAGETEMPLATES (TEMPLATEID)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,027 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:06] info (29299): CORE3282: stdout: alter table NOTIFICATIONS add constraint FK594ACC88C38FBEA foreign key (PAGEID) referen
      ces CONTENT (CONTENTID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,078 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table NOTIFICATIONS add constraint FK594ACC88C38FBEA foreign key (PAGEID) references CONTENT (CONTENTID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,080 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: alter table NOTIFICATIONS add constraint FK594ACC8B2DC6081 foreign key (SPACEID) refere
      nces SPACES (SPACEID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,125 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table NOTIFICATIONS add constraint FK594ACC8B2DC6081 foreign key (SPACEID) references SPACES (SPACEID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,126 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: alter table CONTENT_PERM add constraint FKBD74B31676E33274 foreign key (CPS_ID) referen
      ces CONTENT_PERM_SET (ID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,174 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table CONTENT_PERM add constraint FKBD74B31676E33274 foreign key (CPS_ID) references CONTENT_PERM_SET (ID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,175 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: alter table ATTACHMENTDATA add constraint FK9DC3E34D34A4917E foreign key (ATTACHMENTID)
      references ATTACHMENTS (ATTACHMENTID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,231 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsu
      ccessful: alter table ATTACHMENTDATA add constraint FK9DC3E34D34A4917E foreign key (ATTACHMENTID) references ATTACHMENTS (ATTACHMENTID)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: 2007-07-10 15:36:07,233 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can'
      t create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:07] info (29299): CORE3282: stdout: alter table CONTENT_PERM_SET add constraint FKBF45A7992CAF22C1 foreign key (CONTENT_ID)
      references CONTENT (CONTENTID)
      2007-07-10 15:36:07,269 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Unsuccessful: alter table CONTENT_PERM_SET add constraint FKBF45A7992CAF22C1 foreign key (CONTENT_ID) references CONTENT (CONTENTID)
      2007-07-10 15:36:07,270 ERROR [main] [hibernate.tool.hbm2ddl.SchemaUpdate] execute Can't create table './wikis/#sql-3c3e_481819fc.frm' (errno: 121)
      [10/Jul/2007:15:36:47] info (29299): PWC1412: WebModule[] ServletContext.log():org.tuckey.web.filters.urlrewrite.utils.Log ERROR: logLevelConf
      : null
      [10/Jul/2007:15:36:48] info (29299): PWC1412: WebModule[] ServletContext.log():org.tuckey.web.filters.urlrewrite.UrlRewriteFilter INFO: loaded
      (conf ok)
      [10/Jul/2007:15:36:48] info (29299): CORE3282: stdout: [Filter: profiling] Using parameter [profile]
      [10/Jul/2007:15:36:48] info (29299): CORE3282: stdout: [Filter: profiling] defaulting to off [autostart=false]
      [10/Jul/2007:15:36:48] info (29299): CORE3282: stdout: [Filter: profiling] Turning filter off [profile=off]
      [10/Jul/2007:15:36:51] info (29299): HTTP3072: http-listener-1: http://xxxxxx:1234 ready to accept requests
      [10/Jul/2007:15:36:51] info (29299): CORE3274: successful server startup

      Attachments

        Issue Links

          Activity

            People

              bnguyen Brian Nguyen (Inactive)
              15d9a6950818 Igor Minar
              Votes:
              5 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: