Reset-admin-password returns ERROR no localtoken


#1

Would someone help me understand why I’m getting this error? I’m using Couchbase 5.1.1 CE.

This is the command I’m using:

./couchbase-cli reset-admin-password -c ‘localhost:8091’ --new-password ‘my_password’

This is the error I’m getting:

ERROR: No such file or directory /home/server/opt/couchbase/var/lib/couchbase/localtoken


#2

Hi Hyling,
Thanks for using our product.
I have a question. What Couchbase Server you are running now?
By default, reset password only runs in localhost. So you don’t need to pass ‘localhost’ param.
Here is an example code I ran it in Couchbase Server 6.0.0 Enterprise Edition

./couchbase-cli reset-admin-password --new-password password1
SUCCESS: Administrator password changed
[root@s44015 bin]#

If you still have issue with reset password, drop me a line to thuan at couchbase dot com
Thanks


#3

Thuan,

I emailed you days ago but didn’t get a response so I’m posting here in case you didn’t get my email.:

Thanks for the help. I’m using Couchbase 5.1.1 CE.

I tried the command you suggested and I get the following error:

./couchbase-cli reset-admin-password --new-password password

ERROR: argument -c/–cluster is required


#4

Hi Hyling,
In 5.1.1, reset admin password needs a flag -c/–cluster .
In your command, remove double/single quote around your host and you don’t need to put port number if you use default port (8091). It will reset you password with new password

[root@s44015 ~]# /opt/couchbase/bin/couchbase-cli reset-admin-password -c localhost --new-password password1
SUCCESS: Administrator password changed


#5

Unfortunately using that exact command I’m getting the same error. Can you help me understand the purpose of the “localtoken” file mentioned in the error?

/home/server/opt/couchbase/bin/couchbase-cli reset-admin-password -c localhost --new-password password1

ERROR: No such file or directory /home/server/opt/couchbase/var/lib/couchbase/localtoken


#6

I’m not sure what caused this but I finally reinstalled Couchbase server and the password reset commands now work.