# Dream Factory MySQL database error

**URL:** <https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730>\
**Category:** Connecting to SQL\
**Created:** [December 9, 2018, 6:31am UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730 "2018-12-09T06:31:26Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![volga629](https://avatars.discourse-cdn.com/v4/letter/v/94ad74/32.png) [@volga629](https://community.dreamfactory.com/u/volga629)\
**Post date:** [December 9, 2018, 6:31am UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/1 "2018-12-09T06:31:26Z")

</div>

Hello Everyone,  
Kubernetes deployed Dream Factory any operation include log in getting errors.  
Used docker image

[https://hub.docker.com/r/dreamfactorysoftware/df-docker/](https://hub.docker.com/r/dreamfactorysoftware/df-docker/)

If I am looking into correct place database.php contain only default configuration.

```
   SQLSTATE[HY000] [1045] Access denied for user 'bn_dreamfactory'@'10.244.1.40' (using password: YES) (SQL: select * from `app` where `api_key` = 6498a8ad1beb9d84d63035c5d1120c007fad6de706734db9689f8996707e0f7d limit 1)

```

Any help thank you

---

<div class="post-metadata">

**Author:** ![Kevin\_Mcgahey](https://avatars.discourse-cdn.com/v4/letter/k/b3f665/32.png) [@Kevin\_Mcgahey](https://community.dreamfactory.com/u/Kevin_Mcgahey)\
**Post date:** [December 10, 2018, 4:46pm UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/2 "2018-12-10T16:46:29Z")

</div>

Hi @volga629,

The error seems to be showing that you have the wrong credentials to login to the DB. Could you double check your password please?

Best,  
Kevin

---

<div class="post-metadata">

**Author:** ![volga629](https://avatars.discourse-cdn.com/v4/letter/v/94ad74/32.png) [@volga629](https://community.dreamfactory.com/u/volga629)\
**Post date:** [December 10, 2018, 5:02pm UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/3 "2018-12-10T17:02:59Z")

</div>

Hello Kevin,  
Thank you for reply which file is stored correct credentials. I tried set from .env file, but didn’t helped.

Here are current db grants

```
MariaDB [bitnami_dreamfactory_lURL6]> show grants for 'bn_dreamfactory';

```

±---------------------------------------------------------------------------------------------------------------+  
| Grants for bn\_dreamfactory@% |  
±---------------------------------------------------------------------------------------------------------------+  
| GRANT USAGE ON _._ TO ‘bn\_dreamfactory’@’%’ IDENTIFIED BY PASSWORD ‘_’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory_NMfOy`._ TO ‘bn\_dreamfactory’@’%’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory_lURL6`.\* TO ‘bn\_dreamfactory’@’%’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory_SU18B`.\* TO ‘bn\_dreamfactory’@’%’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory_v7Ccu`.\* TO ‘bn\_dreamfactory’@’%’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory_BiY9X`.\* TO ‘bn\_dreamfactory’@’%’ |  
| GRANT ALL PRIVILEGES ON `bitnami_dreamfactory`.\* TO ‘bn\_dreamfactory’@’%’ |  
±---------------------------------------------------------------------------------------------------------------+  
7 rows in set (0.00 sec)

---

<div class="post-metadata">

**Author:** ![Kevin\_Mcgahey](https://avatars.discourse-cdn.com/v4/letter/k/b3f665/32.png) [@Kevin\_Mcgahey](https://community.dreamfactory.com/u/Kevin_Mcgahey)\
**Post date:** [December 10, 2018, 5:17pm UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/4 "2018-12-10T17:17:00Z")

</div>

One solution is accessing phpmyadmin and checking the credentials/resetting them. If you are unable to access phpmyadmin you can create a new instance, as I see you are using Bitnami, it should be quick and easy.

---

<div class="post-metadata">

**Author:** ![volga629](https://avatars.discourse-cdn.com/v4/letter/v/94ad74/32.png) [@volga629](https://community.dreamfactory.com/u/volga629)\
**Post date:** [December 10, 2018, 8:38pm UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/5 "2018-12-10T20:38:09Z")

</div>

What configuration file of dream factory store mysql credentials ?

---

<div class="post-metadata">

**Author:** ![Kevin\_Mcgahey](https://avatars.discourse-cdn.com/v4/letter/k/b3f665/32.png) [@Kevin\_Mcgahey](https://community.dreamfactory.com/u/Kevin_Mcgahey)\
**Post date:** [December 10, 2018, 9:02pm UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/6 "2018-12-10T21:02:10Z")

</div>

It can be found in your .env file.

---

<div class="post-metadata">

**Author:** ![volga629](https://avatars.discourse-cdn.com/v4/letter/v/94ad74/32.png) [@volga629](https://community.dreamfactory.com/u/volga629)\
**Post date:** [December 14, 2018, 4:27am UTC](https://community.dreamfactory.com/t/dream-factory-mysql-database-error/4730/7 "2018-12-14T04:27:15Z")

</div>

Hello Kevin,  
Sorry for delay. I was investigating the issue and found that all 3 pods are using same user name credentials to connect mysql that cause a conflict. As soon I scale down to one and corrected permissions on mysql everything is connects no problem.

thank you for you help
