Grafana dashboard: LDAP Monitor
Description: Monitor your 389 Directory Server

You want to monitor the 389 Directory Server.
Please download and compile the ds389 input plugin, now in beta version at [Github](https://github.com/influxdata/telegraf/pull/6117).

- Create your telegraf config file, with many LDAP instances as your need.
- Test the plugin to ensure you are collecting the data as explained in the plugin README
- Then install this dashboard and enjoy!

PS: the alert section still has to improve

The plugin is still waiting to be added to Telegraf. Meanwhile you can add it as external [here](https://github.com/falon/CSI-telegraf-plugins)

{
  "__inputs": [
    {
      "name": "DS_TELEGRAF_POSTA",
      "label": "Telegraf_Posta",
      "description": "",
      "type": "datasource",
      "pluginId": "influxdb",
      "pluginName": "InfluxDB"
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "7.5.5"
    },
    {
      "type": "panel",
      "id": "graph",
      "name": "Graph",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "influxdb",
      "name": "InfluxDB",
      "version": "1.0.0"
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "type": "dashboard"
      }
    ]
  },
  "editable": true,
  "gnetId": 10587,
  "graphTooltip": 0,
  "id": null,
  "iteration": 1620038595703,
  "links": [],
  "panels": [
    {
      "alert": {
        "conditions": [
          {
            "evaluator": {
              "params": [
                10
              ],
              "type": "gt"
            },
            "operator": {
              "type": "and"
            },
            "query": {
              "params": [
                "A",
                "24h",
                "now"
              ]
            },
            "reducer": {
              "params": [],
              "type": "percent_diff"
            },
            "type": "query"
          }
        ],
        "executionErrorState": "alerting",
        "for": "0m",
        "frequency": "24h",
        "handler": 1,
        "message": "People in your organization increase over 10%.\nPay attention how your Organizations grow up!",
        "name": "LDAP Organization alert",
        "noDataState": "no_data",
        "notifications": []
      },
      "aliasColors": {},
      "bars": false,
      "dashLength": 10,
      "dashes": false,
      "datasource": null,
      "description": "Count people by your organization domains.",
      "fieldConfig": {
        "defaults": {
          "links": []
        },
        "overrides": []
      },
      "fill": 1,
      "fillGradient": 0,
      "gridPos": {
        "h": 18,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "hiddenSeries": false,
      "id": 2,
      "legend": {
        "alignAsTable": true,
        "avg": false,
        "current": false,
        "max": false,
        "min": false,
        "rightSide": true,
        "show": true,
        "total": false,
        "values": false
      },
      "lines": true,
      "linewidth": 1,
      "links": [],
      "nullPointMode": "connected",
      "options": {
        "alertThreshold": true
      },
      "percentage": false,
      "pluginVersion": "7.5.5",
      "pointradius": 2,
      "points": false,
      "renderer": "flot",
      "seriesOverrides": [],
      "spaceLength": 10,
      "stack": false,
      "steppedLine": false,
      "targets": [
        {
          "alias": "",
          "groupBy": [
            {
              "params": [
                "24h"
              ],
              "type": "time"
            },
            {
              "params": [
                "linear"
              ],
              "type": "fill"
            }
          ],
          "measurement": "ldap_org",
          "orderByTime": "ASC",
          "policy": "default",
          "query": "SELECT max(/^$dom$/) AS \"#\" FROM \"ldap_org\" WHERE  base = '$base' AND instance = '$instance' AND  $timeFilter GROUP BY time(24h) fill(linear)",
          "rawQuery": true,
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "/^$dom$/"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "max"
              },
              {
                "params": [
                  "#"
                ],
                "type": "alias"
              }
            ]
          ],
          "tags": [
            {
              "key": "base",
              "operator": "=",
              "value": "ou=people,o=servizirete,c=it"
            },
            {
              "condition": "AND",
              "key": "b",
              "operator": "=",
              "value": "select tag value"
            }
          ]
        }
      ],
      "thresholds": [
        {
          "colorMode": "critical",
          "fill": true,
          "line": true,
          "op": "gt",
          "value": 10,
          "visible": false
        }
      ],
      "timeFrom": null,
      "timeRegions": [],
      "timeShift": null,
      "title": "LDAP Organization",
      "tooltip": {
        "shared": true,
        "sort": 2,
        "value_type": "individual"
      },
      "type": "graph",
      "xaxis": {
        "buckets": null,
        "mode": "time",
        "name": null,
        "show": true,
        "values": []
      },
      "yaxes": [
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        },
        {
          "format": "short",
          "label": null,
          "logBase": 1,
          "max": null,
          "min": null,
          "show": true
        }
      ],
      "yaxis": {
        "align": false,
        "alignLevel": null
      }
    }
  ],
  "schemaVersion": 27,
  "style": "dark",
  "tags": [
    "ldap_org"
  ],
  "templating": {
    "list": [
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_TELEGRAF_POSTA}",
        "definition": "SHOW TAG VALUES FROM \"ldap_org\" WITH KEY = \"instance\"",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": false,
        "label": "Instance",
        "multi": false,
        "name": "instance",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"ldap_org\" WITH KEY = \"instance\"",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_TELEGRAF_POSTA}",
        "definition": "SHOW TAG VALUES FROM \"ldap_org\" WITH KEY = \"base\" WHERE instance =  '$instance'",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": false,
        "label": "Search Base DN",
        "multi": false,
        "name": "base",
        "options": [],
        "query": "SHOW TAG VALUES FROM \"ldap_org\" WITH KEY = \"base\" WHERE instance =  '$instance'",
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "allValue": null,
        "current": {},
        "datasource": "${DS_TELEGRAF_POSTA}",
        "definition": "SHOW FIELD KEYS FROM \"ldap_org\"",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": true,
        "label": "Domains",
        "multi": false,
        "name": "dom",
        "options": [],
        "query": "SHOW FIELD KEYS FROM \"ldap_org\"",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "tagValuesQuery": "",
        "tags": [],
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      }
    ]
  },
  "time": {
    "from": "now-2d",
    "to": "now"
  },
  "timepicker": {
    "refresh_intervals": [
      "5s",
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ],
    "time_options": [
      "5m",
      "15m",
      "1h",
      "6h",
      "12h",
      "24h",
      "2d",
      "7d",
      "30d"
    ]
  },
  "timezone": "",
  "title": "LDAP Monitor",
  "uid": "-QUSMaIZk",
  "version": 37,
  "description": "Monitor your 389 Directory Server"
}