You are on page 1of 6

SpagoBI Installation

Angelo Bernabei 2013/11/14 12:05

spagobi_server - SpagoBI Installation

Table of Contents
Install JDK .............................................................................................................................................................................. Install Tomcat ......................................................................................................................................................................... Install SpagoBI Metadata DB ................................................................................................................................................ Deploy SpagoBI WebApplication on Tomcat ....................................................................................................................... Configure SpagoBI ................................................................................................................................................................. Edit server.xml ..................................................................................................................................................................... Set Up Data Source ............................................................................................................................................................. Set up Environment variables .............................................................................................................................................. Context /SpagoBI ................................................................................................................................................................. Context /SpagoBI*Engine .................................................................................................................................................... Thread Manager ................................................................................................................................................................... Additional libraries ................................................................................................................................................................. Run & Test ............................................................................................................................................................................. 3 3 3 4 4 4 4 4 5 5 6 6 6

Page 2 - last modified by Angelo Bernabei on 2013/11/14 12:05

spagobi_server - SpagoBI Installation

This section describes the installation procedure for the latest release of SpagoBI. For older versions, please .

check here

Beside the quick start procedure that installs all SpagoBI engines with minimal configuration effort (All-In-One), advanced users can choose to manually select which engines to download and install. This section describes how to perform a customized installation of SpagoBI. Install JDK Install Tomcat Install SpagoBI Metadata DB Deploy SpagoBI WebApplication on Tomcat Configure SpagoBI Edit server.xml Set Up Data Source Set up Environment variables Environment variable: resource-path Environment variable: spagobi-sso-class Environment variables: spagobi-service-url Environment variables: spagobi-host-url Context /SpagoBI Context /SpagoBI*Engine Thread Manager Additional libraries Run & Test

Install JDK
If you haven't a JVM (1.5 or 1.6) already installed on your machine, you have to download and install it.

Install Tomcat
Download Tomcat 6.0.18 from http://tomcat.apache.org/download-60.cgi and unzip apache-tomcat-6.0.18.zip. To check if the installation was successful: double-click on apache-tomcat-6.0.18/bin/startup.bat open your browser and type http://localhost:8080 you should be able to see the "Tom cat"

Install SpagoBI Metadata DB


SpagoBI relies on a schema to store metadata about configuration, document template, etc. You need to create this schema using a SQL script according to your DBMS Type (e.g., Oracle, MySQL, etc.). You can easily create the schema by running the scripts shipped with SpagoBI (in the Scripts db package) of the chosen SpagoBI Server release. The Scripts db package may contain, apart from .sql scritps, a README.txt file and patches to be applied to SpagoBI Server: follow the instructions of README.txt after having deployed SpagoBI war files as explained below. For example, in MySql you have to open "MySql Query Browser" and execute these files: MySQL-create.sql MySQL-create-quartz-schema.sql In order to recreate the Foodmart DB open MySql Administrator and execute an import of foodmart DB. Remember to change the MySQL File dimension ( my.ini)

Page 3 - last modified by Angelo Bernabei on 2013/11/14 12:05

spagobi_server - SpagoBI Installation

Deploy SpagoBI WebApplication on Tomcat


Copy all WAR in WEBAPP Folder of Tomcat, run Tomcat with startup.bat (Windows) or startup.sh (Linux). This operation extracts all WAR files and allows you to edit the configuration files. Don't worry if Tomcat writes some type of error in console or log files

Configure SpagoBI
Now you have to edit some configuration file.

Edit server.xml
This is Tomcat main configuration file. Here you need to set up: DataSource Environment variables From SpagoBI version *2.3* context information is defined within the *META-INF/context.xml* files, which are already included in all packages. If you don't use the 6.0.18 version of Tomcat you have to check at [ http://www.apache.org ] how these configurations are made.

Set Up Data Source


To add a new Data Source you need to add the following XML excerpt under tag: <GlobalNamingResources> Here is the excerpt to add: <Resource auth= "Container" driverClassName= "com.mysql.jdbc.Driver" maxActive= "20" maxIdle= "10" maxWait= "-1" name= "jdbc/spagobi" password= "root" type= "javax.sql.DataSource" url= "jdbc:mysql://localhost/spagobi" username= "root" /> <Resource auth= "Container" driverClassName= "com.mysql.jdbc.Driver" maxActive= "20" maxIdle= "10" maxWait= "-1" name= "jdbc/foodmart" password= "root" type= "javax.sql.DataSource" url= "jdbc:mysql://localhost/foodmart" username= "root" /> The first represents the Connection pool for SpagoBI metadata and the second the Connection pool for Foodmart ( DWH used for demos ) Note that the JDBC driver must be available under the /lib folder. Remember to insert in each Context the resource-link: <ResourceLink global= "<JNDI_NAME>" name= "<JNDI_NAME>" type= "java.lang.String" />

Set up Environment variables


To add a new Variable you need to add the following XML excerpt under tag: <GlobalNamingResources> Here is the excerpt: <Environment name= "<VARIABLE-NAME>" type= "java.lang.String" value= "<VARIABLE-VALUE>" /> Remember to insert in each Context the resource-link: <ResourceLink global= "<VARIABLE-NAME>" name= "<VARIABLE-NAME>" type= "java.lang.String" /> Environment variable: resource-path <Environment name= "spagobi-resource-path" type= "java.lang.String" value= "C:\spagobi2.0\resources" /> This path is used to store resources that SpagoBI Server will look for at the specified directory. These resources are: QBE datamarts Talend jobs

