You are here

Step 5. Installing and setting up the Business Analytics (BA) server

Use this information to install and perform the initial setup for the Business Analytics server.
  1. Change the default user and password to secure your communication link between the Analytics and SkyVault servers.

    By default, the Analytics server uses the user admin and password admin to communicate with SkyVault. It is strongly recommended that you do not use these defaults.

    1. Create a new user and password; for example, ba-system with a long and complex password.
    2. Add the ba-system user to the ANALYTICS_SYSTEM and ANALYTICS_ADMINISTRATORS groups.
    3. In the ba-server/pentaho-solutions/system/alfresco.properties file:

      1. Update the pentahoAdminUsername and pentahoAdminPassword properties to reflect the ba-system user and password values.
      2. Specify your Share and repository locations to the Analytics server (share.baseUrl and repository.baseUrl):
        share.baseUrl=http://alfresco.mycompany.com:8080/share
        repository.baseUrl=http://alfresco.internal.mycompany.com:8080/SkyVault
        where SkyVault.mycompany.com is the external URL that a user types to access SkyVault Share, and SkyVault.internal.mycompany.com is the URL that the Analytics server uses to access the SkyVault repository directly.
        Note: Make sure that you review the possible differences between the values for share.baseUrl and repository.baseUrl.
  2. Stop the SkyVault server and specify the URL of the Analytics server:
    1. Update <classpathRoot>/alfresco-global.properties with the following properties:

      pentaho.ba-server.url=http://pentaho.internal.mycompany.com:8080/pentaho/
      pentaho.ba-server.public.url=http://pentaho.mycompany.com:8080/pentaho/
      where pentaho.internal.mycompany.com represents the IP address or host name of the Analytics server and pentaho.mycompany.com represents the public IP address or host name that is used to access the Analytics server. You do not need to configure pentaho.ba-server.public.url if it has the same value as pentaho.ba-server.url.
    2. Restart the SkyVault server to apply these settings.
  3. If you are using PostgreSQL, navigate to the ba-server/data/postgresql Analytics installation directory. For MySQL, navigate to the ba-server/data/mysql5 Analytics installation directory:
    1. Open the create_jcr_<dbtype>.sql, create_quartz_<dbtype>.sql and create_repository_<dbtype>.sql files (where dbtype is either mysql5 or postgresql) and edit the user and password entries. Make sure that you use credentials that are relevant to you, and do not use the default settings, particularly in a production environment.
    2. Open the ba-server/tomcat/conf/context.xml file.

      Edit the username and password attributes in the jdbc/Hibernate, jdbc/Audit and jdbc/Quartz Resource elements to match the changes that you made in the create_quartz_<dbtype>.sql and create_repository_<dbtype>.sql files.

      Note: You do not need to edit the jdbc/alfrescoDataSource resource at this time.
    3. Edit the ba-server/pentaho-solutions/system/jackrabbit/repository.xml in all relevant sections to set your jcr_user and password entries to match the changes that you made in the create_jcr_<dbtype>.sql files.

      Note: If you changes your port configuration or any other settings when you created the database, edit these parameters accordingly.
    4. If you are not using PostgreSQL, you must specify PersistenceManager and FileSystem properties in the ba-server/pentaho-solutions/system/jackrabbit/repository.xml file:

      1. Uncomment the PersistenceManager section of ba-server/pentaho-solutions/system/jackrabbit/repository.xml, relevant to your database, and comment out the PostgreSQL PersistenceManager section. For example, for MySQL:
        <PersistenceManager class="org.apache.jackrabbit.core.persistence.bundle.MySqlPersistenceManager">
           <param name="url" value="jdbc:mysql://localhost:3306/jackrabbit"/>
           <param name="driver" value="com.mysql.jdbc.Driver"/>
           <param name="user" value="jcr_user" />
           <param name="password" value="password" />
           <param name="schema" value="mysql"/>
           <param name="schemaObjectPrefix" value="${wsp.name}_pm_ws_"/>
        </PersistenceManager>
      2. Uncomment the FileSystem section ba-server/pentaho-solutions/system/jackrabbit/repository.xml, relevant to your database, and comment out the PostgreSQL FileSystem section. For example, for MySQL:
        <FileSystem class="org.apache.jackrabbit.core.fs.db.DbFileSystem">
              <param name="driver" value="com.mysql.jdbc.Driver"/>
              <param name="url" value="jdbc:mysql://localhost:3306/jackrabbit"/>
              <param name="user" value="jcr_user"/>
              <param name="password" value="password"/>
              <param name="schema" value="mysql"/>
              <param name="schemaObjectPrefix" value="fs_ver_"/>
            </FileSystem>
      Note: If a repository.xml file also exists in ba-server/pentaho-solutions/system/jackrabbit/repository/workspaces/default, this will also need to be edited inthe PersistenceManager and FileSystem sections.
      For more information about configuring other databases with the BA server, see BA Server Installation - Configure Repository.
    5. Open the ba-server/pentaho-solutions/system/hibernate/<dbtype>.hibernate.cfg.xml file, where <dbtype> is the database that you are using; for example, mysql5 or postgresql.

      Edit the username and password attributes to match the changes that you made in the create_repository_<dbtype>.sql file.

      Note: If your databases are on a remote server, ensure that you configure the appropriate access before running the scripts in the next step.
    6. In the ba-server/pentaho-solutions/system/audit_sql.xml file, edit the <insertSQL> section as follows:

      For PostgreSQL:

      INSERT INTO PRO_AUDIT 
           (AUDIT_ID, JOB_ID, INST_ID, OBJ_ID, OBJ_TYPE, ACTOR,MESSAGE_TYPE, MESSAGE_NAME, MESSAGE_TEXT_VALUE, MESSAGE_NUM_VALUE, DURATION,AUDIT_TIME) values (NEXTVAL('hibernate_sequence'),?,?,?,?,?,?,?,?,?,?,?)

      For MySQL:

      INSERT INTO PRO_AUDIT 
           (JOB_ID, INST_ID, OBJ_ID, OBJ_TYPE, ACTOR, MESSAGE_TYPE, MESSAGE_NAME, MESSAGE_TEXT_VALUE, MESSAGE_NUM_VALUE, DURATION, AUDIT_TIME) values (?,?,?,?,?,?,?,?,?,?,?)
    7. For PostgreSQL, create the three PostgreSQL databases required by the BA server:

      psql -U postgres < ba-server/data/postgresql/create_jcr_postgresql.sql
      psql -U postgres < ba-server/data/postgresql/create_quartz_postgresql.sql
      psql -U postgres < ba-server/data/postgresql/create_repository_postgresql.sql
    8. For MySQL, create the three MySQL databases required by the BA server:

      mysql -u root -p < ba-server/data/mysql5/create_jcr_mysql.sql
      mysql -u root -p < ba-server/data/mysql5/create_quartz_mysql.sql
      mysql -u root -p < ba-server/data/mysql5/create_repository_mysql.sql
  4. If you are using MySQL, add the MySQL driver jar file that you using (mysql-connector-java-x.x.x-bin.jar) to the ba-server/tomcat/lib directory.
  5. Start the BA server.

    You need to do this to generate a web.xml file.

  6. Navigate to the ba-server/tomcat/webapps/pentaho/WEB-INF directory and open the web.xml file.

    Edit the following section:

    <!--  FullyQualifiedServerUrl is used only in the case of offline content generation and whenever something need to talk back to the server -->
    <context-param>
        <param-name>fully-qualified-server-url</param-name>
        <param-value>http://localhost:8080/pentaho/</param-value>
    </context-param>
    where http://localhost:8080/pentaho/ is the public IP address or host name of the Analytics server (//pentaho.mycompany.com/pentaho/) that you configured in step 2. See Change the BA server fully qualified URL for more information.
    Note: If you redeploy the BA server, these changes are lost and you must edit the file again.

    If you are using SSL, use https in place of http.