This page last changed on May 31, 2009 by alui.

JIRA can be configured to automatically create an XML backup of JIRA data on a routine basis.

The XML backup includes all data in the database. However, it does not include attachments, which are on the filesystem.
For production use, it is strongly recommended to use native database-specific tools instead of the XML backup service. The XML backup is not guaranteed to be consistent, as the database is not locked during the backup process.

When JIRA is installed, the first step in the Setup Wizard prompts you for a backup path, and if entered, JIRA will automatically generate XML backups (as ZIP files) every 12 hours. If you did not specify this path, follow the steps below to enable automated backups. (Note that you can also perform XML backups manually - see Backing up data. )

  1. Log in as a user with the 'JIRA System Administrators' global permission.
  2. Bring up the administration page by clicking either the 'Administration' link on the top bar or the title of the Administration box on the dashboard.
  3. Under the 'System' sub-menu in the left-hand navigation column, click the 'Services' link.
  4. This will display the 'Services' page. It lists the current services running on this system. By default there should be one service running: 'Mail Queue Service'. You cannot delete this service.
  5. Fill in the 'Add Service' form as follows:
    • For 'Name', enter a descriptive name, e.g. Backup Service
    • For Class, enter com.atlassian.jira.service.services.export.ExportService
    • For 'Delay', enter the number of minutes between backups. A good default for this would be 720 minutes (12 hours).Click the 'Add Service' buttont.
  6. This will display the 'Edit Service' screen. Fill in the following fields:
    • If you wish to write your backup files to the the default directory, leave the 'Use Default Directory' checkbox checked. By default, your backup files are written to your JIRA home directory under the exports sub-directory.
    • If you wish to specify a different sub-directory, type the full path of the directory to which JIRA will write backup files in the 'Directory Name' textbox. Ensure that the 'Use Default Directory' checkbox is unchecked and that JIRA has rights to write to this location.
      Changing your backups path
      If you are running a large instance of JIRA, you may wish to consider moving your backups directory from the default directory under JIRA home to another machine. The directory which stores your backups may need to hold a considerable amount of data. Hence, it may be more efficient for you to host the attachments on a separate network drive.

      If you change your backups directory, please ensure that it is given appropriate security, as described in Security Overview.

    • For 'Date format', specify the format which JIRA will use to name the individual backup files. This format can be anything that SimpleDateFormat can parse. A good default is 'yyyy-MMM-dd-HHmm', which would generate files named like this: '2007-Mar-05-1322'.
    • For 'Backup as:', either:
      • Select 'XML' to have JIRA store your data as an XML file; or
      • Select Zip' to have JIRA to compress your backup and store it as a ZIP file.
  7. Your backup service is now configured. XML backups will be performed according to the schedule you specified in the Delay field (above).
    • For every successful backup, an XML (or ZIP) file will be saved in the backup directory that you specified in the Directory Name field (above).
    • If a scheduled backup fails for any reason, the XML (or ZIP) file will be saved into the 'corrupted' directory, which is directly under your nominated backup directory. (NB. JIRA will created the 'corrupted' directory if required - you don't need to create it.) Additionally, a file explaining the reason for the failure will be written to the 'corrupted' directory. This file will have the same name as the backup file, but with the extension '.failure.txt'.

Document generated by Confluence on Oct 06, 2009 00:26