2014-04-01 12:28:08 -04:00
|
|
|
[[setup-upgrade]]
|
2017-12-05 10:58:52 -08:00
|
|
|
= Upgrade Elasticsearch
|
|
|
|
|
|
|
|
[partintro]
|
|
|
|
--
|
|
|
|
Elasticsearch can usually be upgraded using a <<rolling-upgrades,Rolling upgrade>>
|
|
|
|
process so upgrading does not interrupt service. However, you might
|
|
|
|
need to <<reindex-upgrade,Reindex to upgrade>> indices created in older versions.
|
|
|
|
Upgrades across major versions prior to 6.0 require a <<restart-upgrade,Full cluster restart>>.
|
|
|
|
|
|
|
|
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].
|
2014-04-01 12:28:08 -04:00
|
|
|
|
2015-05-04 16:48:53 +02:00
|
|
|
[IMPORTANT]
|
2015-06-19 16:27:28 +02:00
|
|
|
===========================================
|
|
|
|
Before upgrading Elasticsearch:
|
2014-04-01 12:28:08 -04:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
* Review the <<breaking-changes,breaking changes>> for changes that
|
|
|
|
affect your application.
|
|
|
|
* Check the <<deprecation-logging, deprecation log>> to see if you are using
|
|
|
|
any deprecated features.
|
|
|
|
* If you use custom plugins, make sure compatible versions are available.
|
2015-06-19 16:27:28 +02:00
|
|
|
* Test upgrades in a dev environment before upgrading your production cluster.
|
2017-08-23 14:03:14 -07:00
|
|
|
* <<modules-snapshots,Back up your data>> before upgrading.
|
|
|
|
You **cannot roll back** to an earlier version unless you have a backup of
|
|
|
|
your data.
|
|
|
|
|
2015-06-19 16:27:28 +02:00
|
|
|
===========================================
|
2014-04-01 12:28:08 -04:00
|
|
|
|
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
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.
|
2014-04-01 12:28:08 -04:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
[[upgrade-paths]]
|
2015-06-19 16:27:28 +02:00
|
|
|
[cols="1<m,1<m,3",options="header",]
|
|
|
|
|=======================================================================
|
|
|
|
|Upgrade From |Upgrade To |Supported Upgrade Type
|
2018-06-11 15:53:25 -07:00
|
|
|
|6.0-6.2 |{version} |<<rolling-upgrades,Rolling upgrade>>
|
|
|
|
|5.6 |{version} |<<rolling-upgrades,Rolling upgrade>> footnoteref:[reindexfn, You must delete or reindex any indices created in 2.x before upgrading.]
|
|
|
|
|5.0-5.5 |{version} |<<restart-upgrade,Full cluster restart>> footnoteref:[reindexfn]
|
|
|
|
|Pre-5.0 |{version} |<<reindex-upgrade,Reindex to upgrade>>
|
2015-06-19 16:27:28 +02:00
|
|
|
|=======================================================================
|
2014-04-01 12:28:08 -04:00
|
|
|
|
2016-10-11 12:14:35 +02:00
|
|
|
[IMPORTANT]
|
|
|
|
===============================================
|
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
Elasticsearch can read indices created in the *previous major version*.
|
2018-06-11 15:53:25 -07:00
|
|
|
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.
|
2017-08-23 14:03:14 -07:00
|
|
|
|
|
|
|
This also applies to indices backed up with <<modules-snapshots,snapshot
|
2018-06-11 15:53:25 -07:00
|
|
|
and restore>>. 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.
|
2016-10-11 12:14:35 +02:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
Elasticsearch nodes will fail to start if incompatible indices are present.
|
2016-10-11 12:14:35 +02:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
For information about how to upgrade old indices, see <<reindex-upgrade,
|
|
|
|
Reindex to upgrade>>.
|
2016-10-11 12:14:35 +02:00
|
|
|
|
|
|
|
===============================================
|
2018-06-11 15:53:25 -07:00
|
|
|
|
|
|
|
[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:
|
|
|
|
|
2018-06-11 22:04:30 -04:00
|
|
|
[source,json]
|
2018-06-11 15:53:25 -07:00
|
|
|
----------------------------------------------------------
|
|
|
|
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:
|
|
|
|
|
2018-06-11 22:04:30 -04:00
|
|
|
[source,json]
|
2018-06-11 15:53:25 -07:00
|
|
|
----------------------------------------------------------
|
|
|
|
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.
|
|
|
|
|
2017-12-05 10:58:52 -08:00
|
|
|
--
|
2016-10-11 12:14:35 +02:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
include::upgrade/rolling_upgrade.asciidoc[]
|
2014-04-01 12:28:08 -04:00
|
|
|
|
2017-08-23 14:03:14 -07:00
|
|
|
include::upgrade/cluster_restart.asciidoc[]
|
2016-10-11 12:14:35 +02:00
|
|
|
|
2017-12-15 00:42:36 -08:00
|
|
|
include::upgrade/reindex_upgrade.asciidoc[]
|