Yandex Cloud
Search
Contact UsTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Yandex MPP Analytics for PostgreSQL
  • Getting started
    • All guides
      • Pre-configuration
      • FQDNs of hosts
      • Connecting from applications
      • Code examples
    • Connecting to an external file server (gpfdist)
    • Auxiliary utilities
  • Access management
  • Pricing policy
  • Terraform reference
  • Monitoring metrics
  • Audit Trails events
  • Public materials
  • Release notes

In this article:

  • Command line tools
  • Linux (Bash)
  • Windows (PowerShell)
  • Connecting with IAM authentication
  • Connecting from graphical IDEs
  • Connecting from pgAdmin 4
  • Before you connect from a Docker container
  1. Step-by-step guides
  2. Connection
  3. Connecting from applications

Connecting to an Greenplum® cluster from applications

Written by
Yandex Cloud
Updated at March 5, 2026
  • Command line tools
    • Linux (Bash)
    • Windows (PowerShell)
    • Connecting with IAM authentication
  • Connecting from graphical IDEs
  • Connecting from pgAdmin 4
  • Before you connect from a Docker container

This section provides settings for connecting to Yandex MPP Analytics for PostgreSQL cluster hosts using command line tools, graphical IDEs, pgAdmin 4, or a Docker container. To learn how to connect from your application code, see Code examples.

Creating a Greenplum® cluster does not entail creating a user database. To test the connection, use the postgres service database.

To connect to a publicly accessible cluster, prepare an SSL certificate. In these examples, the root.crt SSL certificate is located in the following directory:

  • /home/<home_directory>/.postgresql/ for Ubuntu.
  • $HOME\AppData\Roaming\postgresql for Windows.

You can connect to a cluster using either a master host's regular FQDN or a primary master host's special FQDN. To learn how to get a host's FQDN, see this guide.

Command line toolsCommand line tools

To see code examples with the host FQDN filled in, open the cluster page in the management console and click Connect.

Linux (Bash)Linux (Bash)

Before connecting, install the required dependencies:

sudo apt update && sudo apt install --yes postgresql-client

Connect to a database:

Connecting without SSL
Connecting with SSL
psql "host=c-<cluster_ID>.rw.mdb.yandexcloud.net \
      port=6432 \
      sslmode=disable \
      dbname=postgres \
      user=<username> \
      target_session_attrs=read-write"
psql "host=c-<cluster_ID>.rw.mdb.yandexcloud.net \
      port=6432 \
      sslmode=verify-full \
      dbname=postgres \
      user=<username> \
      target_session_attrs=read-write"

After you run this command, enter the user password to complete the connection procedure.

To check the connection, run the following query:

SELECT version();

Windows (PowerShell)Windows (PowerShell)

Before connecting, install the current version of PostgreSQL for Windows. Install only the Command Line Tools.

Connect to a database:

Connecting without SSL
Connecting with SSL
& "C:\Program Files\PostgreSQL\<version>\bin\psql.exe" "`
    host=c-<cluster_ID>.rw.mdb.yandexcloud.net `
    port=6432 `
    sslmode=disable `
    dbname=postgres `
    user=<username>"
& "C:\Program Files\PostgreSQL\<version>\bin\psql.exe" "`
    host=c-<cluster_ID>.rw.mdb.yandexcloud.net `
    port=6432 `
    sslmode=verify-full `
    dbname=postgres `
    user=<username>"

After you run this command, enter the user password to complete the connection procedure.

To check the connection, run the following query:

SELECT version();

Connecting with IAM authenticationConnecting with IAM authentication

You can connect to a Greenplum® database from the Yandex Cloud CLI using IAM authentication. To do this, associate a Yandex account or federated account with the Greenplum® user. You can only use IAM authentication to connect to a public cluster, in which case you do not need an SSL certificate.

Before connecting, install the PostgreSQL client:

sudo apt update && sudo apt install --yes postgresql-client

Set up your Yandex MPP Analytics for PostgreSQL cluster for connection:

Management console
  1. Go to Yandex MPP Analytics for PostgreSQL.

  2. Click the cluster name.

  3. Enable public access to the cluster.

  4. Assign a role to the user account connecting to the database:

    1. Select the Access bindings tab and click Assign roles.
    2. Enter the user account’s email.
    3. Click Add role and select the managed-greenplum.clusters.connector role.
    4. Click Save.
  5. Create a Greenplum® user and grant them access to the database:

    1. Connect to the Yandex MPP Analytics for PostgreSQL cluster using any method of your choice.

    2. Create a Greenplum® user, specifying their account’s email as their username.

      CREATE ROLE "<account_email>"
          LOGIN
          ENCRYPTED PASSWORD '<password>';
      
    3. If required, configure privileges and attributes of the Greenplum® user you created.

  6. Add the authentication rule for the user you created:

    1. Select the User authentication tab.

    2. Click Edit rules.

    3. Click  Add rule and specify its settings:

      • Type: Interconnect type.
      • Database: Database name.
      • User: User account's email.
      • Address (CIDR/FQDN): IP range to connect to the database from.
      • Method: iam.
    4. Click Save.

To connect to the Greenplum® database, run this command:

yc managed-greenplum connect <cluster_name_or_ID> --db <DB_name>

Connecting from graphical IDEsConnecting from graphical IDEs

Connections were tested in the following environment:

  • Ubuntu 20.04, DBeaver: 22.2.4
  • MacOS Monterey 12.7:
    • JetBrains DataGrip: 2023.3.4
    • DBeaver Community: 24.0.0

You can only use graphical IDEs to connect to a public cluster using SSL certificates.

To avoid connection errors, save the certificate to a local folder that does not require administrator rights to access.

DataGrip
DBeaver
  1. Create a data source:

    1. Select File → New → Data Source → Greenplum®.

    2. On the General tab:

      1. Configure the connection as follows:

        • User, Password: DB user name and password.

        • URL: Connection string. Use the special primary master FQDN:

          jdbc:postgresql://c-<cluster_ID>.rw.mdb.yandexcloud.net:6432/<DB_name>
          
      2. Click Download to download the connection driver.

    3. On the SSH/SSL tab:

      1. Enable Use SSL.
      2. In the CA file field, specify the path to the SSL certificate for your connection.
  2. Click Test Connection. If the connection is successful, you will see the connection status and information about the DBMS and driver.

  3. Click OK to save the data source.

  1. Create a new DB connection:
    1. In the Database menu, select New connection.
    2. Select Greenplum® from the DB list.
    3. Click Next.
    4. Specify the connection settings on the Main tab:
      • Host: Special FQDN of the primary master, c-<cluster_ID>.rw.mdb.yandexcloud.net.
      • Port: 6432.
      • Database: DB to connect to.
      • Under Authentication, specify the DB user name and password.
    5. On the SSL tab:
      1. Enable Use SSL.
      2. In the Root certificate field, specify the path to the saved SSL certificate file.
  2. Click Test Connection .... If the connection is successful, you will see the connection status and information about the DBMS and driver.
  3. Click Done to save the database connection settings.

Connecting from pgAdmin 4Connecting from pgAdmin 4

The connection has been checked for pgAdmin 4 ver. 7.1 on macOS Ventura 13.0 and Microsoft Windows 10 Pro 21H1.

You can only use pgAdmin 4 to connect to public cluster hosts using an SSL certificate.

Create a new server connection:

  1. Select Object → Register → Server....

  2. On the General tab, in the Name field, specify the cluster name to be shown in the pgAdmin 4 interface. You can set any name.

  3. In the Connection tab, specify the connection settings:

    • Host name/address: Special master host FQDN or regular host FQDN.
    • Port: 6432.
    • Maintenance database: Name of the postgres maintenance database.
    • Username: Username for connection.
    • Password: User password.
  4. In the Parameters tab:

    • Set the SSL mode parameter to verify-full.
    • Add a new Root certificate parameter and specify the path to the saved SSL certificate file in it.
  5. Click Save to save the server connection settings.

As a result, the cluster appears in the server list in the navigation menu.

To monitor the cluster status, use Yandex Monitoring rather than the Dashboard tab in pgAdmin 4, since the latter might generate an error:

column "wait_event_type" does not exist LINE 10: wait_event_type || ': ' || wait_event AS wait_event, ^

This error does not occur in other pgAdmin 4 tabs.

Before you connect from a Docker containerBefore you connect from a Docker container

To connect to a Greenplum® cluster from a Docker container, add the following lines to the Dockerfile:

Connecting without SSL
Connecting with SSL
RUN apt-get update && \
    apt-get install postgresql-client --yes
RUN apt-get update && \
    apt-get install wget postgresql-client --yes && \
    mkdir --parents ~/.postgresql && \
    wget "https://storage.yandexcloud.net/cloud-certs/CA.pem" \
         --output-document ~/.postgresql/root.crt && \
    chmod 0655 ~/.postgresql/root.crt

Greenplum® and Greenplum Database® are registered trademarks or trademarks of Broadcom Inc. in the United States and/or other countries.

Was the article helpful?

Previous
FQDNs of hosts
Next
Code examples
© 2026 Direct Cursus Technology L.L.C.