非常好-- Pentaho4.8 BI server搭建


一 下载解压

1> 从pentaho官网http://community.pentaho.com/ 下载biserver-ce-4.8.0-stable.zip

2> 解压,在biserver-ce目录下执行start-pentaho.bat,在administration-console目录下执行start-pac.bat, 分别启动user console与admin console

3> pentaho自带了tomcat,直接访问http://localhost:8080/pentaho 可以打开user console,访问http://localhost:8099 可以打开admin console

4> 在biserver-ce目录下执行stop-pentaho.bat 可以关闭user console,在administration-console目录下执行stop-pac.bat可以关闭admin console


二 采用Mysql数据库

pentaho默认采用的是HSQLDb,这里将替换成mysql。

1> 分别运行biserver-ce\data\mysql5目录下的:

create_repository_mysql.sql

create_quartz_mysql.sql

create_sample_datasource_mysql.sql

2> 导入sampledata

可以从我的资源中下载sql语句:http://download.csdn.net/detail/sundongsdu/5139341


3> 修改配置文件:

a) 修改applicationContext-spring-security-jdbc.xml

    driverClassName改为com.mysql.jdbc.Driver

    url改为jdbc:mysql://localhost:3306/hibernate

b)修改applicationContext-spring-security-hibernate.properties,修改后为:

[html]  view plain copy
  1. jdbc.driver=com.mysql.jdbc.Driver  
  2. jdbc.url=jdbc:mysql://localhost:3306/hibernate  
  3. jdbc.username=hibuser  
  4. jdbc.password=password  
  5. hibernate.dialect=org.hibernate.dialect.MySQLDialect  

c) 修改hibernate/hibernate-settings.xml

config-file改为mysql5.hibernate.cfg.xml

d) 修改webapps/pentaho/META-INF/context.xml,

[html]  view plain copy
  1. <?xml version="1.0" encoding="UTF-8"?>  
  2. <Context path="/pentaho" docbase="webapps/pentaho/">  
  3.     <Resource name="jdbc/Hibernate" auth="Container" type="javax.sql.DataSource"  
  4.         factory="org.apache.commons.dbcp.BasicDataSourceFactory" maxActive="20" maxIdle="5"  
  5.         maxWait="10000" username="hibuser" password="password"  
  6.         driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost/hibernate"  
  7.         validationQuery="select 1" />  
  8.           
  9.     <Resource name="jdbc/Quartz" auth="Container" type="javax.sql.DataSource"  
  10.         factory="org.apache.commons.dbcp.BasicDataSourceFactory" maxActive="20" maxIdle="5"  
  11.         maxWait="10000" username="pentaho_user" password="password"  
  12.         driverClassName="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost/quartz"  
  13.         validationQuery="select 1"/>  
  14. </Context>  

e) 修改mysql hibernate数据库中datasource的值

driverclass改为:com.mysql.jdbc.Driver

URL改为: jdbc:mysql://localhost:3306/sampledata

Query改为:select 1

f) 修改biserver-ce-4.8.0-stable\biserver-ce\pentaho-solutions\system\simple-jndi 下的jdbc.properties 如下:

[html]  view plain copy
  1. SampleData/type=javax.sql.DataSource  
  2. SampleData/driver=com.mysql.jdbc.Driver  
  3. SampleData/url=jdbc:mysql://localhost:3306/sampledata  
  4. SampleData/user=pentaho_user  
  5. SampleData/password=password  
  6. Hibernate/type=javax.sql.DataSource  
  7. Hibernate/driver=com.mysql.jdbc.Driver  
  8. Hibernate/url=jdbc:mysql://localhost:3306/hibernate  
  9. Hibernate/user=hibuser  
  10. Hibernate/password=password  
  11. Quartz/type=javax.sql.DataSource  
  12. Quartz/driver=com.mysql.jdbc.Driver  
  13. Quartz/url=jdbc:mysql://localhost:3306/quartz  
  14. Quartz/user=pentaho_user  
  15. Quartz/password=password  
  16. SampleDataAdmin/type=javax.sql.DataSource  
  17. SampleDataAdmin/driver=com.mysql.jdbc.Driver  
  18. SampleDataAdmin/url=jdbc:mysql://localhost:3306/sampledata  
  19. SampleDataAdmin/user=pentaho_admin  
  20. SampleDataAdmin/password=password  

g) 修改biserver-ce/tomcat/webapps/pentaho/WEB-INF/web.xml

禁掉HSQLDB

Line 87:

[html]  view plain copy
  1. <!-- [BEGIN HSQLDB DATABASES]  
  2.     <context-param>  
  3.         <param-name>hsqldb-databases</param-name>  
  4.         <param-value>sampledata@../../data/hsqldb/sampledata,hibernate@../../data/hsqldb/hibernate,quartz@../../data/hsqldb/quartz</param-value>  
  5.     </context-param>  
  6.     [END HSQLDB DATABASES] -->  

Line 214:

[html]  view plain copy
  1. <!-- [BEGIN HSQLDB STARTER]  
  2.     <listener>  
  3.         <listener-class>org.pentaho.platform.web.http.context.HsqldbStartupListener</listener-class>  
  4.     </listener>  
  5.     [END HSQLDB STARTER] -->  

h) 拷贝biserver-ce\tomcat\webapps\pentaho\META-INF\context.xml中的内容到biserver-ce\tomcat\conf\Catalina\localhost\pentaho.xml

i) 按步骤一启动即可


三. 安装saiku插件

Pentaho社区版已经停止了jpivot的支持,转而使用saiku: http://analytical-labs.com/

下载saiku-plugin-2.4.zip以及saiku-webapp-2.4-war  

将saiku-plugin-2.4.zip解压至/biserver-ce/pentaho-solutions/system/, 将saiku-webapp-2.4-war 拷贝至biserver-ce\tomcat\webapps,

重启bi server

点击"New Saiku Analytics"可以查看Saiku分析结果,点击"New  Analysis"可以查看JPivot分析结果



PS:
问题及解决方案:

Could not load JDBC driver class [com.mysql.jdbc.Driver]

解决方案:

拷贝mysql-connector-java-5.1.20.jar 到tomcat/lib目录


参考文献:

http://sysapp.51cto.com/art/200904/121222.htm

http://interestingittips.wordpress.com/2011/04/27/complete-pentaho-installation-on-ubuntu-part-1/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值