Documentation

Migrate InfluxDB OSS instances to InfluxDB Enterprise clusters

Migrate a running instance of InfluxDB open source (OSS) to an InfluxDB Enterprise cluster.

Migration transfers all users from the OSS instance to the InfluxDB Enterprise cluster.

Migrate an OSS instance to InfluxDB Enterprise

Complete the following tasks to migrate data from OSS to an InfluxDB Enterprise cluster without downtime or missing data.

  1. Upgrade InfluxDB OSS and InfluxDB Enterprise to the latest stable versions.

  2. On each meta node and each data node, add the IP and hostname of your OSS instance to the /etc/hosts file. This will allow the nodes to communicate with the OSS instance.

  3. On the OSS instance, take a portable backup from OSS using the influxd backup command with the -portable flag:

    influxd backup -portable -host <IP address>:8088 /tmp/mysnapshot
    

    Note the current date and time when you take the backup. For more information, see influxd backup.

  4. Restore the backup on the cluster by running the following:

    influxd-ctl restore <path-to-backup-files>
    

    Note: InfluxDB Enterprise uses the influxd-ctl utility to back up and restore data. For more information, see influxd-ctl and restore.

  5. To avoid data loss, dual write to both OSS and Enterprise while completing the remaining steps. This keeps the OSS and cluster active for testing and acceptance work. For more information, see Write data with the InfluxDB API.

  6. Export data from OSS from the time the backup was taken to the time the dual write started. For example, if you take the backup on 2020-07-19T00:00:00.000Z, and started writing data to Enterprise at 2020-07-19T23:59:59.999Z, you would run the following command:

    influx_inspect export -compress -start 2020-07-19T00:00:00.000Z -end 2020-07-19T23:59:59.999Z`
    

    For more information, see -export.

  7. Import data into Enterprise.

  8. Verify data is successfully migrated to your Enterprise cluster. See:

Next, stop writes to OSS instance, and remove it.

Stop writes and remove OSS

  1. Stop all writes to the InfluxDB OSS instance.

  2. Stop the influxdb service on the InfluxDB OSS instance server.

    sudo service influxdb stop
    
    sudo systemctl stop influxdb
    
    1. Double check that the service is stopped. The following command should return nothing:
    ps ax | grep influxd
    
  3. Remove the InfluxDB OSS package.

    sudo apt-get remove influxdb
    
    sudo yum remove influxdb
    

Rebalance the cluster

  1. Use the ALTER RETENTION POLICY statement to increase the replication factor on all existing retention polices to the number of data nodes in your cluster.
  2. Rebalance your cluster manually to meet the desired replication factor for existing shards.
  3. If you were using Chronograf, add your Enterprise instance as a new data source.

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 v3 enhancements and InfluxDB Clustered is now generally available

New capabilities, including faster query performance and management tooling advance the InfluxDB v3 product line. InfluxDB Clustered is now generally available.

InfluxDB v3 performance and features

The InfluxDB v3 product line has seen significant enhancements in query performance and has made new management tooling available. These enhancements include an operational dashboard to monitor the health of your InfluxDB cluster, single sign-on (SSO) support in InfluxDB Cloud Dedicated, and new management APIs for tokens and databases.

Learn about the new v3 enhancements


InfluxDB Clustered general availability

InfluxDB Clustered is now generally available and gives you the power of InfluxDB v3 in your self-managed stack.

Talk to us about InfluxDB Clustered