Install Grafana and InfluxDB on Ubuntu Server 17.04

This quickstart assumes you know how to install Ubuntu and access it through a terminal (command line).

EDIT: There seems to be a bug with the latest stable version of Grafana (2.6) and running on a headless system such as the one I’m describing here (Ubuntu Server). This bug causes icons not to be displayed in the web interface. I would suggest either using Ubuntu Desktop (I have not tested this myself) or using Grafana 3 which does not have this bug (I tested this and it does work on Ubuntu Server 16.04. I’ve updated the Grafana installation instructions to include version 3 as well).

After a clean installation, setup openssh server or complete the following from console;

and

grafana_influxdb_ubuntu_configure

Install InfluxDB

The instructions below are based on the official documentation which can be found here: https://docs.influxdata.com/influxdb/v0.12/introduction/installation/

First, configure the package sources.

Make sure you’ve previously used sudo in the current session, so that the sudo in the command below does not prompt you for a password again. To make sure, you can just run “sudo ls” and check that it doesn’t prompt for a password.

If you copy and paste this, make sure it is three separate lines.

grafana_influxdb_ubuntu_influxdb1

This will create a file called “/etc/apt/sources.list.d/influxdb.list” if it worked.

Then install InfluxDB:

grafana_influxdb_ubuntu_influxdb2

Start InfluxDB. This command produces no output.

Install Grafana

The instructions below are based on the official documentation, available here: http://docs.grafana.org/installation/debian/

Configure package sources. You can either install the latest stable version (2.6 currently), or the Beta/Testing version (3.0 beta currently).

Due to a bug with 2.6 and Ubuntu 16.04 Server, I recommend using the beta version if you’re using Ubuntu Server in a headless configuration (No X).

For the current Stable version (2.6), use:

grafana_influxdb_ubuntu_grafana1

Update package repositories and install Grafana:

grafana_influxdb_ubuntu_grafana2

Start the grafana server:

Configure Grafana

These instructions are for Grafana 2.6, but if you installed the beta version it is very similar.

Then use a webbrowser to connect to grafana, using the hostname or IP of your Ubuntu server and port 3000. Log in with admin/admin:

http://statsdemo:3000/

grafana_influxdb_ubuntu_grafana3