# ERR: unable to parse authentication credentials

**URL:** <https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974>\
**Category:** Systems\
**Created:** [March 12, 2019, 10:08am UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974 "2019-03-12T10:08:59Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![BaptisteMagous](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/baptistemagous/32/2656_2.png) [@BaptisteMagous](https://community.influxdata.com/u/BaptisteMagous)\
**Post date:** [March 12, 2019, 10:08am UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974/1 "2019-03-12T10:08:59Z")

</div>

Hi,

I tried to install influxDB using Digital Ocean.  
I started influx CLI using:

> influx

following lines appeared:

> Connected to [http://localhost:8086](http://localhost:8086) version 1.7.2  
> InfluxDB shell version: 1.7.2  
> Enter an InfluxQL query

Then I wanted to create a database using following command:

> CREATE DATABASE myDB

But I got this error:

_ERR: unable to parse authentication credentials_  
_Warning: It is possible this error is due to not setting a database._  
_Please set a database with the command “use \<database\>”._

I search on internet what was going on. All was about being logged with permission (correct me if i’m wrong)

I found this interesting post [Authentication doesn't work in 0.11 · Issue #5792 · influxdata/influxdb · GitHub](https://github.com/influxdata/influxdb/issues/5792) where someone managed to solve the error.

> influx -username admin -password test

but… I never created any user for influx. I tried

> create user admin with password ‘test’ with all privileges

Error again ☹

Since the post is closed, I have to create a new one.

I’m stuck and i don’t know if I have to contact Digital Ocean support or someone here can help me.

Thanks for reading,  
Baptiste

---

<div class="post-metadata">

**Author:** ![philb](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/philb/32/1805_2.png) [@philb](https://community.influxdata.com/u/philb)\
**Post date:** [March 12, 2019, 2:39pm UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974/2 "2019-03-12T14:39:34Z")

</div>

Hi,

Did yo try wrapping the username in double quotes?

`create user "admin" with password ‘test’ with all privileges`

I’ve just tried your version and i think the single quotes could be a problem also. `‘test’` the single quotes look formatted, you should try `'password'`

So,

`create user "admin" with password 'test' with all privileges`

That should definitely work, if you don’t get any error message then you can check with `show users` to confirm if the account was created.

---

<div class="post-metadata">

**Author:** ![MarcV](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/marcv/32/7676_2.png) [@MarcV](https://community.influxdata.com/u/MarcV)\
**Post date:** [March 12, 2019, 4:47pm UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974/3 "2019-03-12T16:47:00Z")

</div>

Hi , what is the outcome of

```
 influxd config|grep -i auth

```

auth-enabled should be false …

---

<div class="post-metadata">

**Author:** ![BaptisteMagous](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/baptistemagous/32/2656_2.png) [@BaptisteMagous](https://community.influxdata.com/u/BaptisteMagous)\
**Post date:** [March 19, 2019, 1:18pm UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974/4 "2019-03-19T13:18:50Z")

</div>

Thank you for your reply 🙂

Whatever I type, it always end up  
\_ _ERR: unable to parse authentication credentials_  
_Warning: It is possible this error is due to not setting a database._  
_Please set a database with the command “use \<database\>”._\_

I tried `create user "admin" with password 'test' with all privileges` using any possible quote.

I will try to contact Digital Ocean Support to see what they can do ☹

Have a good day,  
Baptiste

P.S. Digital Ocean console is so amazing I can’t type | in (letters work fine but anythings that is not a number or a letter is either missing or in the wrong place). Sadly, I have to way to execute `influxd config|grep -i auth`

BTW : `show users` return me a user. His name is _ERR: unable to parse authentication credentials_  
_Warning: It is possible this error is due to not setting a database._  
_Please set a database with the command “use \<database\>”._ 😄

---

<div class="post-metadata">

**Author:** ![Seth1u](https://avatars.discourse-cdn.com/v4/letter/s/278dde/32.png) [@Seth1u](https://community.influxdata.com/u/Seth1u)\
**Post date:** [October 15, 2019, 4:10pm UTC](https://community.influxdata.com/t/err-unable-to-parse-authentication-credentials/8974/5 "2019-10-15T16:10:28Z")

</div>

Hello, I made some changes that worked.

First 🕵️‍♂️

auth-enabled = true

# The default realm sent back when issuing a basic auth challenge.

# realm = “InfluxDB”

# Determines whether HTTP request logging is enabled.

log-enabled = true

[monitor]

# Whether to record statistics internally.

store-enabled = true

# The destination database for recorded statistics

store-database = “\_internal”

# The interval at which to record statistics

store-interval = “20s”

Restart service of influxdb : systemctl restart influxdb

localman@app: ~ # influx  
Connected to [http://localhost:8086](http://localhost:8086) version 1.7.8  
InfluxDB shell version: 1.7.8

> CREATE USER “adm” WITH PASSWORD ‘administrator’ WITH ALL PRIVILEGES  
> exit  
> Restart service of influxdb

now reconnect with this user and password

> auth adm administrator  
> show users  
> user admin

* * *

adm true

> show databases  
> name: databases  
> name

* * *

\_internal

Best regards 😉
