# Unable to update the password of elastic user

**URL:** <https://discuss.elastic.co/t/unable-to-update-the-password-of-elastic-user/325422>\
**Category:** Elasticsearch\
**Created:** [February 13, 2023, 9:04pm UTC](https://discuss.elastic.co/t/unable-to-update-the-password-of-elastic-user/325422 "2023-02-13T21:04:42Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![quynhdn](https://avatars.discourse-cdn.com/v4/letter/q/8dc957/32.png) [@quynhdn](https://discuss.elastic.co/u/quynhdn)\
**Post date:** [February 13, 2023, 9:04pm UTC](https://discuss.elastic.co/t/unable-to-update-the-password-of-elastic-user/325422/1 "2023-02-13T21:04:42Z")

</div>

I want to rotate the password of elastic user. I used this utility: `bin/elasticsearch-users passwd elastic -p XXXXX`  
It didn’t give any error, but when I tried to use the new password, it didn’t work. The old password continues to work.  
Restarting the pods didn’t help either.

---

<div class="post-metadata">

**Author:** ![Wave](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wave/32/117242_2.png) [@Wave](https://discuss.elastic.co/u/Wave)\
**Post date:** [February 14, 2023, 3:19am UTC](https://discuss.elastic.co/t/unable-to-update-the-password-of-elastic-user/325422/2 "2023-02-14T03:19:29Z")

</div>

Instead try:

```auto
bin/elasticsearch-reset-password -u elastic

```

bin/elasticsearch-users will change passwords but on a node by node basis, and all nodes must have the same changes for them to go into effect. See [documentation](https://www.elastic.co/guide/en/elasticsearch/reference/current/users-command.html#_description_13) for more details. Especially the part about [file based authentication](https://www.elastic.co/guide/en/elasticsearch/reference/current/file-realm.html).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 14, 2023, 3:19am UTC](https://discuss.elastic.co/t/unable-to-update-the-password-of-elastic-user/325422/3 "2023-03-14T03:19:55Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
