Change the default port on Pentaho BI Server

Introduction

There are many reasons for changing the Pentaho BI Server’s default port, but one of the most common is a conflict with another server. I ran into this issue where both the Pentaho User Console and the Hadoop MapReduce ShuffleHandler were trying to use port 8080. I wrote an earlier article on how to change the default port for Hadoop MapReduce ShuffleHandler.

So this got me thinking about how to change the Pentaho BI Server port, which is the focus of this article. Plus, it’s always good to know which ports each server requires so that you can manage your firewall, security, and so on.

Step-by-Step

Open a terminal and enter the commands below.

Update server.xml

cd /opt/pentaho/biserver-ce/tomcat/conf

We’ll make a copy of server.xml before we edit it.

I like to keep an original copy of each configuration file that I edit. My standard is to append ‘.org’ to the end of the file.

sudo cp server.xml server.xml.org

I’m going to change from port 8080 to port 8585. Also, I’m going to use sed so that I can change multiple settings with a single command.

sudo sed -i 's/port="8080/port="8585/g' server.xml

Next, we’ll have to update one of the comments that references port 8080. I like to keep my comments in sync with the configuration.

sudo sed -i 's/port 8080/port 8585/g' server.xml

Let’s check what we changed via sed. This command is a good use of the server.xml.org file that we created above.

diff server.xml server.xml.org

You should see output similar to:

< Define a non-SSL HTTP/1.1 Connector on port 8585
---
> Define a non-SSL HTTP/1.1 Connector on port 8080
69c69
< <Connector URIEncoding="UTF-8" port="8585" protocol="HTTP/1.1"
---
> <Connector URIEncoding="UTF-8" port="8080" protocol="HTTP/1.1"
75c75
< port="8585" protocol="HTTP/1.1"
---
> port="8080" protocol="HTTP/1.1"

Update web.xml

cd /opt/pentaho/biserver-ce/tomcat/webapps/pentaho/WEB-INF
sudo cp web.xml web.xml.org
sudo vi web.xml

Update the fully-qualified-server-url‘s param-value to:

http://localhost:8585/pentaho/

The complete node should look like:


  fully-qualified-server-url
  http://localhost:8585/pentaho/

Restart the Pentaho BI Server

cd /opt/pentaho/biserver-ce
sudo -u pentaho ./stop-pentaho.sh
sudo -u pentaho ./start-pentaho.sh

Login to the Pentaho User Console

  1. Open a web browser to http://localhost:8585.
  2. Click Evaluation Login and select a user type to login as.
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s