Page 4 - last modified by Angelo Bernabei on 2013/11/14 12:05

spagobi_server - SpagoBI Installation

Images that are used within reports HTML files .xls. or .csv files used in self-service datasets Until SpagoBI 3.x the same path should also include: Mondrian XML schemas Starting SpagoBI 4, Mondrian schemas are made available to SpagoBI Server under a dedicated catalog. Dont' forget to create this PATH ! Environment variable: spagobi-sso-class <Environment name= "spagobi-sso-class" type= "java.lang.String" value= "it.eng.spagobi.services.common.FakeSsoService" /> These classes implements the interaction between SpagoBI and the SSO system. it.eng.spagobi.services.common.FakeSsoService(NO SSO) it.eng.spagobi.services.cas.CasSsoService ( CAS 2.0 ) it.eng.spagobi.services.cas.CasSsoServiceNoProxy( CAS 2.0 , without WebService Security ) it.eng.spagobi.services.cas.CasSsoService3 ( CAS 3.0 ) it.eng.spagobi.services.cas.CasSsoService3NoProxy ( CAS 3.0, without WebService Security )

Environment variables: spagobi-service-url <Environment name= "spagobi-service-url" type= "java.lang.String" value= "http://localhost:8080/SpagoBI" /> This URL is only for back-end service You have to change this value if SpagoBI core and some Engines are not installed in the same server Environment variables: spagobi-host-url <Environment name= "spagobi-host-url" type= "java.lang.String" value= "http://localhost:8080" /> This URL is used to produce some address in html. This is useful if there is a proxy server between the SpagoBI Server and the Browser

Context /SpagoBI
These context information are embedded in META-INF/context.xml, but you can insert this xml in server.xml if you prefere. <Context docBase= "SpagoBI" path= "/SpagoBI" privileged= "true" reloadable= "true" > <ResourceLink global= "jdbc/spagobi" name= "jdbc/spagobi" type= "javax.sql.DataSource" /> <ResourceLink global= "jdbc/foodmart" name= "jdbc/foodmart" type= "javax.sql.DataSource" /> <ResourceLink global= "spagobi-resource-path" name= "spagobi-resource-path" type= "java.lang.String" /> <ResourceLink global= "spagobi-sso-class" name= "spagobi-sso-class" type= "java.lang.String" /> <ResourceLink global= "spagobi-host-url" name= "spagobi-host-url" type= "java.lang.String" /> </Context> You have to define /SpagoBI Context, this configuration depends on the Tomcat version ( check on [ http:// www.apache.org ] )

Context /SpagoBI*Engine
These context information are true for all ENGINE and are embedded in META-INF/context.xml, but you can insert this xml in server.xml if you prefere. <Context docBase= "SpagoBIJasperReportEngine" path= "/SpagoBIJasperReportEngine" privileged= "true" reloadable= "false" > <ResourceLink global= "jdbc/foodmart" name= "jdbc/foodmart" type= "javax.sql.DataSource" /> <ResourceLink global= "jdbc/spagobi" name= "jdbc/spagobi" type= "javax.sql.DataSource" /> <ResourceLink global= "spagobi-resource-path" name= "spagobi&#95;resource-path" type= "java.lang.String" /> <ResourceLink global= "spagobi-sso-class" name= "spagobi-sso-class" type= "java.lang.String" /> <ResourceLink global= "spagobi-service-url" name= "spagobi-service-url" type= "java.lang.String" /> </Context>

Page 5 - last modified by Angelo Bernabei on 2013/11/14 12:05

spagobi_server - SpagoBI Installation

Thread Manager
SpagoBI uses a Thread manager in off-line activities to: Execute Talend JOB Execute Process ( CommonJ Engine ) It's possible to configure the number of thread, in server.xml you have to put: <Resource auth= "Container" factory= "de.myfoo.commonj.work.FooWorkManagerFactory" maxThreads= "5" name= "wm/SpagoWorkManager" type= "commonj.work.WorkManager" /> *Important*: you have to put this resource link in /SpagoBITalendEngine and /SpagoBICommonJEngine Context: <ResourceLink global= "wm/SpagoWorkManager" name= "wm/SpagoWorkManager" type= "jcommonj.work.WorkManager" />

Additional libraries
Each SpagoBI WebApplication contains all libraries required to properly run it. As for resources defined in server.xml you need to include these libraries in /LIB folder. commonj-twm.jar concurrent.jar mysql-connector-java-5.0.8-bin.jar foo-commonj.jar some required libraries for JDBC Drivers.

You can find these libraries in source distribution or in the All-In-One package.

Run & Test


Open your browser and type [ http://localhost:8080/SpagoBI ] The following users are available by default (usr/pwd): biadmin/biadmin bitest/bitest bimodel/bimodel bidev/bidev biuser/biuser

Choose a user and log in: now you are ready to start!

Page 6 - last modified by Angelo Bernabei on 2013/11/14 12:05

You might also like