This is the procedure I follow to upgade OpenDJ from 2.5.0-Xpress1 to 2.6.0, complete with the eccentricities of my firm’s standard paths.
If you’re on RHEL 6 and don’t mind running OpenDJ under /opt/opendj (which is where I have all my instances at home), it is highly recommended that you use the rpm package now available in ForgeRock’s Enterprise Downloads area.
Over the years I’ve found that using rpm packages wherever possible increases the liklihood that things will get patched and upgraded as necessary.
Note: I was very happy to see that the project went with installing all the files into /opt rather than the typical LSB (Linux Standard Base) structure because in my opinion that would have unnecessarily complicated things. If you do install to /opt be sure to adjust your backup and recovery plan to accomodate it.
All my enterprise installations of OpenDJ are installed into [volname]/app/opendj, with the root folder of each instance named something like “ds-user1”, “ds-app1”, etc. This is to accomodate the running of multiple instances on a single server, something that is often required in my particular environment.
This procedure is only slightly modified from what you’ll find in the officially released OpenDJ 2.6.0 Installation Guide.
In the procedure that follows the $DSHOME or OpenDJ install root is:
1. Log into the directory host as user owning the OpenDJ instance (in my case this is system user opendj).
2. Stop server.
3. Back up the directory server files.
cd /data/app/opendj tar czf ds-user1.tgz ds-user1
4. Download and unpack the latest version files over the exsiting version.
cd /data/install/opendj unzip OpenDJ-2.6.0.zip cp -R opendj/* /data/app/opendj/ds-user1/
(Oh, for a wgettable url to download the latest stable file from!)
6. Run the upgrade command.
cd $DSHOME ./upgrade
Respond affirmatively to the prompts after reading them and satisfying yourself you understand what they mean.
7. Rebuild the dir-sync-hist index (required due to a legacy bug).
$DSHOME/bin/rebuild-index \ --baseDN dc=example,dc=com \ --index ds-sync-hist
8. Start the server and note any errors.