icon-gettingStarted.png
Getting Started
Prerequisites for installing XNAT
Download XNAT
Step by Step Guide to Installing XNAT

Installing DicomServer


Custom Installation Options

Build From Source

Download XNAT in a Virtual Machine

[Edit Nav]

How to Upgrade XNAT


To current users, there are several update methodologies you can pursue. These are for normal upgrades of XNAT (i.e. from 1.4 to 1.4.1 to 1.4.2 etc). Upgrading major versions (1.3 to 1.4) will require some specialized behaviour.

New Release/ New Database
  • This is appropriate if you are still in test mode and do not need to preserve the data you've previously uploaded to your XNAT installation.
New Release/ Old Database
  • Download the full release, and set it up in tandem to your old version, but re-use your prior database. This is particularly helpful if you haven't made any modifications to your projects directory or your modifications to it are limited, but you want to preserve your database (i.e. you've added lots of things you don't want to re-add). This will not work in major upgrades (i.e. 1.3 to 1.4).
Old Release/ Old Database
  • When you cannot use one of the above methods, you can upgrade your existing installation (and database). This is often how we maintain our internal installations (including production ones).


New Release/ New Database

Download the full release, and set it up in tandem to your old version. Follow the steps in the installation guide to complete the installation. If you've made modifications to your projects directory, perform the following steps after Step 5 in the installation guide.
    • Copy your old xnat/projects directory into the new release (xnat/projects).
    • Run the update.sh command (with the same deploy=true option if used on the setup).
update.sh
    • Run bin/generate-create-sql.sh from the xnat directory
bin/generate-create-sql.sh


New Release/ Old Database

Download the full release, and set it up in tandem to your old version, but re-use your prior database. This is particularly helpful if you haven't made any modifications to your projects directory or your modifications to it are limited, but you want to preserve your database (i.e. you've added lots of things you don't want to re-add). This will not work in major upgrades (i.e. 1.3 to 1.4).

Run the following steps,
    • Backup your database (using pgdump)
    • Download the new copy of XNAT into a different location from your previous one.
    • Copy your build.properties file from the previous version (xnat/build.properties) to the new release (xnat/build.properties).
      • This will preserve your previous configurations (i.e. db connection info)
    • Run the setup.sh script to initialize your new release (same as step 5 in the installation guide).
    • Copy your old xnat/projects directory into the new release (xnat/projects). (OPTIONAL: Only required if you've made modifications to the projects directory)
    • Complete steps 7-10 of the Release Upgrade Instructions below (not steps 7-10 of the installation guide).

Another option here: Use pgdump to duplicate your database, and upgrade using that copied database. This will allow you to leave your old site up and running, until you are comfortable that your upgrade was successful. To do this, you should modify the database connection parameters in the build.properties after you copy it to the new installation.


Old Release/ Old Database

When you cannot use one of the above methods, you can upgrade your existing installation (and database). This is often how we maintain our internal installations (including production ones). Follow the ‘Release Upgrade Instructions’ listed below.



Release Upgrade Instructions

These instructions are to be used when using the upgrade package available from the download section of the website. The upgrade package includes modified files which will overwrite the files in the plugin-resources section of your installation.
1. Backup your xnat folder (zip) and your database (pgdump)
2. Download the upgrade package

TAR.GZ xnat_upgrade_1_4_1.tar.gz (8.95MB)
ZIP xnat_upgrade_1_4_1.zip (9.96 MB)
3. Create an 'upgrade' folder within your XNAT_HOME directory
cd $XNAT_HOME mkdir upgrade
4. Extract the upgrade package into your created xnat upgrade folder (i.e. xnat/upgrade)
unzip xnat_upgrade_1_4_1.zip -d ./upgrade
5. Go to the command prompt in the xnat/upgrade/xnat_upgrade_1_4_1 folder.
cd ./upgrade/xnat_upgrade_1_4_1
6. run Upgrade package
./upgrade.sh
7. return to the XNAT_HOME directory
cd ../../
8. run standard XNAT update
bin/update.sh
9. Execute the generated SQL file in your database (deployments/PROJECT/sql/PROJECT-update.sql)
psql -f deployments/xnat/sql/xnat-update.sql xnat
10. Load the generated WAR file (deployments/PROJECT/target/*.war) into your TOMCAT installation. (SKIP this step if you used the -Ddeploy=true option on the update)