|
@@ -12,7 +12,9 @@ supported for your version of Elasticsearch.
|
|
|
|
|
|
To perform a rolling upgrade:
|
|
To perform a rolling upgrade:
|
|
|
|
|
|
-==== Step 1: Disable shard allocation
|
|
|
|
|
|
+. *Disable shard allocation*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
When you shut down a node, the allocation process will wait for one minute
|
|
When you shut down a node, the allocation process will wait for one minute
|
|
before starting to replicate the shards that were on that node to other nodes
|
|
before starting to replicate the shards that were on that node to other nodes
|
|
@@ -30,8 +32,11 @@ PUT _cluster/settings
|
|
--------------------------------------------------
|
|
--------------------------------------------------
|
|
// CONSOLE
|
|
// CONSOLE
|
|
// TEST[skip:indexes don't assign]
|
|
// TEST[skip:indexes don't assign]
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 2: Stop non-essential indexing and perform a synced flush (Optional)
|
|
|
|
|
|
+. *Stop non-essential indexing and perform a synced flush (Optional)*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
You may happily continue indexing during the upgrade. However, shard recovery
|
|
You may happily continue indexing during the upgrade. However, shard recovery
|
|
will be much faster if you temporarily stop non-essential indexing and issue a
|
|
will be much faster if you temporarily stop non-essential indexing and issue a
|
|
@@ -46,9 +51,11 @@ POST _flush/synced
|
|
A synced flush request is a ``best effort'' operation. It will fail if there
|
|
A synced flush request is a ``best effort'' operation. It will fail if there
|
|
are any pending indexing operations, but it is safe to reissue the request
|
|
are any pending indexing operations, but it is safe to reissue the request
|
|
multiple times if necessary.
|
|
multiple times if necessary.
|
|
|
|
+--
|
|
|
|
|
|
-[[upgrade-node]]
|
|
|
|
-==== Step 3: Stop and upgrade a single node
|
|
|
|
|
|
+. [[upgrade-node]] *Stop and upgrade a single node*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
Shut down one of the nodes in the cluster *before* starting the upgrade.
|
|
Shut down one of the nodes in the cluster *before* starting the upgrade.
|
|
|
|
|
|
@@ -87,14 +94,20 @@ To upgrade using a zip or compressed tarball:
|
|
* Either copy the files in the `data` directory from your old installation
|
|
* Either copy the files in the `data` directory from your old installation
|
|
to your new installation, or configure the location of the data directory
|
|
to your new installation, or configure the location of the data directory
|
|
in the `config/elasticsearch.yml` file, with the `path.data` setting.
|
|
in the `config/elasticsearch.yml` file, with the `path.data` setting.
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 4: Upgrade any plugins
|
|
|
|
|
|
+. *Upgrade any plugins*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
Elasticsearch plugins must be upgraded when upgrading a node. Use the
|
|
Elasticsearch plugins must be upgraded when upgrading a node. Use the
|
|
`elasticsearch-plugin` script to install the correct version of any plugins
|
|
`elasticsearch-plugin` script to install the correct version of any plugins
|
|
that you need.
|
|
that you need.
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 5: Start the upgraded node
|
|
|
|
|
|
+. *Start the upgraded node*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
Start the now upgraded node and confirm that it joins the cluster by checking
|
|
Start the now upgraded node and confirm that it joins the cluster by checking
|
|
the log file or by checking the output of this request:
|
|
the log file or by checking the output of this request:
|
|
@@ -104,8 +117,11 @@ the log file or by checking the output of this request:
|
|
GET _cat/nodes
|
|
GET _cat/nodes
|
|
--------------------------------------------------
|
|
--------------------------------------------------
|
|
// CONSOLE
|
|
// CONSOLE
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 6: Reenable shard allocation
|
|
|
|
|
|
+. *Reenable shard allocation*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
Once the node has joined the cluster, reenable shard allocation to start using
|
|
Once the node has joined the cluster, reenable shard allocation to start using
|
|
the node:
|
|
the node:
|
|
@@ -120,8 +136,11 @@ PUT _cluster/settings
|
|
}
|
|
}
|
|
--------------------------------------------------
|
|
--------------------------------------------------
|
|
// CONSOLE
|
|
// CONSOLE
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 7: Wait for the node to recover
|
|
|
|
|
|
+. *Wait for the node to recover*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
You should wait for the cluster to finish shard allocation before upgrading
|
|
You should wait for the cluster to finish shard allocation before upgrading
|
|
the next node. You can check on progress with the <<cat-health,`_cat/health`>>
|
|
the next node. You can check on progress with the <<cat-health,`_cat/health`>>
|
|
@@ -168,8 +187,12 @@ GET _cat/recovery
|
|
|
|
|
|
If you stopped indexing, then it is safe to resume indexing as soon as
|
|
If you stopped indexing, then it is safe to resume indexing as soon as
|
|
recovery has completed.
|
|
recovery has completed.
|
|
|
|
+--
|
|
|
|
|
|
-==== Step 8: Repeat
|
|
|
|
|
|
+. *Repeat*
|
|
|
|
++
|
|
|
|
+--
|
|
|
|
|
|
When the cluster is stable and the node has recovered, repeat the above steps
|
|
When the cluster is stable and the node has recovered, repeat the above steps
|
|
for all remaining nodes.
|
|
for all remaining nodes.
|
|
|
|
+--
|