Upgrading Elasticsearchedit

Important

Before upgrading Elasticsearch:

  • Review the breaking changes for changes that affect your application.
  • Check the deprecation log to see if you are using any deprecated features.
  • If you use custom plugins, make sure compatible versions are available.
  • Test upgrades in a dev environment before upgrading your production cluster.
  • Back up your data before upgrading. You cannot roll back to an earlier version unless you have a backup of your data.

Elasticsearch can usually be upgraded using a Rolling upgrade process so upgrading does not interrupt service. However, you might need to Reindex to upgrade indices created in older versions. Upgrades across major versions prior to 6.0 require a Full cluster restart.

The following table shows when you can perform a rolling upgrade, when you need to reindex or delete old indices, and when a full cluster restart is required.

Upgrade From Upgrade To Supported Upgrade Type

5.x

5.y

Rolling upgrade (where y > x)

5.6

6.x

Rolling upgrade [a]

5.0-5.5

6.x

Full cluster restart [a]

<5.x

6.x

Reindex to upgrade

6.x

6.y

Rolling upgrade (where y > x) [b]

[a] You must delete or reindex any indices created in 2.x before upgrading.

[b] Upgrading from a 6.0.0 pre GA version requires a full cluster restart.

Important

Elasticsearch can read indices created in the previous major version. Older indices must be reindexed or deleted. Elasticsearch 6.x can use indices created in Elasticsearch 5.x, but not those created in Elasticsearch 2.x or before. Elasticsearch 5.x can use indices created in Elasticsearch 2.x, but not those created in 1.x or before.

This also applies to indices backed up with snapshot and restore. If an index was originally created in 2.x, it cannot be restored to a 6.x cluster even if the snapshot was created by a 2.x cluster.

Elasticsearch nodes will fail to start if incompatible indices are present.

For information about how to upgrade old indices, see Reindex to upgrade.