Like what you see? Have a play with our trial version.

This guide will allow users to automate Yellowfin deployment on a Linux operating system using a bash script.

Deployment Bash Script

Following is an example of a headless bash script that can be used as is, or modified to very quickly get Yellowfin and its dependencies installed on any Linux operating system (such as Ubuntu).


This bash script will require the following:

  • To provide a database user and password of your choosing to be used when installing into PostgresSQL.
  • To point it at a Yellowfin .jar installer, which can be found on our website and also a Yellowfin license file.

Overview of Script Steps

The script will then perform these steps:

  1. Install default Java.
  2. Install PostgresSQL.
  3. Create a Postgres user for Yellowfin to use.
  4. Generate a Silent Installer file for Yellowfin.
  5. Install Yellowfin.
  6. Start Yellowfin.
  7. Clean up after itself.

The Bash Script

To use the script below, it’s important you have a thorough understanding of Linux.

echo "Start script"
#Setting DB user var
_dbuser=`echo $1 | base64 --decode`
echo "db User is"
echo $_dbuser
#Setting DB user var
_dbpass=`echo $2 | base64 --decode`
echo "db pass is"
echo $_dbpass
#Update installer package
echo "Update apt-get"
sudo apt-get update
#Install JRE and Postgres
echo "Install Default-jre"
sudo apt-get install --yes --force-yes default-jre
echo "Install Postgres"
sudo apt-get install --yes --force-yes postgresql postgresql-contrib
#Create Postgres User for YF
echo "Create Postgres DB User"
sudo -u postgres createuser $_dbuser --createdb --superuser
echo "Set Postgres DB User Pass"
sudo -u postgres psql -c "ALTER USER $_dbuser WITH PASSWORD '$_dbpass'"
#Get Yellowfin Installer
#Change the "WGET" to the location of your Yellowfin installer file
#echo "Get Yellowfin Installer"
#wget http://insterller-file-here/installer.jar -O /tmp/yellowfin.jar
#Get Yellowfin Licence
#echo "Get Yellowfin Licence"
#wget http://licence-location-here/licence.lic -O /tmp/yellowfin72.lic
#Generate Silence Installer Properties
echo "Generate Silence Installer Properties"
echo "InstallPath=/opt/yellowfin" >> /tmp/
echo "InstallTutorialDatabase=true" >> /tmp/
echo "LicenceFilePath=/tmp/licence.lic" >> /tmp/
echo "ServicePort=80" >> /tmp/
echo "DatabaseType=PostgreSQL" >> /tmp/
echo "CreateYellowfinDB=true" >> /tmp/
echo "CreateYellowfinDBUser=false" >> /tmp/
echo "DatabaseHostname=localhost" >> /tmp/
echo "DatabaseName=yellowfindb" >> /tmp/
echo "DatabaseDBAUser=$_dbuser" >> /tmp/
echo "DatabaseDBAPassword=$_dbpass" >> /tmp/
echo "DatabaseUser=$_dbuser" >> /tmp/
echo "DatabasePassword=$_dbpass" >> /tmp/
#Install Yellowfin
echo "Install Yellowfin"
sudo java -jar /tmp/yellowfin.jar -silent /tmp/
#Set Boot Params
echo "Set Boot Params"
sudo sed -i '$ihostname Yellowfin72' /etc/rc.local
sudo sed -i '$i/opt/yellowfin/appserver/bin/ > /tmp/yellowfinstart.log 2>&1' /etc/rc.local
#Start Yellowfin
echo "Start Yellowfin"
sudo nohup /opt/yellowfin/appserver/bin/
#Clean Up
echo "Clean up"
rm -rf /tmp/installer.jar
rm -rf /tmp/licence.lic
echo "END"
exit 0

 Deployment Instructions

  1. To get started, log into your Linux terminal. 
  2. Upload the Yellowfin .jar installer to the machine and rename it. It should be located here: /tmp/yellowfin.jar. This can be done using SCP or any other method of transfer you like.

    If uploading from a Windows machine, we recommend using an easy to use tool like WinSCP.

    If the installer was downloaded from Yellowfin's website, you will need to rename it to "yellowfin.jar"

  3. Upload your Yellowfin license to the machine and rename the license file to "licence.lic". It should be located here: /tmp/licence.lic. This can be done with SCP or any other method of transfer you like.
  4. Copy the provided script to your instance and save it as a .sh file, using your preferred text editor.

    Make any modifications to the script that you like, for example make sure you point it towards your license file and the Yellowfin installer file, if you have not placed them in the same location. You can also change where Yellowfin will install to inside the “#Generate Silent Installer” section of the script.

    Note there are optional parts in the script, in which the script would go and wget a license and installer file from the location you choose. Uncomment this section if you wish to use it. IMPORTANT – you will need to direct the script to the correct location for these files by changing the value of the wget.

  5. Make your new .sh file executable in Linux. (chmod +x
  6. Execute the script. (./

    You may need to run the script as root, depending on your permission level. If you install it at root, you will likely need to start Yellowfin as root too.

  7. By default, this script is configured to install Yellowfin to “/opt/yellowfin”. To start Yellowfin, navigate to “/opt/yellowfin/appserver/bin” and run “./”.

    If you ran the installer script as root, you may need to run ./ as root.

  8. You should now have a working Yellowfin install available on port 80.

    If you want Yellowfin to run on a different port, you can change this in the “#Generate Silent Installer” section of the script.

  • No labels