> ## Documentation Index
> Fetch the complete documentation index at: https://www.integrate.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Amazon RDS PostgreSQL source for ELT & CDC

> Configure Amazon RDS PostgreSQL as a CDC source in Integrate.io ELT & CDC. Enable logical replication and grant the rds_replication role.

This page covers the **Amazon RDS-specific** steps to prepare your PostgreSQL instance for ELT & CDC. After completing them, follow the common setup (sync user grants, heartbeat table, publication, and replication slot) on the [PostgreSQL source for ELT & CDC](/cdc/postgresql) page.

## Requirements

* Amazon RDS for PostgreSQL **version 10 or above**.
* Connect to the **primary** instance. Logical replication only works on the primary.
* Tables with a `PRIMARY KEY`.

## Enable logical replication

<Steps>
  <Step title="Open the AWS RDS dashboard">
    Go to the AWS RDS console.
  </Step>

  <Step title="Create or open a DB parameter group">
    Create a DB parameter group that matches your PostgreSQL version (for example, `postgres12`). Skip this step if you already have one.

    <Frame>
      <img src="https://mintcdn.com/integrateio/SIDFEDRgXpxG0yrn/images/cdc/sources/image-82.png?fit=max&auto=format&n=SIDFEDRgXpxG0yrn&q=85&s=aba2c7ff1e01c8945dc9d2bf843e02a7" alt="Creating a new parameter group for PostgreSQL in AWS RDS console" width="2182" height="1054" data-path="images/cdc/sources/image-82.png" />
    </Frame>
  </Step>

  <Step title="Set rds.logical_replication to 1">
    On the parameter group page, search for `rds.logical_replication`, select the row, click **Edit parameters**, and set the value to `1`.

    <Frame>
      <img src="https://mintcdn.com/integrateio/SIDFEDRgXpxG0yrn/images/cdc/sources/image-83.png?fit=max&auto=format&n=SIDFEDRgXpxG0yrn&q=85&s=61461125a89618aaaef4c80cc690cbd5" alt="Setting rds.logical_replication parameter to 1 in the parameter group" width="2804" height="886" data-path="images/cdc/sources/image-83.png" />
    </Frame>
  </Step>

  <Step title="Apply the parameter group">
    Apply the parameter group to the DB instance.

    <Frame>
      <img src="https://mintcdn.com/integrateio/SIDFEDRgXpxG0yrn/images/cdc/sources/image-84.png?fit=max&auto=format&n=SIDFEDRgXpxG0yrn&q=85&s=851367ef9f53d6b7d2f58ca2904022b3" alt="Applying the parameter group to the RDS PostgreSQL database" width="2278" height="1068" data-path="images/cdc/sources/image-84.png" />
    </Frame>
  </Step>

  <Step title="Reboot the instance">
    Modify the DB instance and wait until its status changes to `pending-reboot`, then reboot it to apply the new parameter group.

    <Frame>
      <img src="https://mintcdn.com/integrateio/SIDFEDRgXpxG0yrn/images/cdc/sources/image-85.png?fit=max&auto=format&n=SIDFEDRgXpxG0yrn&q=85&s=6bc14b0530c93aa50199192dd09621e2" alt="RDS instance in pending-reboot status after parameter group modification" width="1396" height="300" data-path="images/cdc/sources/image-85.png" />
    </Frame>
  </Step>
</Steps>

## Grant the RDS replication role

After creating the sync user (see the [common setup](/cdc/postgresql#setup-steps-customer-managed)), grant the managed RDS replication role instead of `ALTER ROLE ... WITH REPLICATION`:

```sql theme={null}
GRANT rds_replication TO integrateio;
```

## Next: common setup

Continue with the canonical PostgreSQL setup for the remaining steps — sync user privileges (`USAGE`, `SELECT`, `REFERENCES`), heartbeat table, publication, and replication slot:

<Card title="PostgreSQL source for ELT & CDC" icon="arrow-right" href="/cdc/postgresql" horizontal />

<CardGroup cols={2}>
  <Card title="SSH Tunnel" icon="arrow-right" href="/cdc/ssh-tunnel" horizontal />

  <Card title="PostgreSQL PrivateLink" icon="arrow-right" href="/cdc/postgresql-privatelink-set-up" horizontal />
</CardGroup>
