Skip to content

Instantly share code, notes, and snippets.

@xemoe
Last active November 14, 2017 17:45
Show Gist options
  • Save xemoe/a2f504dfd33909c4ec72 to your computer and use it in GitHub Desktop.
Save xemoe/a2f504dfd33909c4ec72 to your computer and use it in GitHub Desktop.
Setup Collectd + InfluxDB + Grafana

OS: Ubuntu 14.04 amd64

InfluxDB

  1. download deb file http://s3.amazonaws.com/influxdb/influxdb_latest_amd64.deb

  2. install via dpkg -i influxdb_latest_amd64.deb

  3. configure /opt/influxdb/shared/config.toml add input_plugins.collectd below the input_plugins section

    [input_plugins]
        [input_plugins.collectd]
            enabled = true
            port = 8096
            database = "collectd"
            typesdb = "/usr/share/collectd/types.db"
    
  4. create influxdb database via web http://localhost:8083 user: root pass: root

Collectd

  1. install via apt sudo apt-get install -y collectd collectd-utils

  2. configure hostname, LoadPlugin and network plugin

    Hostname "xemoe.com"
    LoadPlugin network
    <Plugin network>
        Server "127.0.0.1" "8096" 
    </Plugin>
    
  3. restart collectd service

Grafana

  1. download deb file http://grafanarel.s3.amazonaws.com/builds/grafana_latest_amd64.deb

  2. install via dpkg -i grafana_latest_amd64.deb

  3. go to http://localhost:3000 user: admin pass: admin

  4. create datasource

    name: collectd
    default: true
    type: influxdb 0.8
    url: http://localhost:8086
    access: proxy
    database: collectd
    user: root
    pass: root
    
  5. create dashboard

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment