21
Pentaho Business Intelligence Server 3.5 Oracle 10g & 11g and Windows Installation Tutorial Version 1.1, published 13 January 2010 by Prashant Raju Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by Prashant Raju

Pentaho BI Server 3 5 Oracle WIN v1.1

Embed Size (px)

DESCRIPTION

Pentaho with oracle installation

Citation preview

  • Pentaho Business Intelligence Server 3.5Oracle 10g & 11g and Windows Installation Tutorial

    Version 1.1, published 13 January 2010 by Prashant Raju

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 1. Table of Contents1. Table of Contents .......................................................................................................... 02. Introduction ................................................................................................................... 0

    About ............................................................................................................................... 3Donate ............................................................................................................................. 3The Community ............................................................................................................... 3Thanks............................................................................................................................. 4

    2. Downloads ..................................................................................................................... 5Java JDK ......................................................................................................................... 5SQL Script Packs............................................................................................................. 5Oracle JDBC Thin Client Driver ....................................................................................... 5Pentaho Business Intelligence Server 3.5 Stable............................................................ 6

    3. Setting up the Database ............................................................................................... 7Extract SQL Script Pack .................................................................................................. 7Modify SQL Script Pack................................................................................................... 7

    create_repository_ora.sql ............................................................................................ 7create_quartz_ora.sql .................................................................................................. 7create_sample_datasource_ora.sql ............................................................................. 8load_sample_users_ora.sql ......................................................................................... 8

    Load SQL Scripts ............................................................................................................ 84. Setting up the Business Intelligence Server ............................................................ 10

    Overview........................................................................................................................ 10pentaho-solutions\ ......................................................................................................... 10

    applicationContext-spring-security-jdbc.xml .............................................................. 10applicationContext-spring-security-hibernate.properties............................................ 11hibernate-settings.xml ................................................................................................ 11oracle10g.hibernate.cfg.xml ....................................................................................... 11quartz.properties ........................................................................................................ 12

    tomcat\ ........................................................................................................................... 12web.xml (optional) ...................................................................................................... 12context.xml ................................................................................................................. 12

    5. Setting up the Administration Console..................................................................... 146. Starting the Business Intelligence Server ................................................................ 157. Starting the Administration Console......................................................................... 198. Success! ...................................................................................................................... 21

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 2. Introduction

    About

    This tutorial is an update to the its original "Pentaho Business Intelligence Server 2.0 with MySQL andLinux". Although this tutorial isn't as detailed as it's predecessor it assumes that readers haveintermediate to advanced knowledge in their setup of choice. With what this tutorial lacks in detail itdefinitely makes up to accommodates a lot more of different setups:

    Windows MySQL 5.x PostgreSQL 8.x.x Oracle 10g & 11g

    Linux MySQL 5.x PostgreSQL 8.x.x Oracle 10g & 11g

    This tutorial is for Windows and Oracle 10g & 11g setup.

    Here is a description of the different colour-coded boxes seen throughout the tutorial:

    Blue boxes represent helpGrey boxes represent tips

    Green boxes represent file description

    Donate

    My last tutorial had over 6,000 unique downloads and I believe from most of the feedback and numerouspeople adding me to Gmail that it was extremely helpful! But contrary to belief I do not work for Pentahoand all of this work is voluntary. So even $1 can help me with producing better and bigger tutorials!

    You can donate to my PayPal account by clicking here.

    The Community

    Don't forget about other projects which are part of the Pentaho community:

    PAT (Pentaho Analysis Tool)An alternative to Pentaho's current OLAP analyser tool, JPivot.

    CDF (Community Dashboard Framework)A great framework for building dashboards within Pentaho's Business Intelligence Server User Console.

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • Thanks

    Thanks to the following blogs, people are groups:

    Open Source Business IntelligenceProvided a working copy of the sample database for MySQL.

    BizcubedProvided a working copy of the sample database for PostgreSQL.

    Pentaho Solutions: Business Intelligence and Data Warehousing with Pentaho and MySQLA book by Roland and Jos van Dongen.

    ##pentaho & ##pentaho.patIRC channels found on Freenode (Pentaho and Pentaho PAT).

    Pentaho Wiki & Pentaho ForumsThe first place any new user to Pentaho should look.

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 2. Downloads

    Java JDK

    The first thing is to check if you have a version of Java JDK (1.5 or greater) installed on your computer/server. You can easily check this by opening up a command prompt window and typing in the text foundin bold below:

    C:\Users\Prashant> java -versionjava version "1.6.0_17"Java(TM) SE Runtime Environment (build 1.6.0_17-b04)Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)

    If you get a similar output to mine above you already have a version of the Java JDK installed.

    If you don't get the above output here is an indepth tutorial on how to install and configure the Java JDK onWindows (only worry about steps 1 - 24).

    The next step is to check if you have setup your JAVA_HOME environment variable setup correctly. Youcan also check this by opening up a command prompt window and typing in the text found in bold below:

    C:\Users\Prashant>echo %JAVA_HOME%C:\Program Files\Java\jdk1.6.0_13

    If you get a similar output to mine above you already have setup your JAVA_HOME environment variable,if you don't make sure you completed all steps in the tutorial.

    SQL Script Packs

    Since Pentaho's Business Intelligence Server 2.0 release there has been incomplete/broken SQL scriptsprovided with all releases. I have decided to go through and create these "SQL Script Packs" for eachdatabase seen in this tutorial - these packs contain everything you need to setup your database of choice.

    To download a SQL Script Pack click on the database which you are setting up Pentaho on and keep ithandy as you will need to use this in the next step.

    MySQL 5.x PostgreSQL 8.x.x Oracle 10g & 11g - you will need to download this one

    Oracle JDBC Thin Client Driver

    We will need to download the Oracle JDBC Thin Client JAR file. There are many different types availablefrom the Oracle website depending on your setup (In this guide I was using the ojdbc14.jar whichworked with Oracle XE and 11g).

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • Make sure if you are using Oracle 10.x.x.x that you get the appropiate ojdbc14.jar file from the Oraclewebsite - the ojdbc14.jar that I used will not necessarily work with your Oracle 10.x.x.x version.

    Once you have downloaded the file copy it to the following folders:

    c:\pentaho\biserver-ce\tomcat\common\lib\c:\pentaho\adminstration-console\jdbc\

    Pentaho Business Intelligence Server 3.5 Stable

    The most important file you will need to download is the pentaho-ce-3.5.0.stable.zip file from thePentaho Sourceforge page. After you have downloaded this file extract its contents into a directory youwould like to have Pentaho running from - in this example I have chosen c:\pentaho.

    If you have successfully extracted the ZIP file you should have the following directories:

    c:\pentaho\ adminstration-console\ biserver-ce\

    We will need to make the majority of our changes inside the biserver-ce directory.

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 3. Setting up the Database

    Extract SQL Script Pack

    In the previous step I told you to download the SQL Script Pack for Oracle 10g now you need to extractthis file into a temporary location. Once you have done that you should have 5 SQL scripts:

    1. create_repository_ora.sql2. create_quartz_ora.sql3. create_sample_datasource_ora.sql Currently no working sample data for Oracle4. load_sample_users_ora.sql5. sample_data_ora.sql Currently no working sample data for Oracle

    You must load all these scripts in the order shown above. You must load these SQL scripts at thesqlplus console.

    Modify SQL Script Pack

    Before you can load these SQL scripts you will need to make some small modifications to the files. BelowI have created sections for each SQL script which needs changes and what these changes are. You canedit these file in Notepad or your Oracle frontend tool of choice.

    create_repository_ora.sql

    Once you have opened this file locate this section of code:

    conn hibuser/password@[TNS];

    You will need to add the TNS or host you are trying to connect the hibuser user to, in my example that isORCL_JUPITER.

    conn hibuser/password@ORCL_JUPITER;

    create_quartz_ora.sql

    Once you have opened this file locate this section of code:

    conn quartz/password@[TNS];

    You will need to add the TNS or host you are trying to connect the quartz user to, in my example that isORCL_JUPITER.

    conn quartz/password@ORCL_JUPITER;

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • create_sample_datasource_ora.sql

    Once you have opened this file locate tis section of code:

    conn hibuser/password@[TNS];

    You will need to add the TNS or host you are trying to connect the hibuser user to, in my example that isORCL_JUPITER.

    conn hibuser/password@[ORCL_JUPITER];

    load_sample_users_ora.sql

    Once you have opened this file locate tis section of code:

    conn hibuser/password@[TNS];

    You will need to add the TNS or host you are trying to connect the hibuser user to, in my example that isORCL_JUPITER.

    conn hibuser/password@[ORCL_JUPITER];

    Load SQL Scripts

    Before we start make sure that you place all your SQL scripts in the directory which you will be logginginto sqlplus, in this example that is c:\.

    The next step is to type in the following commands found in bold - one after the other (in the examplebelow the user JUPITER_DBA has DBA access to the TNS ORCL_JUPITER):

    Replace JUPITER_DBA with your user who has DBA access and ORCL_JUPITER with your Oracledatabase TNS or host.

    C:\> sqlplus JUPITER_DBA@ORCL_JUPITER @create_repository_ora.sqlSQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 7 11:04:30 2010Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.Enter password:...outputSQL> exitC:\> sqlplus JUPITER_DBA@ORCL_JUPITER @create_quartz_ora.sqlSQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 7 11:04:30 2010Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.Enter password:...outputSQL> exitC:\> sqlplus JUPITER_DBA@ORCL_JUPITER @load_sample_users_ora.sql;SQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 7 11:04:30 2010Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.Enter password:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • ...outputSQL> exit

    To check if you have succesfully created the hibernate tables login under the hibuser user and thecommands seen in bold below (replace ORCL_JUPITER with your TNS or host):

    C:\> sqlplus hibuser/password@ORCL_JUPITER;SQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 7 11:04:30 2010Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.SQL> select TABLE_NAME from tabs;

    TABLE_NAME------------------------------DATASOURCEGRANTED_AUTHORITIESAUTHORITIESUSERS

    You should see an output similar to above.

    To check if you have succesfully created the quartz tables login under the quartz user and thecommands seen in bold below (replace ORCL_JUPITER with your TNS or host):

    C:\> sqlplus quartz/password@ORCL_JUPITER;SQL*Plus: Release 9.2.0.1.0 - Production on Thu Jan 7 11:04:30 2010Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.SQL> select TABLE_NAME from tabs;

    TABLE_NAME------------------------------QRTZ_JOB_DETAILSQRTZ_JOB_LISTENERSQRTZ_TRIGGERSQRTZ_SIMPLE_TRIGGERSQRTZ_CRON_TRIGGERSQRTZ_BLOB_TRIGGERSQRTZ_TRIGGER_LISTENERSQRTZ_CALENDARSQRTZ_PAUSED_TRIGGER_GRPSQRTZ_FIRED_TRIGGERSQRTZ_SCHEDULER_STATE

    TABLE_NAME------------------------------QRTZ_LOCKS

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 4. Setting up the Business Intelligence Server

    Overview

    The following steps will require you to use a text editor i.e. Notepad, Wordpad etc. The next couple ofsections within this chapter are defined by the parent directory the files that need changing belong to.

    pentaho-solutions\

    You will need to change the configurations of the following files within the pentaho-solutions/directory:

    pentaho-solutions\ system\

    applicationContext-spring-security-jdbc.xml applicationContext-spring-security-hibernate.properties hibernate\

    hibernate-settings.xml oracle10g.hibernate.cfg.xml

    quartz\ quartz.properties

    applicationContext-spring-security-jdbc.xml

    Once you have opened this file locate this section of code:

    Make changes to the highlighted section so that your section of code looks similar to this:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • Here is a brief description of the url value property: jdbc:oracle:thin:[host]:[port]:[sid]

    In this example I have used an IP address of my Oracle 10gdatabase for my host, you would most likely have a host setup inyour tns.ora file already.

    The port which your Oracle 10g database runs on. The SID of your Oracle 10g database, in this example it is ORCL.

    applicationContext-spring-security-hibernate.properties

    Once you opened this file you should see the following code:jdbc.driver=org.hsqldb.jdbcDriverjdbc.url=jdbc:hsqldb:hsql://localhost:9001/hibernatejdbc.username=hibuserjdbc.password=passwordhibernate.dialect=org.hibernate.dialect.HSQLDialect

    Make changes to the highlighted sections so that your code looks similar to this:jdbc.driver=oracle.jdbc.driver.OracleDriverjdbc.url=jdbc:oracle:thin:@161.117.117.182:1521:ORCLjdbc.username=hibuserjdbc.password=passwordhibernate.dialect=org.hibernate.dialect.Oracle10gDialect

    hibernate-settings.xml

    Once you have opened this file locate the following line of code:system/hibernate/hsql.hibernate.cfg.xml

    Make changes to the highlighted sections so that your code looks similar to this:system/hibernate/oracle10g.hibernate.cfg.xml

    oracle10g.hibernate.cfg.xml

    Once you have opened this file locate the following line of code:

    jdbc:oracle:thin:@localhost:1521:pentaho

    Make changes to the highlighted sections so that your code looks similar to this:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • jdbc:oracle:thin:@161.117.117.182:1521:ORCL

    quartz.properties

    Once you have opened this file locate the following line of code:

    org.quartz.jobStore.driverDelegateClass =org.quartz.impl.jdbcjobstore.StdJDBCDelegate

    Make changes the highlighted sections so that your code looks similar to this:

    org.quartz.jobStore.driverDelegateClass =org.quartz.impl.jdbcjobstore.oracle.OracleDelegate

    tomcat\

    You will need to change the configurations of the following files within the tomcat\ directory:

    tomcat\ webapps\

    pentaho\ WEB-INF\

    web.xml (optional) META-INF\

    context.xml

    web.xml (optional)

    You do not need to make any changes to this file if you are happy with visiting the URLhttp://localhost:8080/pentaho to access Pentaho Business Intelligence Server however, if you would likeothers to access the site (remotely or on a network) you will need to make changes to this file.

    Open up the file and locate this line off code:http://localhost:8080/pentaho/

    Make changes to the highlighted section to your desired domain or IP address so it looks similar to this:

    http://www.prashantraju.com:8080/pentaho/orhttp://100.100.10.1:8080/pentaho/

    context.xml

    Once you have opened up the file you should see the following code:

  • factory="org.apache.commons.dbcp.BasicDataSourceFactory"maxActive="20" maxIdle="5"maxWait="10000" username="hibuser" password="password"driverClassName="org.hsqldb.jdbcDriver"url="jdbc:hsqldb:hsql://localhost/hibernate"validationQuery="select count(*) fromINFORMATION_SCHEMA.SYSTEM_SEQUENCES" />

    Make changes to the highlighted sections so that your code looks similar to this:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 5. Setting up the Administration ConsoleNo configuration is needed when setting up the Administration Console with Oracle 10g & 11g.

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 6. Starting the Business Intelligence ServerFor some reason when testing the tutorial with Windows setup I wasn't able to just run the startup.batfile located in the c:/biserver-ce/tomcat/bin directory, however I was able to get Tomcat runningby installing as a Windows service.

    To get started you will need to first register tomcat as a service. To do this type the text found in boldbelow inside c:/biserver-ce/tomcat/bin directory:

    C:\pentaho\biserver-ce\tomcat\bin> service.bat install tomcat5Installing the service 'tomcat5' ...Using CATALINA_HOME: D:\pentaho\biserver-ce\tomcatUsing CATALINA_BASE: D:\pentaho\biserver-ce\tomcatUsing JAVA_HOME: C:\Program Files\Java\jdk1.6.0_13Using JVM: C:\ProgramFiles\Java\jdk1.6.0_13\jre\bin\server\jvm.dll

    The service 'tomcat5' has been installed.Once you have received the above output the next step is to start the Tomcat service. To dot his firstlyclick on the Start button then Run and type in services.msc and click OK. A Services dialog boxshould appear and it will list all available services, locate the Apache Tomcat tomcat5 service anddouble click on it to open up the Properties dialog box:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • To start Tomcat click on the Start button (to stop Tomcat simply click on the Stop button).

    Now you should be able to visit http://localhost:8080/pentaho orhttp://[your_domain_or_ip]:8080/pentaho to see if Pentaho Business Intelligence Server isrunning.

    If it is you should see the following welcome screen:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • After logging in try and run a sample report from the Steel Wheels solution folder:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 7. Starting the Administration ConsoleTo start the Administration Console double click on the the start-pac.bat file which is located underthe c:\pentaho\adminstration-console\ directory. It will pop up a new command prompt windowand should display something similar to the output below:

    DEBUG: Using JAVA_HOMEDEBUG: _PENTAHO_JAVA_HOME=C:\Program Files\Java\jdk1.6.0_13DEBUG: _PENTAHO_JAVA=C:\Program Files\Java\jdk1.6.0_13\bin\java.exe2010-01-05 16:27:17.824::INFO: Logging to STDERR viaorg.mortbay.log.StdErrLog05/01/2010 4:27:18 PM org.pentaho.pac.server.JettyServer startServerINFO: Console is starting2010-01-05 16:27:18.118::INFO: jetty-6.1.22010-01-05 16:27:38.672::INFO: Started SocketConnector @ 0.0.0.0:809905/01/2010 4:27:38 PM org.pentaho.pac.server.JettyServer startServerINFO: Console is now started. It can be accessed usinghttp://D119940:8099 or http://161.117.117.40:8099

    Now you should be able to visit http://localhost:8099/ or the other two address's specified in your output(highlighted). You will be prompted for a Username and Password which are "admin" and "password". Ifyou have successfully started and logged into the administration console you should see the followingwelcome screen:

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

  • 8. Success!You have correctly setup Pentaho Business Intelligence Server 3.5 on Windows with Oracle 10g & 11g.

    Pentaho Business Intelligence Server 3.5 with Oracle 10g & 11g and Win Installation tutorial, Version 2.0, 7 Jan 2010 by PrashantRaju

    1. Table of Contents2. IntroductionAboutDonateThe CommunityThanks

    2. DownloadsJava JDKSQL Script PacksOracle JDBC Thin Client DriverPentaho Business Intelligence Server 3.5 Stable

    3. Setting up the DatabaseExtract SQL Script PackModify SQL Script Packcreate_repository_ora.sqlcreate_quartz_ora.sqlcreate_sample_datasource_ora.sqlload_sample_users_ora.sql

    Load SQL Scripts

    4. Setting up the Business Intelligence ServerOverviewpentaho-solutions\applicationContext-spring-security-jdbc.xmlapplicationContext-spring-security-hibernate.propertieshibernate-settings.xmloracle10g.hibernate.cfg.xmlquartz.properties

    tomcat\web.xml (optional)context.xml

    5. Setting up the Administration Console6. Starting the Business Intelligence Server7. Starting the Administration Console8. Success!