# Temporal mysql db usage

**URL:** <https://community.temporal.io/t/temporal-mysql-db-usage/5049>\
**Category:** Community Support\
**Tags:** mysql\
**Created:** [June 24, 2022, 5:31am UTC](https://community.temporal.io/t/temporal-mysql-db-usage/5049 "2022-06-24T05:31:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![pradnya.bhalekar](https://avatars.discourse-cdn.com/v4/letter/p/f4b2a3/32.png) [@pradnya.bhalekar](https://community.temporal.io/u/pradnya.bhalekar)\
**Post date:** [June 24, 2022, 5:31am UTC](https://community.temporal.io/t/temporal-mysql-db-usage/5049/1 "2022-06-24T05:31:07Z")

</div>

i am trying to connect to external aws mysql rds:

environment:  
- DB=mysql  
- DB\_PORT=3327  
- MYSQL\_USER=temporal  
- MYSQL\_PWD=  
- MYSQL\_SEEDS=  
- DYNAMIC\_CONFIG\_FILE\_PATH=config/dynamicconfig/development.yaml  
- SKIP\_DB\_CREATE=false

Here , the db “temporal” is already created and user “temporal” has access on the db “temporal”

on docker-compose up, i get the error:

temporal | + temporal-sql-tool --ep -u temporal create --db temporal  
temporal | 2022-06-24T05:25:30.400Z ERROR Unable to create SQL database. {“error”: “dial tcp 172.26.22.202:3306: connect: connection refused”, “logging-call-at”: “handler.go:98”}

How do i skip the db creation process?

---

<div class="post-metadata">

**Author:** ![pradnya.bhalekar](https://avatars.discourse-cdn.com/v4/letter/p/f4b2a3/32.png) [@pradnya.bhalekar](https://community.temporal.io/u/pradnya.bhalekar)\
**Post date:** [June 24, 2022, 8:11am UTC](https://community.temporal.io/t/temporal-mysql-db-usage/5049/4 "2022-06-24T08:11:55Z")

</div>

only 2 tables are getting created on running the command:

docker run --entrypoint “/usr/local/bin/temporal-sql-tool” temporalio/admin-tools:1.15.0 -ep -p 3327 -u temporal --pw pwd --db temporal setup-schema -v 1.7

the tables getting created are:

schema\_update\_history  
schema\_version

but, i suppose more tables are required for te setup to run, on docker-compose up i get the error:

: Table ‘temporal.cluster\_metadata\_info’ doesn’t exist

---

<div class="post-metadata">

**Author:** ![tihomir](https://sea2.discourse-cdn.com/flex016/user_avatar/community.temporal.io/tihomir/32/6580_2.png) [@tihomir](https://community.temporal.io/u/tihomir)\
**Post date:** [June 24, 2022, 7:02pm UTC](https://community.temporal.io/t/temporal-mysql-db-usage/5049/6 "2022-06-24T19:02:27Z")

</div>

You can see the sql tool commands auto-setup image runs [here](https://github.com/temporalio/docker-builds/blob/main/docker/auto-setup.sh#L170).  
If you are skipping db creation, see the two create commands the script skips that should be run before starting cluster

hope this helps.
