# Failed to authenticate user \[elastic\] after restart service

**URL:** https://discuss.elastic.co/t/failed-to-authenticate-user-elastic-after-restart-service/128477
**Category:** Elasticsearch
**Created:** [April 18, 2018, 7:51am UTC](https://discuss.elastic.co/t/failed-to-authenticate-user-elastic-after-restart-service/128477 "2018-04-18T07:51:27Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![ashok9177](https://avatars.discourse-cdn.com/v4/letter/a/edb3f5/32.png) [@ashok9177](https://discuss.elastic.co/u/ashok9177)
#### Post date: [April 18, 2018, 7:51am UTC](https://discuss.elastic.co/t/failed-to-authenticate-user-elastic-after-restart-service/128477/1 "2018-04-18T07:51:27Z")

</div>

I have installed x-pack 6.2 , and changed all user passwords with below command

> > bin/x-pack/setup-passwords interactive

then updated user and password in kibana.yml and elasticsearch.yml after some time i restart docker container , then new passwords are not working , i got error message

```
Failed to authenticate user 'elastic' against http://172.17.0.2:9200/_xpack/security/_authenticate?pretty

```

---

<div class="post-metadata">

### Author: ![TimV](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timv/32/13162_2.png) [@TimV](https://discuss.elastic.co/u/TimV)
#### Post date: [April 18, 2018, 8:49am UTC](https://discuss.elastic.co/t/failed-to-authenticate-user-elastic-after-restart-service/128477/2 "2018-04-18T08:49:21Z")

</div>

> [@ashok9177](#):
>
> i got error message

Where did you get that error message?  
That looks like an error message from `setup-passwords`. Are you attempting to run that command a second time? That won't work, it can only be used once.

---

<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: [May 16, 2018, 8:49am UTC](https://discuss.elastic.co/t/failed-to-authenticate-user-elastic-after-restart-service/128477/3 "2018-05-16T08:49:42Z")

</div>

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