How to get InfluxDB version via shell

It's most likely that the InfluxDB client and InfluxDB server on the same server are the same versions. If you want to specifically check the server version, you can do so.

In versions 0.11 (at least) and above, the influxdb executable accepts a version argument:

% /usr/bin/influxd version
InfluxDB v1.2.1 (git: master 3ec60fe2649b51a85cd1db6c8937320a80a64c35)

curl -sL -I localhost:8086/ping

You should get something like:

HTTP/1.1 204 No Content
Content-Type: application/json
Request-Id: c7c8f7d7-b7ef-11e7-8002-000000000000
X-Influxdb-Version: 1.3.6
Date: Mon, 23 Oct 2017 12:43:33 GMT

If you are using HTTPS:

curl -skL -I 'https://myhost:8086/ping'

Tags:

Shell

Influxdb