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

Don't allow indices containing too-old segments to be opened #10215

Closed
clintongormley opened this issue Mar 23, 2015 · 1 comment · Fixed by #11072
Closed

Don't allow indices containing too-old segments to be opened #10215

clintongormley opened this issue Mar 23, 2015 · 1 comment · Fixed by #11072
Assignees
Labels

Comments

@clintongormley
Copy link
Contributor

Elasticsearch 2.x (Lucene 5.x) will support all Lucene 4.x segments, but not Lucene 3.x segments. We should not allow any indices with too-old segments to be opened on cluster restart. These indices should be left in a closed state, and the reason for not opening should be logged.

If the user tries to open the index with the index-open API, they should receive an exception explaining the reason.

We will advise users of 1.x to install the migration advisory plugin #10214 before upgrading to check the age of their segments. The upgrade path in this case will be to install Elasticsearch 1.6 and to run the upgrade API.

If users ignore this advice and go straight to 2.x, then they will be unable to open these indices. At this point, the upgrade path will be to move these indices to a new directory, install 1.6, and use the upgrade API. Once upgraded, they can install 2.0 and rely on the dangling indices function.

@skearns64
Copy link
Contributor

We'll have to be sure to handle the case where some of the shards of a given index have 3.x segments, while other shards contain only 4.x segments. This means we should try to find a way to take/keep the whole index offline, or ensure that the manual process index upgrade process works in this case.

@clintongormley clintongormley assigned s1monw and unassigned martijnvg Apr 8, 2015
@imotov imotov assigned imotov and unassigned s1monw May 4, 2015
imotov added a commit to imotov/elasticsearch that referenced this issue May 8, 2015
When index is introduced into the cluster via cluster upgrade, restore or as a dangled index the MetaDataIndexUpgradeService checks if this index can be upgraded to the current version. If upgrade is not possible, the newly upgraded cluster startup and restore process are aborted, the dangled index is imported as a closed index that cannot be open.

Closes elastic#10215
imotov added a commit to imotov/elasticsearch that referenced this issue May 20, 2015
When index is introduced into the cluster via cluster upgrade, restore or as a dangled index the MetaDataIndexUpgradeService checks if this index can be upgraded to the current version. If upgrade is not possible, the newly upgraded cluster startup and restore process are aborted, the dangled index is imported as a closed index that cannot be open.

Closes elastic#10215
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants