Skip to content

elasticsearch: fix keystore restart notify and non-rolling upgrade - #541

Open
afeefghannam89 wants to merge 4 commits into
mainfrom
elasticsearch
Open

elasticsearch: fix keystore restart notify and non-rolling upgrade#541
afeefghannam89 wants to merge 4 commits into
mainfrom
elasticsearch

Conversation

@afeefghannam89

@afeefghannam89 afeefghannam89 commented Aug 18, 2026

Copy link
Copy Markdown
Member

Two separate bugs in the Elasticsearch upgrade and keystore paths, plus one leftover line.

Keystore credentials never triggered a restart (#540)

The keystore tasks carried changed_when: false, which also kills the notify. Changing a
credential therefore updated the keystore but Elasticsearch kept running with the old value
until some unrelated task happened to restart it.

A version bump upgraded all nodes at once (#546)

Update Elasticsearch if needed was skipped on every host, so raising elasticstack_version
fell through to the plain package: state=present tasks below it and every node was upgraded
and restarted together. Three changes:

  • elasticstack-passwords.yml now persists the fetched elastic password with set_fact
    (__elasticstack_password), so it is in scope no matter which role runs first.
  • elasticstack-versions.yml is no longer imported only for elasticstack_full_stack, so
    package_facts is always gathered and the installed-version comparison also works standalone.
  • The three install tasks are limited to a fresh install
    ('elasticsearch' not in ansible_facts.packages). A version bump can now only take the
    rolling path, and a broken rolling upgrade fails visibly instead of silently upgrading
    everything.

* Use ste_fact with elsticstack password
* fix skspping update task
@afeefghannam89 afeefghannam89 changed the title Elasticsearch elasticsearch: fix keystore restart notify and non-rolling upgrade Aug 24, 2026
@afeefghannam89
afeefghannam89 marked this pull request as ready for review August 24, 2026 08:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant