中国建设劳动学会官方网站,广州外贸型网站设计,为女友做网站,h5网站如何做排名1 简介Pentaho是世界上最流行的开源商务智能软件,以工作流为核心的#xff0c;强调面向解决方案而非工具组件的#xff0c;基于java平台的商业智能(Business Intelligence,BI)套件BI#xff0c;之所以说是套件是因为它包括一个web server平台和几个工具软件#xff1a;报表… 1 简介Pentaho是世界上最流行的开源商务智能软件,以工作流为核心的强调面向解决方案而非工具组件的基于java平台的商业智能(Business Intelligence,BI)套件BI之所以说是套件是因为它包括一个web server平台和几个工具软件报表分析图表数据集成数据挖掘等可以说包括了商务智能的方方面面。它整合了多个开源项目目标是和商业BI相抗衡。它偏向于与业务流程相结合的BI解决方案侧重于大 中型企业应用。它允许商业分析人员或开发人员创建报表仪表盘分析模型商业规则和 BI 流程。注以上感觉高大上但笔者比较鄙视Pentaho这个项目从布署的角度看完全没有支撑该项目的标准文档只有零星的资料要部署好只能靠反复测试和摸索。2 实践部分2.1 环境部分2.1.1 运行环境IP Address 10.168.0.76HostName pentaho.cmdschool.orgOS CentOS 7.32.1.2 安装辅助工具yum install -y unzip2.1.3 配置防火墙firewall-cmd --permanent --add-port 8080/tcp
firewall-cmd --reload
firewall-cmd --list-all2.2 MySQL配置2.2.1 配置MySQL的源vim /etc/yum.repos.d/mysql56-community.repo输入如下内容# Enable to use MySQL 5.6
[mysql56-community]
nameMySQL 5.6 Community Server
baseurlhttp://repo.mysql.com/yum/mysql-5.6-community/el/7/$basearch/
enabled1
gpgcheck1
gpgkeyhttp://repo.mysql.com/RPM-GPG-KEY-mysql2.2.2 安装相关包yum install -y mysql-community-server mysql-community-devel mysql-community-client2.2.3 启动并配置默认开机启动systemctl start mysqld
systemctl enable mysqld2.2.4 初始化数据库mysql_secure_installation向导如下[...]
Set root password? [Y/n] y
New password:
Re-enter new password:
[...]
Remove anonymous users? [Y/n] y
[...]
Disallow root login remotely? [Y/n] n
[...]
Remove test database and access to it? [Y/n] y
[...]
Reload privilege tables now? [Y/n] y
[...]2.3 Java配置2.3.1 创建java目录mkdir /usr/java2.3.2 下载JDKcd /usr/java
wget http://download.oracle.com/otn/java/jdk/8u121-b13/e9e7ea248e2c4826b92b3f075a80e441/jdk-8u121-linux-x64.tar.gz?AuthParam1495873209_eea482e2b59774918c970cf5dc383fdb2.3.3 解压安装包tar -xf jdk-8u121-linux-x64.tar.gz2.3.4 配置环境变量vim /etc/profile末尾加入如下内容export JAVA_HOME/usr/java/jdk1.8.0_121
export JRE_HOME${JAVA_HOME}/jre
export CLASSPATH.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH${JAVA_HOME}/bin:$PATH2.3.5 使环境变量生效source /etc/profile2.3.6 测试环境变量java -version2.4 Pentaho安装包配置2.4.1 下载程序包mkdir /usr/pentaho
cd /usr/pentaho
wget https://nchc.dl.sourceforge.net/project/pentaho/Business%20Intelligence%20Server/7.0/pentaho-server-ce-7.0.0.0-25.zip
wget https://nchc.dl.sourceforge.net/project/pentaho/Data%20Integration/7.0/pdi-ce-7.0.0.0-25.zip
wget https://nchc.dl.sourceforge.net/project/pentaho/Report%20Designer/7.0/prd-ce-7.0.0.0-25.zip注下载链接https://sourceforge.net/projects/pentaho/files/ 2.4.2 解压程序包unzip pentaho-server-ce-7.0.0.0-25.zip
unzip pdi-ce-7.0.0.0-25.zip
unzip prd-ce-7.0.0.0-25.zip2.4.3 更换mysql连接驱动cd ~
wget https://dev.mysql.com/get/Downloads/Connector-J/mysql-connector-java-5.1.41.tar.gz
tar -xf mysql-connector-java-5.1.41.tar.gz
cp mysql-connector-java-5.1.41/mysql-connector-java-5.1.41-bin.jar /usr/pentaho/pentaho-server/tomcat/lib/
mv /usr/pentaho/pentaho-server/tomcat/lib/mysql-connector-java-5.1.17.jar ~/注下载链接https://dev.mysql.com/downloads/connector/j/2.4.4 修改Tomcat运行环境变量vim /usr/pentaho/pentaho-server/tomcat/bin/setenv.sh修改内容如下export JAVA_HOME/usr/java/jdk1.8.0_121
export JRE_HOME${JAVA_HOME}/jre
export CLASSPATH.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH${JAVA_HOME}/bin:$PATH
export PENTAHO_JAVA_HOME${JAVA_HOME}
export INSTALL_HOME/usr/pentaho/pentaho-server
export DI_HOME${INSTALL_HOME}/pentaho-solutions/system/kettle
export CATALINA_OPTS-Xms4096m -Xmx6144m -XX:MaxPermSize256m -Dsun.rmi.dgc.client.gcInterval3600000 -Dsun.rmi.dgc.server.gcInterval3600000 -DDI_HOME$DI_HOME2.4.5 创建程序运行用户useradd -s /sbin/nologin -b /usr/pentaho确认用户家目录ls -ld /usr/pentaho2.4.6 预配置esapi目录mkdir /usr/pentaho/esapi2.4.7 配置目录权限chown -R pentaho:pentaho /usr/pentaho/
chmod -R 770 /usr/pentaho2.5 数据库服务配置2.5.1 修改quartz库的授权vim /usr/pentaho/pentaho-server/data/mysql5/create_quartz_mysql.sql注释掉如下行# grant all on quartz.* to pentaho_userlocalhost identified by password;2.5.2 修改hibernate库的授权vim /usr/pentaho/pentaho-server/data/mysql5/create_repository_mysql.sql注释掉如下行# GRANT ALL ON hibernate.* TO hibuserlocalhost identified by password;2.5.3 修改jackrabbit库的授权vim /usr/pentaho/pentaho-server/data/mysql5/create_jcr_mysql.sql注释掉如下行# grant all on jackrabbit.* to jcr_userlocalhost identified by password;2.5.4 导入数据库mysql -uroot -p /usr/pentaho/pentaho-server/data/mysql5/create_quartz_mysql.sql
mysql -uroot -p /usr/pentaho/pentaho-server/data/mysql5/create_repository_mysql.sql
mysql -uroot -p /usr/pentaho/pentaho-server/data/mysql5/create_jcr_mysql.sql2.5.5 配置数据库权限mysql -uroot -p
grant all on quartz.* to pentaholocalhost identified by passwd;
grant all on hibernate.* to pentaholocalhost identified by passwd;
grant all on jackrabbit.* to pentaholocalhost identified by passwd;
flush privileges;2.5.6 测试数据库mysql -upentaho -ppasswd2.6 迁移数据库等配置2.6.1 配置Quartzcd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/quartz/quartz.properties pentaho-solutions/system/quartz/quartz.properties.default
vim pentaho-solutions/system/quartz/quartz.properties修改并启用如下参数org.quartz.jobStore.driverDelegateClass org.quartz.impl.jdbcjobstore.StdJDBCDelegate
org.quartz.dataSource.myDS.jndiURL Quartz2.6.2 配置hibernate数据源cd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/hibernate/mysql5.hibernate.cfg.xml pentaho-solutions/system/hibernate/mysql5.hibernate.cfg.xml.default
vim pentaho-solutions/system/hibernate/mysql5.hibernate.cfg.xml修改如下标签参数property nameconnection.usernamepentaho/property
property nameconnection.passwordpasswd/property2.6.3 配置Hibernatecd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/hibernate/hibernate-settings.xml pentaho-solutions/system/hibernate/hibernate-settings.xml.default
vim pentaho-solutions/system/hibernate/hibernate-settings.xml修改如下标签参数config-filesystem/hibernate/mysql5.hibernate.cfg.xml/config-file2.6.4 配置审计日志cd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/audit_sql.xml pentaho-solutions/system/audit_sql.xml.default
cp pentaho-solutions/system/dialects/mysql5/audit_sql.xml pentaho-solutions/system/2.6.5 配置repository.xmlcd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/jackrabbit/repository.xml pentaho-solutions/system/jackrabbit/repository.xml.default
vim pentaho-solutions/system/jackrabbit/repository.xml注解以下标签和内容 FileSystem classorg.apache.jackrabbit.core.fs.local.LocalFileSystemparam namepath value${rep.home}/repository//FileSystem去掉以下标签和内容注解并修改账号密码 FileSystem classorg.apache.jackrabbit.core.fs.db.DbFileSystemparam namedriver valuecom.mysql.jdbc.Driver/param nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho/param namepassword valuepasswd/param nameschema valuemysql/param nameschemaObjectPrefix valuefs_repos_//FileSystem注解以下标签和内容 DataStore classorg.apache.jackrabbit.core.data.FileDataStore/去掉以下标签和内容注解并修改账号密码 DataStore classorg.apache.jackrabbit.core.data.db.DbDataStoreparam nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho/param namepassword valuepasswd/param namedatabaseType valuemysql/param namedriver valuecom.mysql.jdbc.Driver/param nameminRecordLength value1024/param namemaxConnections value3/param namecopyWhenReading valuetrue/param nametablePrefix value/param nameschemaObjectPrefix valueds_repos_//DataStore注解以下标签和内容 FileSystem classorg.apache.jackrabbit.core.fs.local.LocalFileSystemparam namepath value${wsp.home}//FileSystem去掉以下标签和内容注解并修改账号密码 FileSystem classorg.apache.jackrabbit.core.fs.db.DbFileSystemparam namedriver valuecom.mysql.jdbc.Driver/param nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho/param namepassword valuepasswd/param nameschema valuemysql/param nameschemaObjectPrefix valuefs_ws_//FileSystem注解以下标签和内容 PersistenceManager classorg.apache.jackrabbit.core.persistence.pool.H2PersistenceManagerparam nameurl valuejdbc:h2:${wsp.home}/db/param nameschemaObjectPrefix value${wsp.name}_//PersistenceManager去掉以下标签和内容注解并修改账号密码 PersistenceManager classorg.apache.jackrabbit.core.persistence.bundle.MySqlPersistenceManagerparam namedriver valuecom.mysql.jdbc.Driver/param nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho /param namepassword valuepasswd /param nameschema valuemysql/param nameschemaObjectPrefix value${wsp.name}_pm_ws_//PersistenceManager注解以下标签和内容 FileSystem classorg.apache.jackrabbit.core.fs.local.LocalFileSystemparam namepath value${rep.home}/version //FileSystem去掉以下标签和内容注解并修改账号密码 FileSystem classorg.apache.jackrabbit.core.fs.db.DbFileSystemparam namedriver valuecom.mysql.jdbc.Driver/param nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho/param namepassword valuepasswd/param nameschema valuemysql/param nameschemaObjectPrefix valuefs_ver_//FileSystem注解以下标签和内容 PersistenceManager classorg.apache.jackrabbit.core.persistence.pool.H2PersistenceManagerparam nameurl valuejdbc:h2:${rep.home}/version/db/param nameschemaObjectPrefix valueversion_//PersistenceManager去掉以下标签和内容注解并修改账号密码 PersistenceManager classorg.apache.jackrabbit.core.persistence.bundle.MySqlPersistenceManagerparam namedriver valuecom.mysql.jdbc.Driver/param nameurl valuejdbc:mysql://localhost:3306/jackrabbit/param nameuser valuepentaho /param namepassword valuepasswd /param nameschema valuemysql/param nameschemaObjectPrefix valuepm_ver_//PersistenceManager2.6.6 配置Tomcat的JDBC连接信息context.xmlcd /usr/pentaho/pentaho-server/
cp tomcat/webapps/pentaho/META-INF/context.xml tomcat/webapps/pentaho/META-INF/context.xml.default
vim tomcat/webapps/pentaho/META-INF/context.xml修以下配置 maxWaitMillis10000 usernamepentaho passwordpasswddriverClassNamecom.mysql.jdbc.Driver urljdbc:mysql://localhost/hibernatevalidationQueryselect 1 /maxWaitMillis10000 usernamepentaho passwordpasswddriverClassNamecom.mysql.jdbc.Driver urljdbc:mysql://localhost/quartzvalidationQueryselect 1/2.6.7 配置web.xmlcd /usr/pentaho/pentaho-server
cp tomcat/webapps/pentaho/WEB-INF/web.xml tomcat/webapps/pentaho/WEB-INF/web.xml.default
vim tomcat/webapps/pentaho/WEB-INF/web.xml删除以下标签和配置 !-- [BEGIN HSQLDB DATABASES] --context-paramparam-namehsqldb-databases/param-nameparam-valuesampledata../../data/hsqldb/sampledata,hibernate../../data/hsqldb/hibernate,quartz../../data/hsqldb/quartz/param-value/context-param!-- [END HSQLDB DATABASES] --删除以下标签和配置 !-- [BEGIN HSQLDB STARTER] --listenerlistener-classorg.pentaho.platform.web.http.context.HsqldbStartupListener/listener-class/listener!-- [END HSQLDB STARTER] --2.6.8 配置applicationContext-spring-security-hibernate.properties(可选)cd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/applicationContext-spring-security-hibernate.properties pentaho-solutions/system/applicationContext-spring-security-hibernate.properties.defautl
vim pentaho-solutions/system/applicationContext-spring-security-hibernate.properties修改如下参数jdbc.drivercom.mysql.jdbc.Driver
jdbc.urljdbc:mysql://localhost:3306/hibernate
jdbc.usernamepentaho
jdbc.passwordpasswd
hibernate.dialectorg.hibernate.dialect.MySQL5InnoDBDialect2.6.9 配置applicationContext-spring-security-jdbc.properties(可选)cd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/applicationContext-spring-security-jdbc.properties pentaho-solutions/system/applicationContext-spring-security-jdbc.properties.default
vim pentaho-solutions/system/applicationContext-spring-security-jdbc.properties修改如下参数datasource.driver.classnamecom.mysql.jdbc.Driver
datasource.urljdbc:mysql://localhost:3306/hibernate
datasource.usernamepentaho
datasource.passwordpasswd
datasource.validation.querySELECT 12.6.10 配置jdbc.properties(可选)cd /usr/pentaho/data-integration
cp simple-jndi/jdbc.properties simple-jndi/jdbc.properties.default
vim simple-jndi/jdbc.properties注释掉原来参数并增加如下参数且修改账号密码SampleData/typejavax.sql.DataSource
SampleData/drivercom.mysql.jdbc.Driver
SampleData/urljdbc:mysql://localhost:3306/hibernate
SampleData/userpentaho
SampleData/passwordpasswd
Hibernate/typejavax.sql.DataSource
Hibernate/drivercom.mysql.jdbc.Driver
Hibernate/urljdbc:mysql://localhost:3306/hibernate
Hibernate/userpentaho
Hibernate/passwordpasswd
Quartz/typejavax.sql.DataSource
Quartz/drivercom.mysql.jdbc.Driver
Quartz/urljdbc:mysql://localhost:3306/quartz
Quartz/userpentaho
Quartz/passwordpasswd
Shark/typejavax.sql.DataSource
Shark/drivercom.mysql.jdbc.Driver
Shark/urljdbc:mysql://localhost:3306/hbibernate
Shark/userpentaho
Shark/passwordpasswd
SampleDataAdmin/typejavax.sql.DataSource
SampleDataAdmin/drivercom.mysql.jdbc.Driver
SampleDataAdmin/urljdbc:mysql://localhost:3306/hibernate
SampleDataAdmin/userpentaho
SampleDataAdmin/passwordpasswd2.6.11 配置pentaho.xml(可选)cd /usr/pentaho/pentaho-server/
cp pentaho-solutions/system/pentaho.xml pentaho-solutions/system/pentaho.xml.defautl
vim pentaho-solutions/system/pentaho.xml修改如下配置login-show-users-listfalse/login-show-users-list
login-show-sample-users-hintfalse/login-show-sample-users-hint注解或删除如下配置 sampledata-datasourcenameSampleData/namehostlocalhost/hosttypeHypersonic/typeport9001/portaccessNATIVE/accessusernamepentaho_user/usernamepasswordpassword/passwordmax-active20/max-activemax-idle5/max-idlemax-wait1000/max-waitqueryselect count(*) from INFORMATION_SCHEMA.SYSTEM_SEQUENCES/query/sampledata-datasource2.7 测试和配置服务启动2.7.1 测试服务启动sudo -u pentaho /usr/pentaho/pentaho-server/tomcat/bin/startup.sh2.7.2 监视日志排错建议监控如下日志tail -f /usr/pentaho/pentaho-server/tomcat/logs/catalina.out建议搜索如下日志grep -i -E error|fail /usr/pentaho/pentaho-server/tomcat/logs/catalina.out | sort -u2.7.3 网页测试http://10.168.0.76:8080/pentaho 参阅资料安装教程https://help.pentaho.com/Documentation/7.0其他参考资料http://www.cnblogs.com/driftingshine/p/6065454.htmlhttp://community.pentaho.com/驱动下载链接http://www.oracle.com/technetwork/apps-tech/jdbc-112010-090769.htmlhttp://www.oracle.com/technetwork/database/features/jdbc/jdbc-ucp-122-3110062.htmlojdbcx.jar, ora18n.jar启动安装教程https://help.pentaho.com/Documentation/7.0/0D0/160/010#OracleLDAP项目https://help.pentaho.com/Documentation/7.0/0P0/Setting_Up_User_Security/Implement_Advanced_Security/010https://help.pentaho.com/Documentation/7.0/0P0/Setting_Up_User_Security/Implement_Advanced_Security/030下载页面https://sourceforge.net/projects/pentaho/files/手动LDAP配置https://help.pentaho.com/Documentation/7.0/0P0/Setting_Up_User_Security/Implement_Advanced_Security/030http://diethardsteiner.github.io/biserver/2014/11/08/LDAP.html切换到LDAPhttps://help.pentaho.com/Documentation/7.0/0P0/Setting_Up_User_Security/Implement_Advanced_Security/010LDAP界面配置https://help.pentaho.com/Documentation/7.0/0P0/Setting_Up_User_Security/Implement_Advanced_Security/010http://wiki.pentaho.com/display/ServerDoc2x/UsingLDAPandJDBCSimultaneouslyJar下载http://mvnrepository.com/安装文档https://help.pentaho.com/Documentation/7.0/0F0/0P0/Starting_the_Pentaho_Server_after_Manual_Installationhttps://help.pentaho.com/Documentation/7.0/0F0/0P0/020/0B0数据库配置https://help.pentaho.com/Documentation/7.0/0F0/0P0/030/020 转载于:https://blog.51cto.com/cmdschool/1933360