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

[DOCS] Alias with the same name as an index can block the upgrade process #28441

Closed
kostasb opened this issue Jan 30, 2018 · 2 comments
Closed
Labels
:Data Management/Indices APIs APIs to create and manage indices and templates >docs General docs changes Team:Data Management Meta label for data/management team won't fix

Comments

@kostasb
Copy link

kostasb commented Jan 30, 2018

Elasticsearch version: upgrading from anything <5.6.3

Description of the problem including expected versus actual behavior:

With versions earlier than 5.6.3 , Elasticsearch could end up with an alias with the same name as an index. For details, refer to #26804

There have been reports of users upgrading Elasticsearch while this condition is in place, which results in the service failing to start after the newer package is installed.

Say there is an alias .name pointing to the index .name-alias , and an index named after .name

Upgrading Elasticsearch to a later version will result to the following error and will abort during boot:

[WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [hostname] uncaught exception in thread [main] org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: index and alias names need to be unique, but the following duplicates were found [.name (alias of [.name-alias/id])]

The master node logs warn about the situation but the issue becomes a major blocker during an upgrade:

[WARN ][o.e.g.LocalAllocateDangledIndices] [esmaster] ignoring dangled index [[.name/id]] on node [{datanode}{id}] due to an existing alias with the same name

One way to get out of this situation, when a data node hits the bootstrap error and shuts down is to locate the physical directory of the problem index on the data path and remove it (purge the index). Not ideal.

This can also manifest when the Reindex Helper in the Kibana Upgrade Assistant (X-Pack 5.6) creates a .security and a .kibana aliases pointing to .security-6 and .kibana-6.

I am unsure which version introduced the abort behavior while booting.

To avoid this, there should be step in docs for the user to verify that there is no such problematic index-alias naming overlap when upgrading from <5.6.3 to a new version.

Especially for the 5.6 to 6.x upgrade it would be good to recommend upgrading only from the latest minor 5.6.x version to 6+

@kostasb kostasb added the >docs General docs changes label Jan 30, 2018
@debadair debadair self-assigned this Mar 28, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra

@colings86 colings86 added the :Data Management/Indices APIs APIs to create and manage indices and templates label Apr 24, 2018
@debadair
Copy link
Contributor

[doc-issue-triage]

5.6 is EOL, but leaving this open because it's related to helping people upgrade to a supported version.

@rjernst rjernst added Team:Data Management Meta label for data/management team Team:Docs Meta label for docs team labels May 4, 2020
@debadair debadair removed their assignment Apr 26, 2022
@debadair debadair added won't fix and removed Team:Docs Meta label for docs team labels Apr 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Data Management/Indices APIs APIs to create and manage indices and templates >docs General docs changes Team:Data Management Meta label for data/management team won't fix
Projects
None yet
Development

No branches or pull requests

5 participants