在 Mac Lion 7.3 上配置 Glassfish V3 + Pentaho 3.10
参考了这个帖子,尽管他用的是tomcat,但是还是非常有价值。
下载 Pentaho BI Server 并初始化 PostSQL 数据库:
cd biserver-manual-ce/pentaho-data/postgresql
sudo psql -h localhost -U postgres -d postgres -f create_quartz_postgresql.sql
psql --username=postgres -h localhost -d postgres -f 1....sql
下载 PostgreSQL JDBC Driver:
http://jdbc.postgresql.org
拷贝 postgresql-<version>.jdbc4.jar 到 /usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib
/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib/postgresql-<version>.jdbc4.jar
apache-log4j-1.2.16.tar.gz
/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib
export CLASSPATH=....:/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib/log4j-1.2.16.jar
1.1.1 binaries in zip format.
/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib
export CLASSPATH=....:/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib/jaxen-1.1.1.jar
asadmin start-domain domain1
选择 Resources -> JDBC -> JDBC Connection Pools
Resource Type 选择:javax.sql.ConnectionPoolDataSource
Resource Type 选择:javax.sql.DataSource
Database Driver Vendor 选择:Postgresql
在下一个页面选择 datasource classname "org.postgresql.ds.PGConnectionPoolDataSource"
选择 Resources -> JDBC -> JDBC Resources
在 JNDI Name :输入 "jdbc/Hibernate"
在 JNDI Name :输入 "Hibernate"
在 Pool Name :选择 "Hibernate"
/usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib/applibs/pentaho
cp pentaho-third-party/asm-* /usr/local/Cellar/glassfish/3.1.1/libexec/glassfish/domains/domain1/lib/applibs/pentaho
选择 Configurations -> server-config -> JVM Settings -> Path Settings
"Native Library Path Prefix":${com.sun.aas.instanceRoot}/lib/applibs/pentaho/asm-1.5.3.jar
cp -rf pentaho-solutions /opt/
cd /opt/pentaho-solutions
mvim system/applicationContext-spring-security-hibernate.properties
-------------------------------------------------
jdbc.driver=org.postgresql.Driver
jdbc.url=jdbc:postgresql://localhost:5432/hibernate
hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect
-------------------------------------------------
mvim system/applicationContext-spring-security-jdbc.xml
-------------------------------------------------
class="org.springframework.jdbc.datasource.DriverManagerDataSource">
<property name="driverClassName" value="org.postgresql.Driver" />
value="jdbc:postgresql://localhost:5432/hibernate" />
<property name="username" value="hibuser" />
<property name="password" value="password" />
-------------------------------------------------
mvim system/hibernate/hibernate-settings.xml
-------------------------------------------------
<config-file>system/hibernate/postgresql.hibernate.cfg.xml</config-file>
-------------------------------------------------
mvim system/quartz/quartz.properties
-------------------------------------------------
org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.PostgreSQLDelegate
org.quartz.dataSource.myDS.jndiURL = quartz
-------------------------------------------------
mvim pentaho-webapp/WEB-INF/web.xml:
找到 “solution-path" ,在下一行的<param-value>中填入/opt/pentaho-solutions
Applications -> Deploy -> 选择
biserver-manual-ce -> build ->pentaho-wars -> tomcat ->
Applications -> Deploy -> 选择
biserver-manual-ce -> build -> pentaho-wars ->
http://localhost:8080/pentaho