Set up InfluxDB
Verbiqo reads InfluxDB with InfluxQL, through the server’s query API. It answers inventory and alert-state questions from what the server holds, and investigates everything else with reads it checks before sending.
At a glance
| Supported tasks | Inventory (buckets, measurements, hosts, tags and fields), the alert state written by Icinga 2, hosts that stopped reporting, network ports, and investigations of any reading over a time window: peaks, the latest value, what changed, comparisons. Questions: Ask InfluxDB. Every check: InfluxDB checks. |
|---|---|
| Limitations | Verbiqo reads only what is stored. It does not know what a field measures from its name, so answers state the readings and leave health and cause open unless the data says them. A 2.x bucket needs a database mapping to be read. Limitations. |
| Supported versions | InfluxDB 1.x and 2.x. Tested on 1.8, 2.3 and 2.7. InfluxDB 3 is detected and refused; nothing is read. Flux is not used. |
| Authentication | An API token (2.x), a user and password (1.x), or none when authentication is off. The token or password is kept in the Keychain or Credential Manager. Credentials in the URL are refused. |
| Minimum permissions | Read access to the buckets or databases you will ask about. A token that cannot write is recommended; Verbiqo does not check whether it can. Commands: Create the read-only access. |
| Connection test | Extensions… › InfluxDB › Test Connection, or verbiqo influx test <name>. Success shows Connected, the server version, the number of buckets or databases (naming any 2.x bucket with no database mapping), what the token could not read, and the TLS in use. |
| First useful question | Attach with /influx <name>, ask list measurements in telegraf, then which hosts stopped reporting. Expect names and times read from the server, and the list of every read made. |
| Safety controls |
|
| Operational limits | 30 seconds per request by default, settable from 1 to 86,400. Per question: at most 100 requests, 300,000 rows returned and 120 seconds. Your organization can lower these under influx: Protect your systems. |
Where it runs
| Platform | Set up and ask | Where the token is kept |
|---|---|---|
| macOS | The app (Extensions… › InfluxDB, then /influx in the Ask window) and the command line. | Keychain |
| Windows | The app (Extensions… › InfluxDB from the tray menu, then /influx in the Ask window) and the command line. | Credential Manager |
| Linux | The command line. | The connection file, readable only by you (Linux has no secure store Verbiqo uses) |
1. Create the read-only access
InfluxDB 2.x. A token with read access to the buckets you will ask about. Find the bucket ids, then create the token with one --read-bucket for each bucket:
influx bucket list --org example-org
influx auth create --org example-org --description "verbiqo read-only" \
--read-bucket 0000000000000001 --read-bucket 0000000000000002
The token is shown once. Create it with read permissions only: Verbiqo sends only reads, but does not check whether the token could write.
InfluxDB 1.x. A user with READ on each database:
CREATE USER "verbiqo" WITH PASSWORD 'choose-a-password'
GRANT READ ON "telegraf" TO "verbiqo"
Database mappings, organizations and the token’s own permissions are read only when a question needs them. If the token may not read them, the answer names them under Not read and goes on.
2.x buckets need a database mapping
InfluxQL reads a 2.x bucket only through a database and retention policy mapping (DBRP). Without one the bucket cannot be read, and Verbiqo never reports it as empty. Create the mapping on the server, once for each bucket:
influx v1 dbrp create --org example-org --bucket-id 0000000000000001 --db telegraf --rp autogen --default
Check the access
After step 2, run the connection test. It lists the buckets or databases the credential can see and names every 2.x bucket that has no mapping. Anything the token may not read is listed as Not read with the server’s reason. To ask the same later, in an attached session:
what can this token read
2. Add the connection
Open the form
Extensions… › InfluxDB. A short name (metrics) and the URL, such as
https://influx.example.com:8086. A path prefix behind a proxy is kept.Sign in
API token (2.x), User and password (1.x), or None. For 2.x, the organization is optional.
Default database (optional)
The bucket or database a question is about when it names none. Without it, Verbiqo uses the only one there is, or the one that holds the host you named, or asks you which.
Choose encryption
For
https://, see TLS.Save and test
Save Connection, then Test Connection. Leave the token field blank to keep the stored one.
Client certificates, field mappings and device identities are set from the command line: From a terminal.
TLS
| Your server | Choose |
|---|---|
Plain http:// | Nothing to choose. The token and every answer cross the network unencrypted, and Verbiqo warns about it. |
https:// with a certificate from a public CA | Full (the default): trusted CA and matching host name. |
https:// with a certificate from your own CA | Full, with the CA in CA certificate. If you connect by an address the certificate does not name, Certificate checks the CA only. |
| A lab with a self-signed certificate | Encrypt only: the certificate is not checked. |
| A server that asks for a client certificate | Add it from the command line: --cert and --key (From a terminal). |
On the command line the three modes are verify-full, verify-ca and require.
Settings that help
None is required. Each lets Verbiqo say more, or say it with less doubt.
| Item | Lets Verbiqo see |
|---|---|
| Icinga 2 InfluxdbWriter sends check metadata | The alert state of every host and service: state, since when, soft or hard, acknowledged, in downtime, flapping. Without it the bucket gives readings only, and the answer says so. |
| Interface fields and tags from the SNMP collector | Ports down while enabled, ports shut on purpose, error and discard counters that rose, busiest ports against their line rate, and device restarts. |
| A steady poll interval | Hosts that stopped reporting. A host has stopped when its newest point is older than three poll intervals, and the interval is read from the samples. Where the gaps are irregular it is not established, and the answer says it did not judge. |
warn, crit, min, max and unit fields beside a reading | A reading judged against the levels its source wrote, in the unit it wrote. A reading with none is not judged. |
For Icinga 2, on the InfluxdbWriter object:
object InfluxdbWriter "influxdb" {
host = "influx.example.com"
enable_send_metadata = true
}
For the SNMP collector, a Telegraf inputs.snmp sketch with the objects Verbiqo understands. Verbiqo takes ifName (else ifDescr) as the port name when it is a tag, and shows ifAlias as the port’s description. Change the agent, interval and community to yours:
# telegraf.conf
[[inputs.snmp]]
agents = ["udp://192.0.2.10:161"]
interval = "60s"
[[inputs.snmp.field]]
name = "sysUpTime"
oid = "RFC1213-MIB::sysUpTime.0"
[[inputs.snmp.table]]
name = "interface"
oid = "IF-MIB::ifTable"
[[inputs.snmp.table.field]]
name = "ifName"
oid = "IF-MIB::ifName"
is_tag = true
[[inputs.snmp.table.field]]
name = "ifAlias"
oid = "IF-MIB::ifAlias"
is_tag = true
[[inputs.snmp.table.field]]
name = "ifOperStatus"
oid = "IF-MIB::ifOperStatus"
[[inputs.snmp.table.field]]
name = "ifAdminStatus"
oid = "IF-MIB::ifAdminStatus"
[[inputs.snmp.table.field]]
name = "ifHighSpeed"
oid = "IF-MIB::ifHighSpeed"
[[inputs.snmp.table.field]]
name = "ifInErrors"
oid = "IF-MIB::ifInErrors"
[[inputs.snmp.table.field]]
name = "ifOutErrors"
oid = "IF-MIB::ifOutErrors"
[[inputs.snmp.table.field]]
name = "ifInDiscards"
oid = "IF-MIB::ifInDiscards"
[[inputs.snmp.table.field]]
name = "ifOutDiscards"
oid = "IF-MIB::ifOutDiscards"
[[inputs.snmp.table.field]]
name = "ifHCInOctets"
oid = "IF-MIB::ifHCInOctets"
[[inputs.snmp.table.field]]
name = "ifHCOutOctets"
oid = "IF-MIB::ifHCOutOctets"
- ifOperStatus and ifAdminStatus tell a port that is down while enabled from one shut on purpose.
- ifHighSpeed is the line rate that the busiest ports are measured against. Without it the answer says the line rate was not read.
- The error, discard and octet counters give rates. A counter that falls is a reset, and is counted as one.
- sysUpTime shows a device restart: it falls back.
A meaning is given only to standard IF-MIB and SNMPv2-MIB objects whose values fit the object. Next: Ask InfluxDB.
The data it understands
The data it understandsVerbiqo works out the shape of each bucket from its data, never from host or bucket names. Which tag is the host, the service and the reading’s label is decided from how the series differ; a role it cannot decide is reported as undecided.
| Data | What Verbiqo adds |
|---|---|
| Icinga 2 check results (InfluxdbWriter) | The alert state of every host and service: state, since when, soft or hard, acknowledged, in downtime, flapping. It needs enable_send_metadata = true on the writer; without it, the bucket gives readings only, and the answer says so. |
SNMP collectors (Telegraf inputs.snmp and the like) | Interfaces down while enabled, ports shut down on purpose, error and discard counters that rose with their rate, device restarts, busiest ports against their speed. A meaning is given only to standard IF-MIB and SNMPv2-MIB objects whose values fit the object. |
| Any other measurement | Readings over the window: lowest, highest, mean, latest, when the peak was, changes between samples. Whether a field is a level, a counter or a status is read from its values. Thresholds and units come only from the data itself or from a mapping. |
Field mappings and device identities
A field’s name does not say what it measures or in which unit. A mapping says so explicitly, for one measurement and field, with the MIB object and the source it comes from. Mapped fields are read with their meaning (unit, scale, status names), the stored value first. The built-in registry today covers Dell iDRAC (IDRAC-MIB). Without a mapping, hardware readings are observations only.
A device identity says that labels written by different collectors are the same device. Nothing is joined by name, address or letter case unless an identity says so.
verbiqo influx mappings metrics
verbiqo influx mappings metrics --file mappings.json
The file is a JSON list of mappings, or an object that also holds deviceIdentities. Use documentation names and addresses like these:
{
"hardwareMappings": [
{
"registry": "dell-idrac",
"revision": "201501190000Z",
"source": "operator-supplied telegraf inputs.snmp",
"measurement": "temps",
"name": "st",
"oid": "1.3.6.1.4.1.674.10892.5.4.700.20.1.5",
"kind": "field"
}
],
"deviceIdentities": [
{
"id": "device-one",
"source": "operator-declared",
"labels": [
{
"connection": "metrics",
"bucket": "telegraf",
"tag": "agent_host",
"value": "device-one"
},
{
"connection": "metrics",
"bucket": "telegraf",
"tag": "agent_host",
"value": "192.0.2.10"
}
]
}
]
}
registry and revision must be a registry Verbiqo holds; source is required and is shown in the details; kind is field (default) or tag. A mapping that fails is listed with its reason and never blocks a valid one.
The first prints what is set; the second replaces it from a file. A file with any error is refused whole and nothing is saved. Mappings never change the collector or the server.
From a terminal
printf '%s' "$INFLUX_TOKEN" | verbiqo influx add metrics \
--url https://influx.example.com:8086 --auth token --secret-stdin
verbiqo influx test metrics
verbiqo influx list
For 1.x with a user:
printf '%s' "$INFLUX_PASSWORD" | verbiqo influx add metrics \
--url http://influx.example.com:8086 --auth basic --user verbiqo --secret-stdin
With no --auth, a user means basic, a secret alone means token, and neither means none.
| Flag | Means |
|---|---|
--url | The server, such as https://influx.example.com:8086. A bare host:port is read as http://. |
--auth token|basic|none | API token (2.x), user and password (1.x), or none. |
--user | The 1.x user. |
--secret-stdin, --secret-env VAR | Read the token or password from standard input or a variable, never from the command line. |
--org | The 2.x organization (optional). |
--database | The default bucket or database. |
--tls-mode require|verify-ca|verify-full | For https://: encrypt only, trusted CA, or trusted CA and host name (default). |
--ca; --cert and --key | A private CA; a client certificate and its key, together. |
--request-timeout-seconds N|default | How long one request may take, 1 to 86,400 seconds; default is 30. |
To delete a connection and its stored secret:
verbiqo influx remove metrics
Questions from a terminal: Ask InfluxDB.
Common errors
| Message or symptom | Likely cause | What to do | Needs an administrator? |
|---|---|---|---|
| …with no database mapping and not readable by InfluxQL | A 2.x bucket has no DBRP mapping. | Create the mapping (2.x buckets need a database mapping). | Yes, on the InfluxDB server |
Expected a supported Verbiqo command for verbiqo influx, or no InfluxDB in the app | An administrator turned the extension off. | Remove the setting (Turn InfluxDB off). | Yes |
| …is detected but not supported yet | The server is InfluxDB 3. | Nothing was read. Use a 1.x or 2.x server. | No |
| The server refused the credentials (401) | A wrong or expired token or password. | Enter it again and press Save Connection. | Sometimes |
| The server refused the token on N of M requests… | One node behind a load balancer rejects a token the others accept. Each refusal was retried up to twice. | Answers are complete if the retries succeeded. Ask the server’s owner to check the nodes. | Yes |
| The credential is not allowed to do this (403) | The token cannot read that bucket or listing. | Give it read access to the bucket (step 1). | Yes |
| No answer from … within N s | A slow server or a large read. | Raise Request timeout, or ask about a shorter window or fewer hosts. | No, unless your organization’s limit caps it |
| State metadata is absent: performance observations only | The Icinga writer does not send check state. | Set enable_send_metadata = true on the InfluxdbWriter (Settings that help). | Yes, on Icinga |