Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add guide for migrating from Elasticsearch 7.10 to OpenSearch 1.x (latest) #2564

Merged
merged 54 commits into from
Feb 15, 2023
Merged
Show file tree
Hide file tree
Changes from 40 commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
9e42f54
Migrating to new branch since the ToC structure has changed so much
Feb 1, 2023
11ec719
Making changes
Feb 1, 2023
24489b0
Added caveat to upgrade spans
Feb 1, 2023
5fed608
Add blurb about the context of the guide - will revisit and add later…
Feb 1, 2023
ee1d827
Reordering sections
Feb 1, 2023
d6d1277
Adding redirects but I think I'm going to rename the pages
Feb 3, 2023
1f2acf3
Renamed
Feb 3, 2023
0bcba00
Renamed
Feb 3, 2023
f795959
Changes
Feb 3, 2023
cb2c0bf
Add note about Lucene table
Feb 3, 2023
3634fc8
Fixed table and identified some issues with overall site formatting -…
Feb 6, 2023
45c4889
Fixed table
Feb 6, 2023
95bf43c
Fixing front matter
Feb 7, 2023
9bf4367
Finally figured out how to make the ToC work - now the structure look…
Feb 7, 2023
46b1cc0
Fix nav order on index, rename pages for consistency with ToC gerund …
Feb 7, 2023
1a8c4c0
Renaming the page to rolling upgrade since that is the only method be…
Feb 7, 2023
94705de
Working through top-to-bottom now
Feb 8, 2023
00111f3
Got the beginning steps re-ordered to make more sense and added some …
Feb 8, 2023
56cd46f
Wrapped up the technical steps and indented all content in the number…
Feb 8, 2023
98cad43
Renamed upgrade page to make more relevant
Feb 8, 2023
876ddd2
Tweaking toc
Feb 8, 2023
3760913
Fixed markdown block formatting in rolling restart page
Feb 8, 2023
2c0edda
Working through upgrade intro and implementing technical feedback
Feb 9, 2023
899f9ac
Phrasing
Feb 9, 2023
571593f
Reviewing reindex guidance
Feb 9, 2023
6f2bc42
Phrasing on compatibility to make tone more active
Feb 9, 2023
c63df49
Added banner about the status of the docs but pending review from Him…
Feb 9, 2023
35ca70c
Refined wording for note about this document
Feb 9, 2023
33c4433
Added note to restart upgrade
Feb 9, 2023
7c28c0b
Stashing changes before weekend
Feb 10, 2023
cc7e002
Created clean meta issue for fresh pushes and added link
Feb 13, 2023
aeec5b1
Added related links
Feb 13, 2023
fd4d018
Editing
Feb 13, 2023
8d16b29
Editing continued
Feb 13, 2023
f560c6b
Working on the table dimensions
Feb 13, 2023
34e1359
Final changes to draft and ready for doc review
Feb 13, 2023
4feb891
Doc review changes
Feb 14, 2023
24ccae7
Removed a comma from line 97 after additional feedback from doc reviewer
Feb 14, 2023
e7c9f35
Removed a comma from line 97 after additional feedback from doc reviewer
Feb 14, 2023
537fd26
Re-added comma after additional doc review comments
Feb 14, 2023
a44379d
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
f3c6843
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
6161f88
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
710baf0
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
06d98ba
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
ead65d1
Update _install-and-configure/upgrade-opensearch/rolling-upgrade.md
Feb 15, 2023
2218ddc
Update _install-and-configure/upgrade-opensearch/rolling-upgrade.md
Feb 15, 2023
5db8a99
Update _install-and-configure/upgrade-opensearch/rolling-upgrade.md
Feb 15, 2023
4d1e8e4
Final editorial changes applied
Feb 15, 2023
425959a
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
463367b
Update _install-and-configure/upgrade-opensearch/index.md
Feb 15, 2023
d2740fd
More editorial fixes
Feb 15, 2023
18c759a
Apply suggestions from code review
Feb 15, 2023
1946b63
More orphaned review comments because of local-remote disparities
Feb 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
229 changes: 229 additions & 0 deletions _install-and-configure/upgrade-opensearch/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,229 @@
---
layout: default
title: Upgrading OpenSearch
nav_order: 4
has_children: true
redirect_from:
- /upgrade-opensearch/index/
---

# Upgrading OpenSearch

