Before upgrading, follow this process to back up the database and files needed by OpenClinica:
- Stop Tomcat by running the following command:
/etc/init.d/tomcat stop - Confirm Tomcat has stopped before continuing.
- Create the backup directory by running the following command:
mkdir -p /usr/local/oc/backup/manual/`date +%b-%d-%Y` - Make the backup directory become the current directory by running the following command:
cd /usr/local/oc/backup/manual/`date +%b-%d-%Y` - Run:
/opt/PostgreSQL/8.4/bin/pg_dump -F c -U postgres openclinica > openclinica.backup - When prompted for a password, enter the PostgreSQL database superuser password you specified when setting up the database as part of installing OpenClinica.
- Copy the files OpenClinica needs by running the following command:
cp -rf /usr/local/tomcat/openclinica* .
cp -rf /usr/local/tomcat/webapps/OpenClinica* .