> For the complete documentation index, see [llms.txt](https://lilbobbytables.gitbook.io/mycrt-user-guide/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://lilbobbytables.gitbook.io/mycrt-user-guide/installation/create-an-rds-instance.md).

# Create an RDS Instance

In order for MyCRT to run, it needs its own MySQL database. We will create one hosted on RDS.

## 1: Launch an RDS Instance

From the RDS instance dashboard, click "Launch Instance".

![](https://1572547363-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-L9ux89_cZRZjByEyMgG%2F-LAQtCcuM1dCgdVrrO1A%2F-LAQteVc2cwr25neFTUw%2FScreen%20Shot%202018-04-18%20at%208.15.11%20PM.png?alt=media\&token=90ea59bd-3e24-4d6d-a6f7-fcb17dfcbcf1)

Select MySQL for the engine, select Dev/Test - MySQL for the use case, select mysql 5.7.21, select the db.t2.micro instance class, provide an instance identifier, master username, master password, and click "next". Change "Publicly Accessible" to "No" - this will require your EC2 instance and RDS instance to be in the same VPC. Click "Launch Instance", and your instance will be created!

![](https://1572547363-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-L9ux89_cZRZjByEyMgG%2F-LAQtCcuM1dCgdVrrO1A%2F-LAQuehPKuRdppacnqZG%2FScreen%20Shot%202018-04-18%20at%208.20.06%20PM.png?alt=media\&token=4b4f5009-0225-4f56-82ac-b6617405a371)

Finally, modify the DB security group inbound rules to allow TCP on port 3306 from anywhere.

## 2: Create the MyCRT Tables

Now, we need to initialize the database for MyCRT. This will all be done inside an SSH into the EC2 instance we have set up.

First, we need to make sure that we can access the new RDS instance from our EC2 instance. Run the following command to connect:

```bash
mysql -h YOUR_RDS_INSTANCE_ENDPOINT -u MASTER_USERNAME -p
```

and enter the master password. You should now have a connection. Go ahead and close it for now.

To configure MyCRT to use the database, make the following files:

* `mycrt/scripts/db/config/demo.cnf`

```
[client]
user=MASTER_USERNAME
password=MASTER_PASSWORD

```

* `mycrt/scripts/db/config/demo.config.json`

```javascript
{
    "database": "LBTMyCRT",
    "host": "YOUR_RDS_INSTANCE_HOSTNAME",
    "password": "MASTER_PASSWORD",
    "user": "MASTER_USER"
}

```

Create the MyCRT database by running:&#x20;

```bash
cd mycrt/scripts/db
mysql --defaults-file="config/demo.cnf" -h YOUR_RDS_INSTANCE_HOSTNAME < mycrt.sql
```

There should be no failure.

**Next Step**

{% content-ref url="/pages/-LAR0HFyvnmDR8Btxeps" %}
[Configure and Launch MyCRT](/mycrt-user-guide/installation/configure-mycrt.md)
{% endcontent-ref %}
