Configure Redshift Integration
This page illustrates how to configure the Redshift integration in Immuta. For an overview of the integration, see the Redshift Overview documentation.
For instructions on configuring Redshift Spectrum, see the Redshift Spectrum section.
Redshift Multi-Database Integration
Prerequisites
- A Redshift cluster with an RA3 node is required for the multi-database integration. You must use a Redshift RA3 instance type because Immuta requires cross-database views, which are only supported in Redshift RA3 instance types. For other instance types, you may configure a single-database integration using one of the Redshift Spectrum tutorials below.
- For automated installations, the credentials provided must be a Superuser or have the ability to create databases and users and modify grants.
- The
enable_case_sensitive_identifier
parameter must be set tofalse
(default setting) for your Redshift cluster.
Add the Integration
- Click the App Settings icon in the left sidebar.
- Click Native Integrations in the left panel.
- Click the +Add Native Integration button and select Redshift from the dropdown menu.
- Complete the Host and Port fields.
- Enter an Immuta Database. This is a new database where all secure schemas and Immuta created views will be stored.
-
Opt to check the Enable Impersonation box and customize the Impersonation Role name as needed. This will allow users to natively impersonate another user.
-
Set up the connection Automatically or Manually.
Immuta requires temporary, one-time use of credentials with specific privileges.
When performing an automated installation, Immuta requires temporary, one-time use of credentials with the following privileges:
CREATE DATABASE
CREATE USER
REVOKE ALL PRIVILEGES ON DATABASE
GRANT TEMP ON DATABASE
MANAGE GRANTS ON ACCOUNT
These privileges will be used to create and configure a new IMMUTA database within the specified Redshift instance. The credentials are not stored or saved by Immuta, and Immuta doesn’t retain access to them after initial setup is complete.
You can create a new account for Immuta to use that has these privileges, or you can grant temporary use of a pre-existing account. By default, the pre-existing account with appropriate privileges is a Superuser. If you create a new account, it can be deleted after initial setup is complete.
Alternatively, you can create the IMMUTA database within the specified Redshift instance manually using the Manual Setup option.
- Select Automatic.
- Enter an Initial Database from your Redshift integration for Immuta to use to connect.
-
Use the dropdown menu to select your Authentication Method.
- Username and Password: Enter the Username and Password of the privileged user.
- AWS Access Key: Enter the Database User, Access Key ID, and Secret Key. Opt to enter in the Session Token.
Required Privileges
The specified role used to run the bootstrap needs to have the following privileges:
CREATE DATABASE
CREATE USER
REVOKE ALL PRIVILEGES ON DATABASE
GRANT TEMP ON DATABASE
MANAGE GRANTS ON ACCOUNT
- Select Manual and download both of the bootstrap scripts.
- Run the bootstrap script (initial database) in the Redshift initial database.
- Run the bootstrap script (Immuta database) in the new Immuta Database in Redshift.
- Choose your authentication method, and enter the information of the newly created account.
-
Click Test Redshift Connection.
-
Once the credentials are successfully tested, click Save.
-
Click Confirm.
Redshift Spectrum
Allow Immuta to create secure views of your external tables through one of these methods:
- configure the integration with an existing database that contains the external tables:
Instead of creating
an
immuta
database that manages all schemas and views created when Redshift data is registered in Immuta, the integration adds the Immuta-managed schemas and views to an existing database in Redshift - configure the integration by creating a new
immuta
database and re-create all of your external tables in that database.
For an overview of the integration, see the Redshift Overview documentation.
Prerequisites
- a Redshift cluster with an AWS row-level security patch applied. Contact Immuta for guidance.
- an AWS IAM role for Redshift that is associated with your Redshift cluster.
- The
enable_case_sensitive_identifier
parameter must be set tofalse
(default setting) for your Redshift cluster. -
the Redshift role used to run the Immuta bootstrap script must have the following privileges when configuring the integration to
- use an existing database:
ALL PRIVILEGES ON DATABASE
for the database you configure the integration with, as you must manage grants on that database.CREATE USER
GRANT TEMP ON DATABASE
- create a new database:
CREATE DATABASE
CREATE USER
GRANT TEMP ON DATABASE
REVOKE ALL PRIVILEGES ON DATABASE
- use an existing database:
-
a Redshift database that contains an external schema and external tables.
Use an Existing Database
- Click the App Settings icon in the left sidebar.
- Click Native Integrations in the left panel.
- Click the +Add Native Integration button and select Redshift from the dropdown menu.
- Complete the Host and Port fields.
- Enter the name of the database you created the external schema in as the Immuta Database. This database will store all secure schemas and Immuta-created views.
-
Opt to check the Enable Impersonation box and customize the Impersonation Role name as needed. This will allow users to natively impersonate another user.
-
Select Manual and download both of the bootstrap scripts. The specified role used to run the bootstrap needs to have the following privileges:
ALL PRIVILEGES ON DATABASE
for the database you configure the integration with, as you must manage grants on that database.CREATE USER
GRANT TEMP ON DATABASE
-
Run the bootstrap script (Immuta database) in the Redshift database that contains the external schema.
-
Choose your authentication method, and enter the credentials from the bootstrap script for the
Immuta_System_Account
. -
Click Test Redshift Connection.
-
Once the credentials are successfully tested, click Save and Confirm.
Create a New Immuta Database
- Click the App Settings icon in the left sidebar.
- Click Native Integrations in the left panel.
- Click the +Add Native Integration button and select Redshift from the dropdown menu.
- Complete the Host and Port fields.
- Enter an Immuta Database. This is a new database where all secure schemas and Immuta created views will be stored.
- Opt to check the Enable Impersonation box and customize the Impersonation Role name as needed. This will allow users to natively impersonate another user.
-
Select Manual and download both of the bootstrap scripts. The specified role used to run the bootstrap needs to have the following privileges:
ALL PRIVILEGES ON DATABASE
for the database you configure the integration with, as you must manage grants on that database.CREATE DATABASE
CREATE USER
GRANT TEMP ON DATABASE
-
Run the bootstrap script (initial database) in the Redshift initial database.
- Run the bootstrap script (Immuta database) in the new Immuta Database in Redshift.
- Choose your authentication method, and enter the credentials from the bootstrap script for the
Immuta_System_Account
. - Click Test Redshift Connection.
- Once the credentials are successfully tested, click Save and Confirm.
Then, add your external tables to the Immuta database.
Edit a Redshift Integration
- Click the App Settings icon in the left sidebar.
- Navigate to the Native Integrations section and click the down arrow next to the Redshift Integration.
- Edit the field you want to change. Note any field shadowed is not editable, and the integration must be disabled and re-installed to change it.
-
Enter Username and Password.
Immuta requires temporary, one-time use of credentials with specific permissions.
When performing edits to an integration, Immuta requires temporary, one-time use of credentials of a Superuser or a user with the following permissions:
- Create Databases
- Create users
- Modify grants
Alternatively, you can download the Edit Script and run it in Redshift.
-
Click Validate Credentials.
- Click Save.
- Click Confirm.
Remove a Redshift Integration
Redshift Spectrum
Disabling the Redshift integration is not supported when you set the fields nativeWorkspaceName
, nativeViewName
,
and nativeSchemaName
to
create Redshift Spectrum data sources.
Disabling the integration when these fields are used in metadata ingestion causes undefined behavior.
- Click the App Settings icon in the left sidebar.
- Navigate to the Native Integrations section and click the down arrow next to the Redshift Integration.
- Click the checkbox to disable the integration.
- Enter the username and password that were used to initially configure the integration and click Validate Credentials.
- Click Save.
- Click Confirm.