Using the Autoupdater in 1.9 is easy. There is a video below demonstrating how to use it.
Notes
- The two most common mistakes are as not making the .sh or .bat files executable and not running from the autoupdater directory.
- If you get stuck with a bad download or the autoupdater is telling you to delete a file it is under updates folder at the root of the dotcms unless it says autoupdater.new or .old in which case it is in the autoupdater directory itself
Running the autoUpdater
The autoUpdater is located in: {dotCMSHome}/bin/autoUpdater
For Windows use autoUpdater.bat
For Linux use autoUpdater.sh
The auptoupdater by default will try to upgrade itself and then it will try to download the latest released upgrade greater than the current install, you can use these options to customize the autoUpdater's behavior.
| Option | Description |
| -allowtestingbuilds <arg> | Includes unreleased builds when looking for latest update |
| -dryrun | Runs without making any changes |
| -file <arg> | Upgrades from a file already on the filesystem under {dotCMSHome}/updates |
| -force | Runs without asking for confirmation |
| -help | Displays the help screen |
| -home <arg> | Sets the location of the dotCMS installation |
| -log <arg> | Name of the log file to be created. Defaults to: update_{timestamp}.log |
| -proxy <arg> | Connects through a proxy server |
| -proxypass <arg> | Password to use for proxy authentication |
| -proxyuser <arg> | Username to use for proxy authentication |
| -quiet | Print only error messages |
| -url <arg> | Url to connect to- Defaults to http://www.dotcms.com:8080/servlets/upgrade/ |
| -verbose | Print for verbose messages |
| -version <arg> | Looks for a specific version to upgrade to |
| -noupdaterupdate | Does not try to update the autoUpdater itself |
Upgrades are downloaded to {dotCMSHome}/updates. If a previous upgrade is found under this directory you must delete it if you want to download a new upgrade, or you can upgrade from this file using the -file {file_name} parameter.
If you experienced any connectivity issues while downloading an upgrade, or if the downloaded upgrade is corrupted, you must delete any upgrades under {dotCMSHome}/updates before you can try and upgrade again.
By default, the autoUpdater will try to download the latest released update greater than the current version. To upgrade to a specific version you must use the -version parameter i.e: -version 1.9.3.1, this will look for the provided version and will try to download the upgrade only if the version exists and it's greater than the current version.
To upgrade to the latest build, regardless of it's release status, you can use the -allowtestingbuilds parameter (i.e -allowtestingbuilds true), this will look for the latest build including unreleased builds.
If you experience any issues trying to run dotCMS again after an upgrade be sure to check if there is more than one version of the dotcms_{version}.jar under {dotCMSHome}/WEB-INF/lib and delete the older one. The autoUpdater will try to delete the file during the upgrade process but if for some reason the delete fails you will need to remove the file manually.