Backing up and restoring Fisheye data

Fisheye data can be backed up from the admin interface or command line. This page contains the command syntax, options and the required procedure to back up and restore your Fisheye instance.

If you are migrating to a different machine, please follow the instructions on our Migrating Fisheye Between Servers page.

Backing up using admin interface

  1. Navigate to the Fisheye Admin area (click Administration in the footer of any Fisheye page).
  2. In the left navigation bar, click Backup.
  3. On the Backup screen, you can edit the name of the backup file that will be generated.
  4. Choose the components, described in the table below, that should be included in the backup file.
    Note that the back up will always include the configuration data (config.xml), your license file and the Fisheye user data.
    (info) Repository and application caches contain temporary data stored from repository scans and library caches that improve startup time. Both will be recreated automatically by re-scanning the source repositories, so the backup files can be significantly reduced by excluding these (if the cost of re-scanning is acceptable).
  5. Click Create Backup Now.



ActiveObjectsData that is stored by plugins

Repository and application caches

The cache contains data that reflects the state of Fisheye's repositories. Without it, Fisheye must re-scan its repositories after a backup is restored. The cache also contains OSGI library data that increases startup time. These too can be excluded and will be generated automatically when the application is started.


Plugins are 3rd-party extensions that you may have installed, and configuration for all plugins (this includes configuration for Crucible's set of standard plugins).

SQL Database

Refers to the SQL content database (used by both Fisheye and Crucible and containing all user profile data, reviews and their comments).

Web templates

In this context, these are custom freemarker templates that you or your users have created. They live in FISHEYE_INST/template.

Uploaded files

In this context, uploads refers to files which are added to Crucible via the web interface (such as patch file reviews). It also includes each repository-backed file that went under review, when Crucible is configured to make a local copy of every reviewed file.

Using the command line to back up

(info) Your Fisheye instance must be running during the back up.

  1. Open a terminal or command prompt on the Fisheye server computer.
  2. Navigate to <FishEye install directory>/bin/.
  3. Run the backup command on the command line using any desired options (described in the table below). By default, all backup components, except repository cache data, is included in the backup.

The backup is created as a new Zip archive file and placed in the FISHEYE_INST/backup/ directory.
(info) Note that if your Fisheye instance uses a custom FISHEYE_INST directory, make sure the environment variable is properly set when running the backup command.



Default setting

Quiet mode

-q, --quiet


Output filename

-f, --file

FISHEYE_INST/backup/ is the default directory.

Compression level

-c, --compression

Yes (6)


-a, --anonymize


Cache Backup


No. By default, the cache data is excluded from backups.

Debug--debugPrint extra information to the debug log.


Advanced backup command line settings

In some cases it might be preferable to only back up a limited set of items. This could be useful when your instance uses an external database such as MySQL or PostgreSQL and your DBA has already configured automatic back ups in the database. The commands below allow this.





Exclude Plugins


Excludes plugins from the backup.

No. By default, plugins are included in every backup.

Exclude Templates


Excludes templates from the backup.

No. By default, templates are included in every backup.

Exclude Uploads


Excludes uploaded files (such as patch reviews, stored in Crucible's internal database) from the backup. (info) This item only applies when using Crucible with Fisheye.

No. By default, uploads are included in every backup.

Exclude SQL Database


Excludes the SQL content database used by both Fisheye and Crucible.

No. By default, this data is included in every backup.

Show help

--help OR -h

Shows inline help on the command line.


Backup command line examples

(info) These examples are for use in a Linux-like operating system. When using these commands on Windows, use the filename fisheyectl.bat and use the correct slashes. Run the command from the <FishEye install directory>/bin/ directory.

The basic syntax of the backup command is as follows:

$ ./ backup [OPTIONS]

To see inline help for all backup options, run the following command in the <FishEye install directory>/bin/ directory:

$ ./ backup --help

Backing up with compression of 9, quiet mode and setting an output location:

$ ./ backup --compression 9 -q -f /application_backups/fisheye/

Back up including cache data (also includes all default components):

$ ./ backup --cache

Known limitations

Archives Larger Than 4GB
Be aware of the fact that some file systems (like FAT32) have trouble with files larger than 4GB. If you still want to archive everything and end up with an archive that is too large, consider creating separate backups for the Fisheye cache and uploaded files respectively.

Scheduling Fisheye backups

To set a schedule for automatic backups:

  1. Go to the Admin area and click Backup (under 'System Settings').
  2. Click Manage Scheduled Backups at the bottom of the page.
  3. Click Edit, set the desired options, then click Save.

The options for scheduled back ups are detailed in the table below:

Option name


Allowed Values

Disable Scheduled Backups

Stops regular back ups from taking place.

On (disabled) or Off (enabled)

Backup path

The path where the backup .zip file will be stored.

Any system or network path that Fisheye or Crucible can access. This cannot be changed using the Fisheye interface. Please edit your config.xml, and add the <path> attribute according to this example:

<schedule enabled="true">
<items> <item name="sql"/>
<item name="templates"/>
<item name="cache"/>
<item name="ao"/>
<item name="plugins"/>
<item name="uploads"/>

Save changes, and restart your Fisheye instance.

Backup file prefix

Characters that will be added to the beginning of the backup file name.

Any string of characters that can be used as part of a filename on the local operating system.

Backup file date pattern

Sets a date for the next (or initial) back up to take place.

Any valid date in the format yyyy_MM_dd (year, month, day of the month).

Backup frequency

Sets how often the back up will take place.

Can be set to every day, every Sunday, Monday to Friday and first day of the month.

Backup time (HH:mm)

The time when the back up will take place.

Any valid 24-hour time in the format HH:mm (hours, minutes).


Specifies which items must be included in the backups (these components are explained at the top of this page).

As per the options for regular on-demand back up (These components are explained at the top of this page).

(info) Be aware that scheduled back ups can fill up disks unless you regularly move or delete old archives.

Restoring Fisheye data

Starting from Fisheye 4.6.1, if you restore from backup, the NETWORK_SERVICE user must full control over the $FISHEYE_INST folder. Otherwise the service won't start. The $FISHEYE_INST folder is by default located in C:\Atlassian\Data\fecru.

Using the command line to restore Fisheye data

There is currently no way to restore a backup from the admin interface because Fisheye must be shut down during a data restore.

(warning) Restoring a backup will irreversibly overwrite the data of your installation with the data from the backup archive. Note that you cannot restore data into versions of Fisheye which are older than the version that created the backup.

  1. Install Fisheye into a new, empty directory (this must be the same version that the backup was created from, or later).
  2. Make sure the Fisheye instance is not running.
  3. Open a command line interface on the Fisheye server computer.
  4. Run the restore command on the command line with any desired options.
  5. The specified elements will be restored.
  6. Start the Fisheye instance.
  7. When using Fisheye integrated with Crucible, you will need to re-index your repositories after restoring data, unless the backup archive was created with the --cache option.

Command line restore options

By default, the restore process will restore all items found in the backup archive (so if you included the caches using the --cache option, these will automatically be restored). However, you can specify a partial restore, by explicitly specifying the item names on the command line.

If you are using an external database (as opposed to the default HSQL database), make sure the JDBC driver file is present in the FISHEYE_INST/lib directory when running restore.

Furthermore, if you are restoring to a new Fisheye instance and install directory, and select --dbtype of mysql, you must download the JDBC driver and accept the license agreement before proceeding with the restore.

The options available for use with the restore command are listed in the following table:




Choose file to restore from



(Required) Restore the backup from PATH/FILENAME.

Repository and application caches


Restore the repository cache backup.

Restore plugins


Restore 3rd-party plugins and their configuration data.

Web templates


Restore freemarker templates from the backup (the restored instance will use the built-in templates).

Uploaded files


Restore uploads (e.g. patch files uploaded into Crucible and contents of files under review). (info) This item only applies when using Crucible with Fisheye.

SQL Database


Restore the SQL database containing user profiles, reviews and review comments.

ActiveObjects--aoRestore ActiveObjects data stored by plugins.
List backup contents-l, --listList the contents of the backup file, and exit.

Set database type

-t, --dbtype

SQL database type (hsql, mysql, oracle, postgresql, sqlserver2012). Only required when restoring to a database location different to that used at back up time.


-j, --jdbcurl

JDBC URL of the SQL database. Only required when restoring to a database location different to that used at used at back up time (not applicable for hsql).

Set JDBC username

-u, --username

JDBC username of the SQL database. Only required when restoring to a database location different to that used at used at back up time (not applicable for hsql).

JDBC password

-p, --password

JDBC password of the SQL database. Only required when restoring to a database location different to that used at used at back up time (not applicable for hsql).

JDBC class

-d, --driver

Optionally, specify the JDBC driver class name needed to access the SQL database. Only required when restoring to a database location different to that used at used at back up time and when using a different JDBC driver than the standard driver associated with the database specified though --dbtype. (Not applicable for hsql).

JDBC driver source-s, --driver-sourceOptionally, specify the JDBC driver file. The default ('bundled') is to use the bundled JDBC driver file; 'user' = use the driver from the FISHEYE_INST/lib directory.

Suppress output

-q, --quiet

Suppress the output messages from the restore program on the command line.

Overwrite the existing DB --force

Overwrite content of the database without warning.

(info) The --force flag checks your current database versions and will let you overwrite the existing database only if it matches the schema version. If you want to downgrade Fisheye, you must use an empty database.

Don't batch SQL inserts--no-batch-sqlDo not batch SQL inserts. This can be useful when diagnosing errors.
Display the help-h, --helpDisplay the help, and exit.

(info) These examples are for use in a Linux-like operating system. When using these commands on Windows, use the filename fisheyectl.bat and use the correct slashes. Run the command from the <FishEye install directory>/bin/ directory.

The basic syntax of the restore command is as follows:

$ ./ restore -f /path/to/ [OPTIONS]

To see inline help for all backup options, run the following command in the <FishEye install directory>/bin/ directory:

$ ./ restore --help

Restoring a backup with cache data (also restores all default components):

$ ./ restore --cache

Restoring a backup of SQL Server database

Fisheye 4.7.1 (and higher) uses new scheme for SQL Server JDBC URL. In order to restore a backup generated from a version prior to 4.7.1, database connection properties (database type, URL, username and password) have to be set explicitly in a command line. Otherwise, restore command will fail as config.xml in the backup file contains an invalid URL scheme.

Change the scheme in the following manner: 

from jdbc:jtds:sqlserver://

to    jdbc:sqlserver://

To use any custom connection parameters, such as domain-based authentication, you have to change them to the ones supported by Microsoft JDBC (see properties supported by jTDS and by Microsoft JDBC). 

Example for Linux operating system:

$ ./ restore \
--username 'john' \
--password 'smith' \
--jdbcurl 'jdbc:sqlserver://localhost:1433;databaseName=crucible;' \
--dbtype 'sqlserver2012' \
--file '/path/to/' \

Migrating backup data

When the process restores a SQL database, it looks at the configuration data (config.xml) included in the backup archive to learn which database product was used and how to connect to it. When Fisheye uses the built-in HSQLDB database (which is the default), the restored instance will also use that.
However, when the restored instance will use a different database than the backed up instance (for instance, HSQLDB was used at the time the backup was created, but it needs to be restored on MySQL ), you should use the command line options to point the process to the new database which must exist before running the restore. The restore will only populate the database, it will not create the database.

Command line example: migrating backup data to MySQL

(info) This example is for use in a Linux-like operating system. When using these commands on Windows, use the filename fisheyectl.bat and use the correct slashes. Run the command from the <FishEye install directory>/bin/ directory.

(info) We recommend to put values in quotes to avoid evaluation of special characters by the shell (e.g. ';' in JDBC URL may be treated as command separator on Linux).

(info) Use the '--force' option also for an empty database (otherwise restore command won't proceed).

Restoring to a Fisheye instance that uses a different database (ensure the MySQL driver jar file is present in the FISHEYE_INST/lib directory)

$ ./ restore \
--username 'john' \
--password 'smith' \
--jdbcurl 'jdbc:mysql://localhost:3306/crucible' \
--dbtype 'mysql' \
--file '/path/to/' \
Last modified on Dec 5, 2019

Was this helpful?

Provide feedback about this article
Powered by Confluence and Scroll Viewport.