Documentation

Install InfluxDB OSS v2

The InfluxDB v2 time series platform is purpose-built to collect, store, process and visualize metrics and events.

Download and install InfluxDB v2

Recommended:: Before you open and install packages and downloaded files, use SHA checksum verification and GPG signature verification to ensure the files are intact and authentic.

InfluxDB installation instructions for some OS versions include steps to verify downloaded files before you install them.

For more information about SHA and GPG verifications, see the following:

Choose the InfluxData key-pair for your OS version

Verify download integrity using SHA-256

Verify file integrity and authenticity using GPG

The following instructions include steps for downloading, verifying, and installing InfluxDB:

To install InfluxDB on Linux, do one of the following:

InfluxDB and the influx CLI are separate packages

The InfluxDB server (influxd) and the influx CLI are packaged and versioned separately.

You’ll install the influx CLI in a later step.

Install InfluxDB as a service with systemd

  1. Choose the InfluxData key-pair for your OS version.

  2. Run the command for your OS version to install the InfluxData key, add the InfluxData repository, and install influxdb.

    Before running the command, replace the checksum and key filename with the key-pair from the preceding step.

    # Ubuntu and Debian
    # Add the InfluxData key to verify downloads and add the repository
    curl --silent --location -O \
    https://repos.influxdata.com/influxdata-archive.key
    echo "943666881a1b8d9b849b74caebf02d3465d6beb716510d86a39f6c8e8dac7515  influxdata-archive.key" \
    | sha256sum --check - && cat influxdata-archive.key \
    | gpg --dearmor \
    | sudo tee /etc/apt/trusted.gpg.d/influxdata-archive.gpg > /dev/null \
    && echo 'deb [signed-by=/etc/apt/trusted.gpg.d/influxdata-archive.gpg] https://repos.influxdata.com/debian stable main' \
    | sudo tee /etc/apt/sources.list.d/influxdata.list
    # Install influxdb
    sudo apt-get update && sudo apt-get install influxdb2
    
    • Copy
    • Fill window
    # RedHat and CentOS
    # Add the InfluxData key to verify downloads
    curl --silent --location -O \
    https://repos.influxdata.com/influxdata-archive.key \
    && echo "943666881a1b8d9b849b74caebf02d3465d6beb716510d86a39f6c8e8dac7515  influxdata-archive.key" \
    | sha256sum --check - && cat influxdata-archive.key \
    | gpg --dearmor \
    | tee /etc/pki/rpm-gpg/RPM-GPG-KEY-influxdata > /dev/null
    
    # Add the InfluxData repository to the repository list.
    cat <<EOF | tee /etc/yum.repos.d/influxdata.repo
    [influxdata]
    name = InfluxData Repository - Stable
    baseurl = https://repos.influxdata.com/stable/${basearch}/main
    enabled = 1
    gpgcheck = 1
    gpgkey = file:///etc/pki/rpm-gpg/RPM-GPG-KEY-influxdata
    EOF
    
    # Install influxdb
    sudo yum install influxdb2
    
    • Copy
    • Fill window
  3. Start the InfluxDB service:

    sudo service influxdb start
    
    • Copy
    • Fill window

    Installing the InfluxDB package creates a service file at /lib/systemd/system/influxdb.service to start InfluxDB as a background service on startup.

  4. To verify that the service is running correctly, restart your system and then enter the following command in your terminal:

    sudo service influxdb status
    
    • Copy
    • Fill window

    If successful, the output is the following:

    ● influxdb.service - InfluxDB is an open-source, distributed, time series database
       Loaded: loaded (/lib/systemd/system/influxdb.service; enabled; vendor preset: enable>
       Active: active (running)
    
    • Copy
    • Fill window

For information about where InfluxDB stores data on disk when running as a service, see File system layout.

Pass configuration options to the service

You can use systemd to customize InfluxDB configuration options and pass them to the InfluxDB service.

  1. Edit the /etc/default/influxdb2 service configuration file to assign configuration directives to influxd command line flags–for example, add one or more <ENV_VARIABLE_NAME>=<COMMAND_LINE_FLAG> lines like the following:

    ARG1="--http-bind-address :8087"
    ARG2="--storage-wal-fsync-delay=15m"
    
    • Copy
    • Fill window
  2. Edit the /lib/systemd/system/influxdb.service file to pass the variables to the ExecStart value:

    ExecStart=/usr/bin/influxd $ARG1 $ARG2
    
    • Copy
    • Fill window

Manually download and install the influxd binary

If necessary, adjust the example file paths and utilities for your system.

  1. In your browser or your terminal, download the InfluxDB binary for your system architecture (AMD64 or ARM).

    InfluxDB v2 (amd64) InfluxDB v2 (arm)

    # Use curl to download the amd64 binary.
    curl --location -O \
    https://download.influxdata.com/influxdb/releases/influxdb2-2.7.11_linux_amd64.tar.gz
    
    • Copy
    • Fill window
    # Use curl to download the arm64 binary.
    curl --location -O \
    https://download.influxdata.com/influxdb/releases/influxdb2-2.7.11_linux_arm64.tar.gz
    
    • Copy
    • Fill window
  2. Choose the InfluxData key-pair for your OS version.

  3. Recommended:: Verify the authenticity of the downloaded binary–for example, enter the following command in your terminal.

    Before running the command for your system, replace https://repos.influxdata.com/influxdata-archive.key with the key URL from the preceding step.

    # amd64
    # Download and import the key
    curl --silent --location https://repos.influxdata.com/influxdata-archive.key \
    | gpg --import - 2>&1 \
    | grep 'InfluxData Package Signing Key <support@influxdata.com>' \
    &&
    # Download and verify the binary's signature file
    curl --silent --location "https://download.influxdata.com/influxdb/releases/influxdb2-2.7.11_linux_amd64.tar.gz.asc" \
    | gpg --verify - influxdb2-2.7.11_linux_amd64.tar.gz \
    2>&1 | grep 'InfluxData Package Signing Key <support@influxdata.com>'
    
    • Copy
    • Fill window
    # arm64
    # Download and import the key
    curl --silent --location https://repos.influxdata.com/influxdata-archive.key \
    | gpg --import - 2>&1 \
    | grep 'InfluxData Package Signing Key <support@influxdata.com>' \
    &&
    # Download and verify the binary's signature file
    curl --silent --location "https://download.influxdata.com/influxdb/releases/influxdb2-2.7.11_linux_arm64.tar.gz.asc" \
    | gpg --verify - influxdb2-2.7.11_linux_arm64.tar.gz \
    2>&1 | grep 'InfluxData Package Signing Key <support@influxdata.com>'
    
    • Copy
    • Fill window

    If successful, the output is similar to the following:

    gpg: Good signature from "InfluxData Package Signing Key <support@influxdata.com>" [unknown]
    
    • Copy
    • Fill window
  4. Extract the downloaded binary–for example, enter the following command for your system:

    # amd64
    tar xvzf ./influxdb2-2.7.11_linux_amd64.tar.gz
    
    • Copy
    • Fill window
    # arm64
    tar xvzf ./influxdb2-2.7.11_linux_arm64.tar.gz
    
    • Copy
    • Fill window
  5. Optional: Place the extracted influxd executable binary in your system $PATH.

    # amd64
    sudo cp ./influxdb2-2.7.11/usr/bin/influxd /usr/local/bin/
    
    • Copy
    • Fill window
    # arm64
    sudo cp ./influxdb2-2.7.11/usr/bin/influxd /usr/local/bin/
    
    • Copy
    • Fill window

    If you choose to not move the influxd binary into your $PATH, enter the path to the binary to start the server–for example:

    ./influxdb2-2.7.11/usr/bin/influxd
    
    • Copy
    • Fill window

Start InfluxDB

If it isn’t already running, follow the instructions to start InfluxDB on your system:

If InfluxDB was installed as a systemd service, systemd manages the influxd daemon and no further action is required. If the binary was manually downloaded and added to the system $PATH, start the influxd daemon with the following command:

influxd
  • Copy
  • Fill window

If successful, you can view the InfluxDB UI at http://localhost:8086.

InfluxDB starts with default settings, including the following:

  • http-bind-address=:8086: Uses port 8086 (TCP) for InfluxDB UI and HTTP API client-server communication.
  • reporting-disabled=false: Sends InfluxDB telemetry information back to InfluxData.

To override default settings, specify configuration options when starting InfluxDB–for example:

Configure the port or address

Opt-out of telemetry reporting

For information about InfluxDB v2 default settings and how to override them, see InfluxDB configuration options.

With InfluxDB installed and initialized, get started writing and querying data.

Download, install, and configure the influx CLI

Recommended:: Install the influx CLI, which provides a simple way to interact with InfluxDB from a command line. For detailed installation and setup instructions, see Use the influx CLI.

InfluxDB and the influx CLI are separate packages

The InfluxDB server (influxd) and the influx CLI are packaged and versioned separately. Some install methods (for example, the InfluxDB Docker Hub image) include both.


Was this page helpful?

Thank you for your feedback!


The future of Flux

Flux is going into maintenance mode. You can continue using it as you currently are without any changes to your code.

Read more

InfluxDB 3 Core and Enterprise are now in Beta

InfluxDB 3 Core and Enterprise are now available for beta testing, available under MIT or Apache 2 license.

InfluxDB 3 Core is a high-speed, recent-data engine that collects and processes data in real-time, while persisting it to local disk or object storage. InfluxDB 3 Enterprise is a commercial product that builds on Core’s foundation, adding high availability, read replicas, enhanced security, and data compaction for faster queries. A free tier of InfluxDB 3 Enterprise will also be available for at-home, non-commercial use for hobbyists to get the full historical time series database set of capabilities.

For more information, check out: