Apache Tomcat has the capability of running as a System Wide Instance or a Private Instance on an Ubuntu server. If you are setting up JasperReports Server to run under Tomcat on Ubuntu in one of these System or Private modes, then there are a few differences on how it might be setup.
Setup/Install JRS on System Instance of Tomcat:
1) sudo service tomcat7 stop
2) configure default_master.properties
a) Add: CATALINA_HOME = /usr/share/tomcat7
b) Add: CATALINA_BASE = /var/lib/tomcat7
3) Either create a postgresql user with access via psql or edit
/etc/postgresql/9.1/main/pg_hba.conf
a) Set "trust" for 127.0.0.1
4) Start PostgreSQL
sudo service postgresql restart
5) Execute sudo ./js-install.sh (or sudo ./js-install-ce.sh)
a) make sure Tomcat is stopped
6) Create Tomcat setenv.sh in /usr/share/tomcat/bin directory
a) Add JAVA_OPTS from Install Guide
7) Execute: chmod ugo+rx (add read and execute rights to everyone)
You can also chown it to root:root
8) Copy JS pro license to directory: /usr/share/tomcat7 (for Pro version only)
9) Start Tomcat7:
sudo service tomcat7 start
NOTE: If you run into file permissions problems, stop Tomcat and do: sudo rm -rf /tmp/*
Setup/Install JRS on Private Instance of Tomcat:
1) Execute: sudo -u postgres psql
2) At PostgreSQL prompt execute: alter user postgres with password ‘postgres’;
3) Restart PostgreSQL service
4) Execute: sudo service postgresql restart
5) Test that you can log into PostgreSQL:
sudo -U postgres -h localhost -W
6) If Tomcat is running, stop it
a) Execute: sudo tomcat7-instance-create jspro56
b) Execute: sudo /opt/jspro56/bin/startup.sh
c) Execute: sudo /opt/jspro56/bin/shutdown.sh
7) Upload JS Pro
8) Switch to the directory where JS Pro will be installed, such as /opt and execute:
sudo unzip ./jasperreports-server-trunk-bin.zip
9) Copy ../buildomatic/sample_conf/postgresql_master.properties
../buildomatic/default_master.properties
10) Edit default_master.properties file
a) Set: appServerDir = /opt/jspro56
b) Save changes
11) Execute:
sudo /opt/jasperreports-server-trunk-create-war-bin_794-bin/buildomatic/js-install.sh test
a) Verify that JS Pro configuration and properties file return Build Successful msg
12) Re-execute above cmd, but without the ‘test’ option
13) Copy the <js-install-dir>/jasperserver.license to the appropriate directory
based on the Install Guide (or Pro version only)
14) Copy file /opt/jspro56/bin/setenv.sh to /usr/share/tomcat7/bin/setenv.sh
15) Edit setenv.sh
a) Add JAVA_OPTS lines listed in JS Pro Install Guide in section 6
16) Once build is completed restart Tomcat: sudo /opt/jspro56/bin/startup.sh
Recommended Comments
There are no comments to display.