Open Clinica installation (Database creation and final configuration)

 

Previous >>> Installing PostgreSQL DB

Assuming that the Postgre is installed and Database initialized.

[ritesh@chennai ~]$ su postgres
Password:
change user to postgres
[postgres@chennai ritesh]$ cd $PGHOME navigate to home directory of user postgres
[postgres@chennai ~]$  /usr/local/pgsql/bin/psql -f /usr/local/oc/OpenClinica-2.5.6/config/database/PostgreSQL/2.5.6/install/create_db_role.sql
CREATE ROLE
run SQL script file to create role in Database
[postgres@chennai ~]$ /usr/local/pgsql/bin/createdb openclinica
CREATE DATABASE
createdb command is used to create openclinica DB which houses all data of openclinica
[postgres@chennai ~]$ /usr/local/pgsql/bin/psql -d openclinica -f /usr/local/oc/OpenClinica-2.5.6/config/database/PostgreSQL/2.5.6/install/create_database_2.5.6_tables_with_data.sql
ALTER TABLE
CREATE TABLE
...............
......
CREATE TRIGGER
REVOKE
GRANT
GRANT
[postgres@chennai ~]$

Finally the SQL script to populate all tables, data into openclinica DB
[postgres@chennai ~]$ exit
exit
[ritesh@chennai ~]$ su root
Password:
[root@chennai ritesh]# su tomcat
Change to user tomcat
[tomcat@chennai ritesh]$ cp /usr/local/oc/OpenClinica-2.5.6/config/libraries/* /usr/local/tomcat/common/lib Copy libraries required for tomcat
[tomcat@chennai ritesh]$ mkdir /usr/local/tomcat/openclinica.data/ create directory which store CRF's
[tomcat@chennai ritesh]$ cp /usr/local/oc/OpenClinica-2.5.6/distribution/OpenClinica.war /usr/local/tomcat/webapps
 
Deploy the java package (war) to tomcat. The war file when copied to tomcat webapps folder will decompress and create necessary files and folders automatically. Take another coffee break !
Installation is done. Edit the files (datainfo.properties and OpenClinica.xml) to suit your environment,
[root@chennai ritesh]# vi /usr/local/tomcat/webapps/OpenClinica/properties/datainfo.properties  

[root@chennai ritesh]# vi /usr/local/tomcat/conf/Catalina/localhost/OpenClinica.xml


:-)

 

For more tutorials click here
 
© www.riteshmandal.com
Contact : ritesh@riteshmandal.com