Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-6797

If a (machine/jvm) crash happens during hard upgrade, derby does not roll back the upgrade.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 10.11.1.3, 10.12.1.1
    • None
    • Store
    • None

    Description

      When a crash happens during hard upgrade of derby, the upgrade -up to that point - is not rolled back. Depending on where the crash happens this might leave a broken database behind.

      This makes it extra important to create a backup before doing a hard upgrade.

      I have not tested this with a soft upgrade.

      I will attach a test case which uses the upgrade test suite framework and uses a call of SanityManager.DEBUG_SET("upgrade_abort") to send a flag, and a change in impl/sql/catalog/DD_version to listen for this flag.
      Thus, it's only a test that would run in a sane environment.

      But this test does show that even if we see the error during hard upgrade, the resulting database appears to be in the newer version. I have manually tested this with 10.11 (by modifying DD_version in 10.11 to throw the error regardless of sanity manager or not) and with 10.12 by running my new test.

      Attachments

        1. Prepare4Upgrade.java
          4 kB
          Myrna van Lunteren
        2. HardUpgradeAbort.java
          5 kB
          Myrna van Lunteren
        3. DERBY-6797.diff
          16 kB
          Myrna van Lunteren
        4. AfterUpgrade.java
          4 kB
          Myrna van Lunteren

        Activity

          People

            Unassigned Unassigned
            myrna Myrna van Lunteren
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: