Secure Direct Access
Elementum provides secure, in-place data access to your Databricks Lakebase Postgres database:Authentication
In-Place Access
How It Works
Databricks Side
Elementum Side
What is Lakebase Postgres?
Lakebase Postgres is a fully managed, cloud-native PostgreSQL database within Databricks. Key features:Managed PostgreSQL
Serverless Scaling
Unity Catalog Integration
Standard Postgres
Security Architecture
Data Encryption
- Database encrypted using industry-standard algorithms
- Credentials encrypted and never exposed
- All traffic encrypted using TLS (sslmode=require)
- Secure connection via PostgreSQL protocol
Access Control
- Native PostgreSQL role with password
- No token expiration (persistent connections)
- PostgreSQL role-based permissions
- Managed at the Lakebase instance level
Setting up Elementum Access in Databricks
Prerequisites
Before starting:- Ensure you have Workspace Admin or Account Admin access
- Have access to create Lakebase Postgres instances
Setup Steps Overview
Create Lakebase Postgres Instance
Enable Native Postgres Login
Create Elementum Role
Grant Permissions
Create Platform Schema
Run These Steps in Databricks
Create Lakebase Postgres Instance
- In your Databricks workspace, go to Compute
- Click the Lakebase Postgres tab
- Click Create
- Configure the instance:
- Name:
elementum-lakebase - Instance size (Capacity Unit):
2(adjust based on workload) - Serverless usage policy:
None(or configure as needed)
- Name:
- Click Create
- Wait for the instance to show Status: Available
Enable Native Postgres Login
- On the Lakebase instance page, click Edit in the upper-right
- Turn on Enable Postgres Native Role Login
- Click Save
Get Connection Details
- Click on the instance name (
elementum-lakebase) - Go to the Connection details tab
- Note the Connection parameters:
- host:
instance-<uuid>.database.cloud.databricks.com - dbname:
databricks_postgres(default database) - port:
5432
- host:
instance-<instance-id>.database.cloud.databricks.comCreate Elementum Role with Password
Grant Permissions to Elementum Role
Choose Your Permission Level
- Superuser (Simplest)
- Specific Permissions (Recommended)
Permission Examples
- Full Access (Read/Write)
- Read-Only Access
- Specific Tables Only
Create Platform Schema for Elementum
(Optional) Register Managed Database Catalog
- On the Lakebase instance page, go to the Catalogs tab
- Click Create managed database catalog
- Select the Unity Catalog you want to expose
- This creates a bridge between your Delta tables and the Postgres interface
Configuring CloudLink in Elementum
After completing the Databricks setup, configure the connection in Elementum:Navigate to CloudLink Settings
Enter Connection Details
Test the Connection
- Network connectivity
- PostgreSQL authentication
- Schema access
Configure Data Access
- Select Tables: Choose which tables to expose in Elementum
- Configure Field Mapping: Map columns to Elementum field types
- Set Primary Key: Identify the unique identifier column for each table
- Configure Permissions: Set which users/roles can access the data
Verification and Testing
After completing the setup, verify everything is working:Test Connection via psql
elementum role.Verify Schema Access
Test in Elementum
- Verify the connection shows as Connected in CloudLink settings
- Browse to the integrated tables in Elementum
- Verify data loads correctly
- Test creating/updating a record (if write access was granted)
Troubleshooting
Connection Issues
Connection Issues
- Verify the Lakebase instance is in “Available” status
- Confirm the password is correct
- Check that the Postgres role has been created and granted appropriate permissions
- Verify the hostname is correct (should be
instance-<uuid>.database.cloud.databricks.com)
- Verify the role name and password are correct
- Ensure Enable Postgres Native Role Login is turned on
- Confirm the role was created with
LOGINprivilege
Cannot See Data Tables
Cannot See Data Tables
- Most common cause: You entered your data schema in the Schema field instead of the platform schema
- Verify the Postgres role has the appropriate permissions
- Check that tables exist in the database
- If using managed database catalogs, verify the catalog is registered
Permission Errors
Permission Errors
- Verify the Postgres role has appropriate GRANT permissions
- Check that
databricks_superuseror appropriate roles are granted - For specific table access, verify GRANT statements have been run
Lakebase Instance Issues
Lakebase Instance Issues
- Check if you’ve reached capacity limits
- Verify workspace has Lakebase Postgres enabled
- Contact Databricks support if the instance stays in “Starting” state
- Lakebase instances can scale to zero when idle
- The instance will automatically resume when a connection is made
- First connection after suspension may take a few seconds
Security Best Practices
Principle of Least Privilege
- Grant only necessary PostgreSQL roles
- Use specific table grants instead of superuser where possible
- Regularly audit granted permissions
- Remove unused Postgres roles
Credential Security
- Rotate passwords periodically (recommended: every 90 days)
- Store passwords securely (never in code)
- Use separate Postgres roles for different environments
- Never share credentials outside authorized personnel
Network Security
- Lakebase uses TLS encryption by default (sslmode=require)
- Consider workspace-level IP access controls
- Monitor connection logs regularly
- Set up alerts for suspicious activity
Monitoring
- Review query history via Lakebase Metrics tab
- Monitor compute costs
- Set up cost alerts in Databricks
- Track data access patterns
Next Steps
Configure Apps
Create Automations
Setup AI Features
Data Best Practices
Additional Resources
CloudLink Overview
Databricks Documentation
Get Support
This guide reflects the latest Databricks Lakebase Postgres and Elementum best practices. For additional assistance, contact support@elementum.io.