Uploaded image for project: 'Bitbucket Data Center'
  1. Bitbucket Data Center
  2. BSERV-7886

Prevent startup of Bitbucket Server when the data directory (BITBUCKET_HOME) is newer than the application being started

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Medium
    • 5.12.0, 5.9.2, 5.11.2, 5.8.4, 5.10.2, 5.14.0
    • 4.0.1, 4.14.2, 5.10.0
    • None
    • None

    Description

      When Bitbucket Server is started, we should prevent the application from running if the database or home directory is of a newer version than the binary.

      Currently, we log a warning, but we should prevent the server from starting.

      2015-09-30 11:50:23,379 WARN  [spring-startup]  c.a.s.internal.ApplicationSettings The configured home directory /home/bitbucket is at a higher build version 5.10.0 than the Bitbucket code build version 5.3.2

      It would be better to prevent this mismatch from continuing on so that the administrator can take the appropriate action if this is unintentional. If intentional, it would be ideal to have a flag or configuration parameter that could be used to allow the application to start.

      Diagnosis

      At some point a newer binary was used to start the application which upgraded the data directory (logging this here: BITBUCKET_HOME/.version) and possibly the database.

      Workaround

      You accidentally started the application with an old binary
      1. Stop the application.
      2. Start the application using the correct, newer, binary.
      You are attempting to recover from a failed upgrade
      Option A
      1. Stop the application.
      2. Roll back the file system to the point immediately prior to upgrade (this must match the database).
      3. Roll back the database to the point immediately prior to upgrade (this must match the files system).
      4. Start the application with the original binary.
      Option B
      1. Stop the application.
      2. Open a Support Request at support.atlassian.com indicating that your upgrade failed, include the version you are currently on and the version you want to upgrade to, and attach the latest application log file (e.g. atlassian-bitbucket.log).

      Attachments

        Issue Links

          Activity

            People

              bturner Bryan Turner (Inactive)
              jethomas Jeff Thomas
              Votes:
              2 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: