Skip to main content
Hitachi VantaraPentaho Documentation
Pentaho Documentation

Start and Stop BA Server

File:/grBaservStepStartBAServer.png

To work with the User Console, the BA repository and the BA server have to be running. Yet, there may be times when you need to manage these components individually, stopping them to perform system maintenance and restarting them after you are done. As part of the Installation Wizard and Archive Installation, we provide different ways to help you start and stop the components, depending on the operating system you use. If you installed Pentaho software manually, use the information in this section as a guide to create a custom way to start and stop these components.
For Microsoft Windows, these are your options for starting and stopping the components.

When you are done, please go on to the next stop on the Guide Post graphic.

Windows Pentaho Installation Wizard

When you ran the Installation Wizard on Windows, the BA Server is deployed in an Apache Tomcat application server. You can manage the BA Server by clicking Start > All Programs > Pentaho Enterprise Edition > Manage Servers and then select one of these menu items.
  • Start BA Server
  • Stop BA Server

The wizard also registered the BA Server, as well as the BA repository, as services. These services are set to run automatically, enabling them to start and stop when the computer running them boots or shuts down. You can use the Windows Services applet found in the Control Panel to start and stop the Pentaho servers and the BA repository.

  1. Click Start > Control Panel > Administrative Tools > Services.
  2. In the Services window, right-click on one of these services in the list and take the appropriate action.
    • Pentaho BA Server
    • Pentaho BA Repository

Windows Pentaho Archive Installation

If you used the Archive Installation, we provide individual control scripts to start and stop the BA server and BA repository. Here is where you can find the individual control scripts.

BA Repository

  • The Archive Installation enables you to install either PostgreSQL, MySQL, or Oracle as the repository. Consult the documentation for the RDBMS you selected for information about starting and stopping.

    The BA repository must be started before the BA Server.

BA Server

  • /pentaho/server/biserver-ee/start-pentaho.bat and stop-pentaho.bat

Linux Pentaho Installation Wizard

When you ran the Installation Wizard on Linux, the BA Server is deployed in an included Apache Tomcat application server. You can control the Tomcat server using the start and stop scripts that come with the Pentaho installation. This script is also used as an easy way to start and stop the BA Server and the PostgreSQL repository.

You can find this script at /pentaho/ctlscript.sh.

Here is a list of the script arguments and services you can use.

Arguments
  • start
  • stop
  • restart
  • status
  • help
Services
  • baserver
  • postgressql

./ctlscript.sh start baserver

./ctlscript.sh status postgressql

./ctlscript.sh help

Linux Pentaho Archive Installation

If you used the Archive Installation, Pentaho provides individual control scripts to start and stop the Tomcat application server, BA Server, and BA repository. Here is where you can find the individual control scripts.

BA Repository

  • The Archive Installation enables you to install either PostgreSQL, MySQL, or Oracle as the BA repository. Consult the documentation for the RDBMS you selected for information about starting and stopping.

    The BA repository must be started before the BA Server.

BA Server

  • /pentaho/server/biserver-ee/start-pentaho.sh and stop-pentaho.sh

Linux Pentaho Wizard or Archive Installation—Starting on Boot

The Installation Wizard and the Archive Installation do not provide a way to start the BA repository and BA Server automatically on boot. They also do not stop automatically at shutdown. Here are examples of how you might approach creating a script to start at boot and stop at shutdown.

This procedure assumes that you are running the BA Server under the pentaho local user account. If you are using a different account to start these services, substitute it in the script in step 2. This script also assumes you are using the PostgreSQL repository. Where postgresql appears in this script, change it to reflect the RDBMS you are using as a repository, either MySQL or Oracle. This script was tested on Red Hat Enterprise Linux. You may have to modify the details of the script if you use a different distribution of Linux or other Unix-like operating system, different shells, or different init systems.

  1. With root permissions, create a file in /etc/init.d/ named pentaho.
  2. Using a text editor, copy the following content into the new pentaho script. If running the solution repository on the same machine as the server, change postgresql to the name of the init script for your database. If running the solution repository on the a remote computer, remove postgresql entirely. You may also have to adjust the paths to the BA Server scripts to match your situation.
    #!/bin/sh
    ### BEGIN INIT INFO
    # Provides: start-pentaho stop-pentaho
    # Required-Start: networking postgresql
    # Required-Stop: postgresql
    # Default-Start: 2 3 4 5
    # Default-Stop: 0 1 6
    # Description: Pentaho BA Server
    ### END INIT INFO
    
    case "$1" in
    "start")
    su - pentaho -c "/home/pentaho/pentaho/server/biserver-ee/start-pentaho.sh"
    ;;
    "stop")
    su - pentaho -c "/home/pentaho/pentaho/server/biserver-ee/stop-pentaho.sh"
    ;;
    *)
    echo "Usage: $0 { start | stop }"
    ;;
    esac
    exit 0
  3. Save the file, then open /home/pentaho/pentaho/server/biserver-ee/start-pentaho.sh.
  4. Change the last if statement to match the this example.
    if [ "$?" = 0 ]; then
      cd "$DIR/tomcat/bin"
      export CATALINA_OPTS="-Xms4096m -Xmx6144m -XX:MaxPermSize=256m -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
      env JAVA_HOME=$_PENTAHO_JAVA_HOME sh ./startup.sh
    fi
  5. Save the file and close the text editor.
  6. Make the init script executable.
    chmod +x /etc/init.d/pentaho
  7. Add the Pentaho init script to the standard run levels by using the update-rc.d command, so that it runs when the system starts, and stops when the system is shut down or rebooted. This command may not exist on your computer if it is not Debian-based. If that is the case, consult your distribution documentation or contact your distribution's support department to determine how to add init scripts to the default run levels.
    update-rc.d pentaho defaults