|
4 | 4 |
|
5 | 5 | InfluxDB is the time series database platform designed to collect, store, and process large amounts of event and time series data. Ideal for monitoring (sensors, servers, applications, networks), financial analytics, and behavioral tracking.
|
6 | 6 |
|
7 |
| -**This README covers all currently supported versions of InfluxDB:** |
| 7 | +## Quick Start |
8 | 8 |
|
9 |
| -- InfluxDB 3: `%%IMAGE%%:3-core`, `%%IMAGE%%:3-enterprise` |
10 |
| -- InfluxDB v2: `%%IMAGE%%:2` |
11 |
| -- InfluxDB v1: `%%IMAGE%%:1.11` |
12 |
| -- InfluxDB Enterprise v1: `%%IMAGE%%:1.11-data` and `%%IMAGE%%:1.11-meta` |
| 9 | +Use InfluxDB 3 Core, the latest InfluxDB OSS: |
13 | 10 |
|
14 |
| -Find a specific InfluxDB version below for startup examples and links to full documentation. |
| 11 | +```console |
| 12 | +docker run -d -p 8181:8181 %%IMAGE%%:3-core |
| 13 | +``` |
15 | 14 |
|
16 |
| -## How to use InfluxDB 3 images |
| 15 | +Available OSS tags: |
17 | 16 |
|
18 |
| -InfluxDB 3 is the latest version and features Apache Arrow, DataFusion SQL, and object storage for sub-10ms queries and unlimited cardinality. The InfluxDB 3 Core and InfluxDB 3 Enterprise editions both support SQL and InfluxQL queries, include the Python processing engine, and work with the InfluxDB 3 Explorer UI. |
| 17 | +- `%%IMAGE%%:3-core` - **Latest InfluxDB OSS** (InfluxDB 3 Core) |
| 18 | +- `%%IMAGE%%:2` - Previous generation OSS (InfluxDB v2) |
| 19 | +- `%%IMAGE%%:1.11` - InfluxDB v1 |
19 | 20 |
|
20 |
| -- **Core** (free, open source): For real-time monitoring and recent data. Covered in this guide. |
21 |
| -- **Enterprise** (requires a license): Adds historical data, clustering, HA, and security. See the InfluxData documentation to [Get started with InfluxDB 3 Enterprise](https://docs.influxdata.com/influxdb3/enterprise/get-started/). |
| 21 | +## Available Versions |
22 | 22 |
|
23 |
| -### Start InfluxDB 3 |
| 23 | +#### InfluxDB 3 Core (`%%IMAGE%%:3-core`) - Latest OSS |
24 | 24 |
|
25 |
| -%%COMPOSE%% |
| 25 | +- **Latest generation** with the InfluxDB 3 storage engine, Apache Arrow, and DataFusion SQL |
| 26 | +- Sub-10ms queries and unlimited cardinality |
| 27 | +- Supports SQL and InfluxQL queries |
| 28 | +- Includes Python processing engine |
| 29 | +- Designed for real-time monitoring and recent data |
| 30 | +- Includes v1 compatibility API for writing and querying data |
| 31 | +- Includes v2 compatibility API for writing data |
26 | 32 |
|
27 |
| -The example `compose.yaml` defines a service for InfluxDB 3 Core and configures file system volumes for data persistence and plugin storage. |
| 33 | +#### InfluxDB v2 (`%%IMAGE%%:2`) |
28 | 34 |
|
29 |
| -#### InfluxDB 3 server options |
| 35 | +- Built on the TSM storage engine |
| 36 | +- Supports Flux query language |
| 37 | +- Integrated UI and dashboards |
| 38 | +- Includes v1 compatibility API that supports InfluxQL |
30 | 39 |
|
31 |
| -You can customize the example, such as changing the node ID or object store type (for example, `s3`). See the full list of server options: |
| 40 | +#### InfluxDB v1 (`%%IMAGE%%:1.11`) |
32 | 41 |
|
33 |
| -```bash |
34 |
| -# InfluxDB 3 Core help |
35 |
| -docker run --pull --rm %%IMAGE%%:3-core influxdb3 serve --help |
36 |
| -``` |
| 42 | +- Built on the TSM storage engine |
| 43 | +- Original version with InfluxQL query language |
| 44 | +- Proven stability for existing deployments |
37 | 45 |
|
38 |
| -[InfluxDB 3 Core `serve` command](https://docs.influxdata.com/influxdb3/core/reference/clis/influxdb3/serve/) |
| 46 | +### Enterprise Editions (License Required) |
39 | 47 |
|
40 |
| -### Get started using InfluxDB 3 |
| 48 | +#### InfluxDB 3 Enterprise (`%%IMAGE%%:3-enterprise`) |
41 | 49 |
|
42 |
| -After starting your InfluxDB 3 server, follow the guide to create an auth token and database, and write, query, and process data in InfluxDB 3: |
| 50 | +- Adds unlimited data retention, compaction, clustering, and high availability to InfluxDB 3 Core |
43 | 51 |
|
44 |
| -- [Get started with InfluxDB 3 Core](https://docs.influxdata.com/influxdb3/core/get-started/) |
45 |
| -- Use the [InfluxDB 3 Explorer UI](https://docs.influxdata.com/influxdb3/explorer/) to write data, create dashboards, explore metrics, and manage your databases. |
| 52 | +For setup instructions, see the [InfluxDB 3 Enterprise installation documentation](https://docs.influxdata.com/influxdb3/enterprise/install/). |
46 | 53 |
|
47 |
| -## How to use the InfluxDB v2 image |
| 54 | +#### InfluxDB v1 Enterprise |
48 | 55 |
|
49 |
| -*InfluxDB v2 is an earlier version of InfluxDB OSS. InfluxDB 3 Core is the latest stable version.* |
| 56 | +- `%%IMAGE%%:1.11-data` - Data nodes for clustering |
| 57 | +- `%%IMAGE%%:1.11-meta` - Meta nodes for cluster coordination (port 8091) |
50 | 58 |
|
51 |
| -Run [InfluxDB v2](https://docs.influxdata.com/influxdb/v2/) using the Docker CLI with the following command: |
52 |
| - |
53 |
| -```bash |
54 |
| -docker run -d -p 8086:8086 \ |
55 |
| - -v $PWD/data:/var/lib/influxdb2 \ |
56 |
| - -v $PWD/config:/etc/influxdb2 \ |
57 |
| - -e DOCKER_INFLUXDB_INIT_MODE=setup \ |
58 |
| - -e DOCKER_INFLUXDB_INIT_USERNAME=my-user \ |
59 |
| - -e DOCKER_INFLUXDB_INIT_PASSWORD=my-password \ |
60 |
| - -e DOCKER_INFLUXDB_INIT_ORG=my-org \ |
61 |
| - -e DOCKER_INFLUXDB_INIT_BUCKET=my-bucket \ |
62 |
| - %%IMAGE%%:2 |
63 |
| -``` |
| 59 | +For setup instructions, see the [InfluxDB v1 Enterprise Docker documentation](https://docs.influxdata.com/enterprise_influxdb/v1/introduction/installation/docker/). |
64 | 60 |
|
65 |
| -After the container starts, visit [http://localhost:8086](http://localhost:8086) in your browser to view the UI. |
| 61 | +## Version Compatibility |
66 | 62 |
|
67 |
| -For detailed instructions, see the [InfluxDB v2 Docker Compose documentation](https://docs.influxdata.com/influxdb/v2/install/use-docker-compose/). |
| 63 | +### Migration Paths |
68 | 64 |
|
69 |
| -For more information about `DOCKER_INFLUXDB_INIT_*` environment variables, see the [InfluxDB v2 upgrade documentation](https://docs.influxdata.com/influxdb/v2/install/upgrade/v1-to-v2/docker/). |
| 65 | +To migrate from v1 or v2 to InfluxDB 3: |
70 | 66 |
|
71 |
| -## How to use the InfluxDB v1 Docker image |
| 67 | +1. Dual-write new data to v1/v2 and InfluxDB 3. |
| 68 | +2. Query historical data from v1/v2 and write it to InfluxDB 3. *InfluxDB 3 Enterprise is recommended for historical query capability.* |
72 | 69 |
|
73 |
| -*InfluxDB v1 is an earlier version of InfluxDB OSS. InfluxDB 3 Core is the latest stable version.* |
| 70 | +## Using InfluxDB 3 Core (Latest OSS) |
74 | 71 |
|
75 |
| -Run [InfluxDB v1](https://docs.influxdata.com/influxdb/v1/) using the Docker CLI: |
| 72 | +### Start InfluxDB 3 Core |
76 | 73 |
|
77 |
| -```bash |
78 |
| -docker run -d -p 8086:8086 \ |
79 |
| - -v $PWD:/var/lib/influxdb \ |
80 |
| - %%IMAGE%%:1.11 |
81 |
| -``` |
| 74 | +%%COMPOSE%% |
82 | 75 |
|
83 |
| -This command maps port `8086` and mounts your current directory to persist data. |
| 76 | +The example `compose.yaml` starts InfluxDB 3 Core on port 8181 with: |
84 | 77 |
|
85 |
| -For more information, see the [InfluxDB v1 Docker documentation](https://docs.influxdata.com/influxdb/v1/introduction/install/docker/). |
| 78 | +- Data persistence at `/var/lib/influxdb3` |
| 79 | +- Plugin directory for Python processing engine |
| 80 | +- Object storage configured (default: file) |
86 | 81 |
|
87 |
| -## How to use the InfluxDB Enterprise v1 Docker image |
| 82 | +### Get Started Using InfluxDB 3 |
88 | 83 |
|
89 |
| -*InfluxDB Enterprise v1 is an earlier version of InfluxDB Enterprise. InfluxDB 3 Enterprise is the latest stable version.* |
| 84 | +After starting your InfluxDB 3 server: |
90 | 85 |
|
91 |
| -Use the official `%%IMAGE%%:meta` and `%%IMAGE%%:data` Docker images to deploy and manage an InfluxDB v1 Enterprise cluster. A valid license is required. |
| 86 | +- Follow the [Get started guide](https://docs.influxdata.com/influxdb3/core/get-started/) to create an auth token and database, and write, query, and process data. |
| 87 | +- Use the [InfluxDB 3 Explorer UI](https://docs.influxdata.com/influxdb3/explorer/) to write data, create dashboards, explore metrics, and manage databases |
92 | 88 |
|
93 |
| -### Start InfluxDB v1 Enterprise Cluster |
| 89 | +### InfluxDB 3 Server Options |
94 | 90 |
|
95 |
| -Create a custom Docker network for node communication: |
| 91 | +Customize your deployment with available [server options](https://docs.influxdata.com/influxdb3/core/reference/clis/influxdb3/serve/): |
96 | 92 |
|
97 | 93 | ```bash
|
98 |
| -docker network create influxdb |
| 94 | +# View all available options |
| 95 | +docker run --rm %%IMAGE%%:3-core influxdb3 serve --help |
99 | 96 | ```
|
100 | 97 |
|
101 |
| -Start three meta nodes (each with a unique hostname and license key): |
| 98 | +## Using InfluxDB v2 |
102 | 99 |
|
103 |
| -```bash |
104 |
| -# Meta node 0 |
105 |
| -docker run -d \ |
106 |
| - --name=influxdb-meta-0 \ |
107 |
| - --network=influxdb \ |
108 |
| - -h influxdb-meta-0 \ |
109 |
| - -e INFLUXDB_ENTERPRISE_LICENSE_KEY=your-license-key \ |
110 |
| - %%IMAGE%%:meta |
111 |
| - |
112 |
| -# Meta node 1 |
113 |
| -docker run -d \ |
114 |
| - --name=influxdb-meta-1 \ |
115 |
| - --network=influxdb \ |
116 |
| - -h influxdb-meta-1 \ |
117 |
| - -e INFLUXDB_ENTERPRISE_LICENSE_KEY=your-license-key \ |
118 |
| - %%IMAGE%%:meta |
119 |
| - |
120 |
| -# Meta node 2 |
121 |
| -docker run -d \ |
122 |
| - --name=influxdb-meta-2 \ |
123 |
| - --network=influxdb \ |
124 |
| - -h influxdb-meta-2 \ |
125 |
| - -e INFLUXDB_ENTERPRISE_LICENSE_KEY=your-license-key \ |
126 |
| - %%IMAGE%%:meta |
127 |
| -``` |
| 100 | +*InfluxDB v2 is a previous version. Consider InfluxDB 3 Core for new deployments.* |
128 | 101 |
|
129 |
| -Join meta nodes into the cluster: |
| 102 | +### Start InfluxDB v2 |
130 | 103 |
|
131 | 104 | ```bash
|
132 |
| -docker exec influxdb-meta-0 influxd-ctl add-meta influxdb-meta-1:8091 |
133 |
| -docker exec influxdb-meta-0 influxd-ctl add-meta influxdb-meta-2:8091 |
134 |
| -``` |
135 |
| - |
136 |
| -Start data nodes: |
137 |
| - |
138 |
| -```bash |
139 |
| -# Data node 0 |
140 |
| -docker run -d \ |
141 |
| - --name=influxdb-data-0 \ |
142 |
| - --network=influxdb \ |
143 |
| - -h influxdb-data-0 \ |
144 |
| - -e INFLUXDB_ENTERPRISE_LICENSE_KEY=your-license-key \ |
145 |
| - %%IMAGE%%:data |
146 |
| - |
147 |
| -# Data node 1 |
148 |
| -docker run -d \ |
149 |
| - --name=influxdb-data-1 \ |
150 |
| - --network=influxdb \ |
151 |
| - -h influxdb-data-1 \ |
152 |
| - -e INFLUXDB_ENTERPRISE_LICENSE_KEY=your-license-key \ |
153 |
| - %%IMAGE%%:data |
154 |
| -``` |
155 |
| - |
156 |
| -Add data nodes to the cluster: |
157 |
| - |
158 |
| -```bash |
159 |
| -docker exec influxdb-meta-0 influxd-ctl add-data influxdb-data-0:8088 |
160 |
| -docker exec influxdb-meta-0 influxd-ctl add-data influxdb-data-1:8088 |
| 105 | +docker run -d -p 8086:8086 \ |
| 106 | + -v $PWD/data:/var/lib/influxdb2 \ |
| 107 | + -v $PWD/config:/etc/influxdb2 \ |
| 108 | + -e DOCKER_INFLUXDB_INIT_MODE=setup \ |
| 109 | + -e DOCKER_INFLUXDB_INIT_USERNAME=my-user \ |
| 110 | + -e DOCKER_INFLUXDB_INIT_PASSWORD=my-password \ |
| 111 | + -e DOCKER_INFLUXDB_INIT_ORG=my-org \ |
| 112 | + -e DOCKER_INFLUXDB_INIT_BUCKET=my-bucket \ |
| 113 | + %%IMAGE%%:2 |
161 | 114 | ```
|
162 | 115 |
|
163 |
| -Verify cluster status: |
164 |
| - |
165 |
| -```bash |
166 |
| -docker exec influxdb-meta-0 influxd-ctl show |
167 |
| -``` |
| 116 | +After the container starts, visit [http://localhost:8086](http://localhost:8086) to view the UI. |
168 | 117 |
|
169 |
| -This displays all registered data and meta nodes. |
| 118 | +For detailed instructions, see the [InfluxDB v2 Docker Compose documentation](https://docs.influxdata.com/influxdb/v2/install/use-docker-compose/). |
170 | 119 |
|
171 |
| -### Stop InfluxDB v1 Enterprise Containers |
| 120 | +## Using InfluxDB v1 |
172 | 121 |
|
173 |
| -To stop individual containers: |
| 122 | +*InfluxDB v1 is a previous version. Consider InfluxDB 3 Core for new deployments.* |
174 | 123 |
|
175 |
| -```bash |
176 |
| -docker stop influxdb-meta-0 |
177 |
| -docker stop influxdb-meta-1 |
178 |
| -docker stop influxdb-meta-2 |
179 |
| -docker stop influxdb-data-0 |
180 |
| -docker stop influxdb-data-1 |
| 124 | +```console |
| 125 | +docker run -d -p 8086:8086 \ |
| 126 | + -v $PWD:/var/lib/influxdb \ |
| 127 | + %%IMAGE%%:1.11 |
181 | 128 | ```
|
182 | 129 |
|
183 |
| -### Restart Containers |
184 |
| - |
185 |
| -To restart stopped containers: |
| 130 | +This starts InfluxDB v1 with: |
186 | 131 |
|
187 |
| -```bash |
188 |
| -docker start influxdb-meta-0 |
189 |
| -docker start influxdb-meta-1 |
190 |
| -docker start influxdb-meta-2 |
191 |
| -docker start influxdb-data-0 |
192 |
| -docker start influxdb-data-1 |
193 |
| -``` |
| 132 | +- HTTP API on port 8086 |
| 133 | +- Data persisted to current directory |
194 | 134 |
|
195 |
| -For more information, see the [InfluxDB v1 Enterprise documentation](https://docs.influxdata.com/enterprise_influxdb/v1/introduction/installation/docker/). |
| 135 | +For more information, see the [InfluxDB v1 Docker documentation](https://docs.influxdata.com/influxdb/v1/introduction/install/docker/). |
0 commit comments