In this guide, I’ll show you how to Install Metabase with Systemd on Ubuntu 18.04 / Ubuntu 16.04. Metabase is a simple and powerful analytics tool which lets you learn and make decisions from your company’s data without any technical knowledge required.

To run the Metabase jar file you need to have Java installed on your system. Currently, Metabase requires Java 8 or higher and will work on either the OpenJDK or Oracle JDK.

Step 1: Install  Java 8 on Ubuntu 18.04 / Ubuntu 16.04

Install Java 8 on Ubuntu by running the command below

sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java8-installer oracle-java8-set-default

When prompted to accept the license agreement, answer “yes”

Verify that Java is installed and working.

$ java -version
java version "1.8.0_181"
Java(TM) SE Runtime Environment (build 1.8.0_181-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)

Step 2: Install and configure the Database server ( MariaDB)

You can skip this step if you have a data store for Metabase already configured.

I had written a guide on how to install the MariaDB database server on Ubuntu

Install MariaDB 10.x on Ubuntu 18.04 and CentOS 7

Follow the steps in the link to get a running database server in minutes. When done, create a database for your Metabase like below

Login to MySQL shell as root user

$ mysql -u root -p

Create a database and user with access privileges

GRANT ALL PRIVILEGES ON metabase.* TO 'metabase'@'localhost' IDENTIFIED BY "StrongPassword";

If the database server is remote, assign privilege to a user at specific IP address, e.g


Or allow access from any IP – Not recommended for a server with public access.


Step 3: Install Metabase

Download Metabase and save it on the path where you want the application to run from.

export VER=0.31.2
sudo mkdir -p /apps/java
sudo mv metabase.jar /apps/java

The most basic way of running Metabase to use the javacommand to launch the application.

java -jar metabase.jar

This will start the Metabase application using all of the default settings.

Step 4: Configure Metabase Systemd service

The best way to run Metabase is using Systemd init system available on both Ubuntu 18.04 and Ubuntu 16.04 LTS. A separate guide on running Java applications with systemd is available on our blog.

How to run Java Jar Application with Systemd on Linux

For the sake of simplicity, I’ll do a specific systemd service file for metabase

Start by creating a system group for the user.

sudo groupadd -r appmgr

Next, we create a system user appmgr with the default group

sudo useradd -r -s /bin/false -g appmgr appmgr

Give this user ownership permission to the applications directory

sudo chown -R appmgr:appmgr /apps/java

Create a systemd service unit file

sudo vim /etc/systemd/system/metabase.service

Add the contents below to the file.

Description=Metabase applicaion service

ExecStart=/usr/bin/java -Xms128m -Xmx256m -jar metabase.jar


Set your values for maximum and minimum memory allowed for the Java application ( -Xms128m and -Xmx256m ) in my case

The next thing to do is start the application service, but first, reload systemd so that it loads the new application added.

sudo systemctl daemon-reload

Once reloaded, start the service and set it to start on boot

sudo systemctl start metabase.service
sudo systemctl enable metabase.service

To check the status, use:

sudo systemctl status metabase

Step 4: Access Metabase Web User Interface

After the service is started, Metabase server will listen on port 3000 by default.

$ ss -tunelp | grep 3000
tcp LISTEN 0 50 *:3000 *:* users:(("java",pid=14386,fd=18)) uid:998 ino:85041 sk:a v6only:0 <->

Access the web page to finish setup using http://<serverip>:3000

Click “Let’s get started” button to start the setup. On the next page, create a user to manage Metabase

Provide info about your MySQL database – username and password. If you don’t have that right now, Metabase also comes with a sample dataset you can get started with.

You need to feed your data to the database configured above. Metabase will check for data there. Once you finish the setup, you’ll get access to Metabase Administration panel

See the Metabase getting Started page to start adding Dataset and playing with your data. Also, visit Official metabase documentation for detailed setup and administration.

Also check:

How to Install Latest phpMyAdmin on Ubuntu 18.04 / Debian 9

How to Install ArangoDB on Ubuntu 18.04 Bionic Beaver

Install Dgraph on CentOS 7 / Ubuntu 18.04