1:pentaho 是一个商业的强大的BI ,支持各种报表,还有数据统计和集成。它分商业版和社区版,这里是社区版
下载地址:http://sourceforge.net/projects/pentaho/files/Business%20Intelligence%20Server/5.0.1-stable/
这有两个版一个是manual 的,这个是下载下来需要人工去创建目录结构,其实下载第一个版本就可以了。
注意:pentaho 5版的和 其它低版的,还有很大的区别的,其中它需要构建数据库中的表名都不一样,就因为这个问题,我弄了好久,启动方式也不一样。
2:解压缩到你自己的一个目录下,解压后目录结构如下:
其中data 是放支持各种数据库文件的地方;
pentaho-solutions 是它的各种配置文件,其它不用说了。
3:安装mysql 5.x,jdk 6/7 (自己进行安装,这里忽略)
4:创建pentaho 需要的数据库表结构
将data/mysql5下的三个SQL脚本在Mysql 设计器中运行(无序)
注: 以上三个脚本会创建三个数据库hibernate、quartz、jackrabbit 和对应的三个用户hibuser、pentaho_user、jcr_user 密码都为password如果在这里你想将密码改成自己的那么以下配置时将对应密码改成你修改的密码即可6.修改配置文件
将 pentaho-solutions\system\applicationContext-spring-security-hibernate.properties 修改成:
Properties代码jdbc.driver=com.mysql.jdbc.Driver
jdbc.url=jdbc:mysql://localhost:3306/hibernate
jdbc.username=hibuser
jdbc.password=password
hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
将 pentaho-solutions\system\hibernate\hibernate-settings.xml 修改成:
Xml代码
system/hibernate/mysql5.hibernate.cfg.xml
将 pentaho-solutions\system\hibernate\mysql5.hibernate.cfg.xml 修改成(如果用默认用户名和密码些文件不用修改 我这里没有改动):
在 pentaho-solutions\system\quartz\quartz.properties 中找到org.quartz.jobStore.driverDelegateClass将其值修改成:
Properties代码
org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.StdJDBCDelegate
将Mysql的驱动tomcat\webapps\pentaho\WEB-INF\lib 目录中,现在下载的版本已经有了(注manual 版没有);将tomcat\webapps\pentaho\WEB-INF\web.xml 中以下部分删除
org.pentaho.platform.web.http.context.HsqldbStartupListener
hsqldb-databases
sampledata@../../data/hsqldb/sampledata,hibernate@../../data/hsqldb/hibernate,quartz@../../data/hsqldb/quartz
以下是建议做的修改,不做也可以:
将pentaho-solutions\system\jackrabbit\repository 删除 如果之前已经设置过repository.xml 存储到Mysql 那需要将 Mysql数据库jackrabbit中对应的表清空
建议将 pentaho-solutions\system\simple-jndi\jdbc.properties 对应hsqldb 的连接都换成 Mysql的
建议将 pentaho-solutions\system\jackrabbit\repository.xml 对应的 Mysql 配置的注释打开 并关闭对应文件系统配置 例如:
将下面的注释掉
Xml代码
将下的打开
Xml代码
到些pentaho 5 配置到mysql 5已经全部结束了
到/tomcat/bin 目录下启动 tomcat ,观察日志能否启动成功。然后在浏览器中输入:http://localhost:8080/pentaho/Login
登陆成功后:
manage data Sources 选项卡,配置pentaho自带的数据库例子