The OpenSearch Project releases regular updates that include new features, enhancements, and bug fixes. OpenSearch uses [Semantic Versioning](https://semver.org/), which means that breaking changes are only introduced between major version releases. To learn about upcoming features and fixes, review the [OpenSearch Project Roadmap](https://github.com/orgs/opensearch-project/projects/1) on GitHub. To see a list of previous releases, or to learn more about how OpenSearch uses versioning, go to [Release Schedule and Maintenance Policy]({{site.url}}/releases.html).
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

We recognize that users are excited about upgrading OpenSearch to enjoy the latest features, and we will continue to expand on these upgrade and migration documents to cover additional topics, such as upgrading OpenSearch Dashboards and preserving custom configurations, such as for plugins. To see what's coming next, or to make a request for future content, leave a comment on the [upgrade and migration documentation meta issue](https://github.com/opensearch-project/documentation-website/issues/2830) in the [OpenSearch Project](https://github.com/opensearch-project) on GitHub.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

If would like to see a specific process added, or would like to contribute yourself, please [submit an issue](https://github.com/opensearch-project/documentation-website/issues) on GitHub. Check out the [Contributor Guidelines](https://github.com/opensearch-project/documentation-website/blob/main/CONTRIBUTING.md) to see how you can help.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
{: .tip}

## Workflow considerations

Take time to plan the process before making any changes to your cluster. For example, consider the following questions:

- How long the upgrade process will take?
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- If your cluster is being used in production, how impactful is downtime?
- Do you have infrastructure in place to stand up the new cluster in a testing or development environment before you move it into production, or do you need to upgrade the production hosts directly?

The answers to questions like these will help you determine which upgrade path will work best in your environment.

At a minimum, you should:

- [Review breaking changes](#review-breaking-changes)
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- [Review the OpenSearch tools compatibility matrices](#review-the-opensearch-tools-compatibility-matrices)
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- [Check plugin compatibility](#review-plugin-compatibility)
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- [Back up configuration files](#back-up-configuration-files)
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- [Take a snapshot](#take-a-snapshot)
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

Stop any non-essential indexing before you begin the upgrade procedure to eliminate unnecessary resource strains on the cluster while you perform the upgrade.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
{: .tip}

### Review breaking changes

It's important to determine how the new version of OpenSearch will fit into your environment. Review [Breaking changes]({{site.url}}{{site.baseurl}}/breaking-changes/) before beginning any upgrade procedures to determine if you will need to make adjustments in your workflow. For example, upstream or downstream components might need to be modified to be compatible with an API change.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

### Review the OpenSearch tools compatibility matrices

If your OpenSearch cluster interacts with other services in your environment, like Logstash or Beats, then you should check the [OpenSearch tools compatibility matrices]({{site.url}}{{site.baseurl}}/tools/index/#compatibility-matrices) to see if other components will need to be upgraded.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

### Review plugin compatibility

Review the plugins you use to determine compatibility with the target version of OpenSearch. Official OpenSearch Project plugins can be found in the [OpenSearch Project](https://github.com/opensearch-project) repository on GitHub. If you use any third party plugins, then you should check the documentation for those plugins to determine if they are compatible.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

### Back up configuration files

Mitigate the risk of data loss by backing up any important files before you start an upgrade. Generally speaking, these files will be located in either of two directories:
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

- `opensearch/config`
- `opensearch-dashboards/config`

Some examples include `opensearch.yml`, `opensearch_dashboards.yml`, plugin configuration files, and TLS certificates. Once you identify which files you want to back up, copy them to remote storage for safety.

### Take a snapshot

We recommend that you back up your cluster state and indexes using [Snapshots]({{site.url}}{{site.baseurl}}/opensearch/snapshots/index/). If you use security features, make sure to read [A word of caution]({{site.url}}{{site.baseurl}}/security-plugin/configuration/security-admin/#a-word-of-caution) for details about backing up and restoring your security settings.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

## Upgrade methods

Choose an appropriate method for upgrading your cluster to a new version of OpenSearch based on your requirements.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

- [Rolling upgrade](#rolling-upgrade) is the process of upgrading nodes one at a time without stopping the cluster.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
- [Cluster restart upgrade](#cluster-restart-upgrade) is the process of upgrading services while the cluster is stopped.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

Upgrades spanning more than a single major version of OpenSearch will require additional effort due to the need for reindexing. For more information, refer to the [Reindex]({{site.url}}{{site.baseurl}}/api-reference/document-apis/reindex/) API. See the [Lucene version reference](#lucene-version-reference) table included later in this guide for help planning your data migration.

### Rolling upgrade

Rolling upgrades are a great option if you want to keep your cluster operational throughout the process. Data may continue to be ingested, analyzed, and queried as nodes are invididually stopped, upgraded, and restarted. A variation of the rolling upgrade, referred to as "node replacement," is exactly the same process except hosts or containers are not reused for the new node. You might perform node replacement if you are upgrading the underlying host(s) as well.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

OpenSearch nodes cannot join a cluster if the cluster manager is running a newer version of OpenSearch than the node requesting membership. To avoid this issue, upgrade the cluster manager-eligible nodes last.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

See [Rolling Upgrade]({{site.url}}{{site.baseurl}}/install-and-configure/upgrade-opensearch/rolling-upgrade/) for details about the process.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

### Cluster restart upgrade

OpenSearch administrators might choose to perform a cluster restart upgrade for several reasons. For example, if the administrator doesn't want to perform maintenance on a running cluster, or if the cluster is being migrated to a different environment.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

Unlike a rolling upgrade, where only one node is offline at a time, a cluster restart upgrade requires you to stop OpenSearch and OpenSearch Dashboards on all nodes in the cluster before proceeding. After the nodes are stopped, a new version of OpenSearch is installed. Then OpenSearch is started and the cluster bootstraps to the new version.

## Compatibility

OpenSearch nodes are compatible with other OpenSearch nodes running any other *minor* version within the same *major* version release. For example, 1.1.0 is compatible with 1.3.7 because they are part of the same *major* version (1.x). Additionally, OpenSearch nodes and indexes are backwards-compatible with the previous major version. That means, for example, that an index created by an OpenSearch node running any 1.x version could be restored from a snapshot to an OpenSearch cluster running any 2.x version.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

OpenSearch 1.x nodes are compatible with nodes running Elasticsearch 7.x, but the longevity of a mixed-version environment should not extend beyond cluster upgrade activities.
{: .tip}

Index compatibility is determined by the version of [Apache Lucene](https://lucene.apache.org/) that created the index. If an index was created by an OpenSearch cluster running version 1.0.0, then the index could be used by any other OpenSearch cluster running up to the latest 1.x or 2.x release. See the [Index compatibility reference](#index-compatibility-reference) table for Lucene versions running in OpenSearch 1.0.0 and later and [Elasticsearch](https://www.elastic.co/) 6.8 and later.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

If your upgrade path spans more than a single major version and you want to retain any existing index(es), then you can use the [Reindex]({{site.url}}{{site.baseurl}}/api-reference/document-apis/reindex/) API to make your indexes compatible with the target version of OpenSearch before upgrading. For example, if your cluster is currently running Elasticsearch 6.8 and you want to upgrade to OpenSearch 2.x, then you must first upgrade to OpenSearch 1.x, recreate your indexes using the [Reindex]({{site.url}}{{site.baseurl}}/api-reference/document-apis/reindex/) API, and finally upgrade to 2.x. One alternative to reindexing is to reingest data from the origin, such as by replaying a datastream or ingesting data from a database.
JeffHuss marked this conversation as resolved.
Show resolved Hide resolved

### Index compatibility reference

If you plan to retain old indexes after the OpenSearch version upgrade, then you might need to reindex or reingest the data. Refer to the following table for Lucene versions across recent OpenSearch and Elasticsearch releases.

<style>
table {
border-collapse: collapse;
table-layout: fixed;
}
th {
background-color: #F5F7F7;
}
th,
td {
text-align: center;
padding: 0.5em 1em;
}
</style>
<table>
<tr>
<th>Lucene Version</th>
<th>OpenSearch Version</th>
<th>Elasticsearch Version</th>
</tr>
<tr>
<td>9.4.2</td>
<td>2.5.0<br>2.4.1</td>
<td>8.6</td>
</tr>
<tr>
<td>9.4.1</td>
<td>2.4.0</td>
<td>&#8212;</td>
</tr>
<tr>
<td>9.4.0</td>
<td>&#8212;</td>
<td>8.5</td>
</tr>
<tr>
<td>9.3.0</td>
<td>2.3.0<br>2.2.x</td>
<td>8.4</td>
</tr>
<tr>
<td>9.2.0</td>
<td>2.1.0</td>
<td>8.3</td>
</tr>
<tr>
<td>9.1.0</td>
<td>2.0.x</td>
<td>8.2</td>
</tr>
<tr>
<td>9.0.0</td>
<td>&#8212;</td>
<td>8.1<br>8.0</td>
</tr>
<tr>
<td>8.11.1</td>
<td>&#8212;</td>
<td>7.17</td>
</tr>
<tr>
<td>8.10.1</td>
<td>1.3.x<br>1.2.x</td>
<td>7.16</td>
</tr>
<tr>
<td>8.9.0</td>
<td>1.1.0</td>
<td>7.15<br>7.14</td>
</tr>
<tr>
<td>8.8.2</td>
<td>1.0.0</td>
<td>7.13</td>
</tr>
<tr>
<td>8.8.0</td>
<td>&#8212;</td>
<td>7.12</td>
</tr>
<tr>
<td>8.7.0</td>
<td>&#8212;</td>
<td>7.11<br>7.10</td>
</tr>
<tr>
<td>8.6.2</td>
<td>&#8212;</td>
<td>7.9</td>
</tr>
<tr>
<td>8.5.1</td>
<td>&#8212;</td>
<td>7.8<br>7.7</td>
</tr>
<tr>
<td>8.4.0</td>
<td>&#8212;</td>
<td>7.6</td>
</tr>
<tr>
<td>8.3.0</td>
<td>&#8212;</td>
<td>7.5</td>
</tr>
<tr>
<td>8.2.0</td>
<td>&#8212;</td>
<td>7.4</td>
</tr>
<tr>
<td>8.1.0</td>
<td>&#8212;</td>
<td>7.3</td>
</tr>
<tr>
<td>8.0.0</td>
<td>&#8212;</td>
<td>7.2<br>7.1</td>
</tr>
<tr>
<td>7.7.3</td>
<td>&#8212;</td>
<td>6.8</td>
</tr>
</table>
<p style="text-align:right"><sub><em>A dash (&#8212;) indicates that there is no product version containing the specified version of Apache Lucene.</em></sub></p>
Loading