[[setup-upgrade]] = Upgrade Elasticsearch [partintro] -- Elasticsearch can usually be upgraded using a <> process so upgrading does not interrupt service. However, you might need to <> indices created in older versions. Upgrades across major versions prior to 6.0 require a <>. When upgrading to a new version of Elasticsearch, you need to upgrade each of the products in your Elastic Stack. The steps you need to take to upgrade differ depending on which products you are using. Want a list that's tailored to your stack? Try out our {upgrade_guide}[Interactive Upgrade Guide]. For more information about upgrading your stack, see {stack-ref}[Upgrading the Elastic Stack]. [IMPORTANT] =========================================== Before upgrading Elasticsearch: * Review the <> for changes that affect your application. * Check the <> 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. * <> before upgrading. You **cannot roll back** to an earlier version unless you have a backup of your data. =========================================== 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-paths]] [cols="1> |5.6 |{version} |<> footnoteref:[reindexfn, You must delete or reindex any indices created in 2.x before upgrading.] |5.0-5.5 |{version} |<> footnoteref:[reindexfn] |Pre-5.0 |{version} |<> |======================================================================= [IMPORTANT] =============================================== Elasticsearch can read indices created in the *previous major version*. Older indices must be reindexed or deleted. Elasticsearch 6.n can use indices created in Elasticsearch 5.n, but not those created in Elasticsearch 2.n or before. Elasticsearch 5.n can use indices created in Elasticsearch 2.n, but not those created in 1.n or before. This also applies to indices backed up with <>. If an index was originally created in 2.n, it cannot be restored to a 6.n cluster even if the snapshot was created by a 5.n cluster. Elasticsearch nodes will fail to start if incompatible indices are present. For information about how to upgrade old indices, see <>. =============================================== [float] [[elasticsearch-upgrade-6.3]] === Upgrading to 6.3 Starting in 6.3, the default distribution includes {xpack} with a free Basic license. If you already have a Basic license, once you upgrade to 6.3 it will never expire or need to be renewed. If you have a license subscription, your license and settings are preserved when you upgrade. You can perform rolling upgrades to 6.3 from OSS-only clusters running 5.6 or 6.0-6.2. {xpack} Basic features will be operational once the cluster is fully upgraded. If you are using {xpack} for the first time, you must explicitly enable data collection after the upgrade to use monitoring. Set `xpack.monitoring.collection.enabled` to `true` with the `_cluster/settings` API: [source,json] ---------------------------------------------------------- PUT /_cluster/settings { "persistent" : { "xpack.monitoring.collection.enabled" : "true" } } ---------------------------------------------------------- // CONSOLE To take all of the {xpack} features for a spin, you can start a 30-day trial from Kibana, or with the Start Trial API: [source,json] ---------------------------------------------------------- POST _xpack/license/start_trial ---------------------------------------------------------- // CONSOLE The 30-day trial enables you to try out the full set of Platinum features, including security, machine learning, alerting, graph capabilities, and more. -- include::upgrade/rolling_upgrade.asciidoc[] include::upgrade/cluster_restart.asciidoc[] include::upgrade/reindex_upgrade.asciidoc[]