Getting started with Managed Service for PostgreSQL

    Before creating a database cluster:

    1. If you already have a folder in Yandex.Cloud, open the page of that folder in the management console. If there is no folder yet, create one:

      1. In the management console, click Create folder.

      2. Enter the folder name.

        The name may contain lowercase Latin letters, numbers, and hyphens. The first character must be a letter. The last character can't be a hyphen. The length of the name must be from 3 to 63 characters.

      3. Click Create folder.

    2. Create a VM (based on Linux or Windows) that you will use for accessing the DB cluster. If you plan to connect to the database from outside the Cloud, request external IP addresses for hosts when creating a cluster.

    Follow the instructions below to quickly create a cluster and test your connection to it.

    1. In the management console, select the folder where you want to create a DB cluster.

    2. Click Managed Service for PostgreSQL.

    3. Click Create cluster and select the necessary DBMS.

    4. Set the cluster parameters and click Create cluster. The process is described in detail in the section Creating a PostgreSQL cluster.

    5. When the cluster is ready to operate, its status on the Managed Service for PostgreSQL dashboard will change to RUNNING.

    6. To connect to the DB server, an SSL certificate is required. You can prepare all the necessary authentication data as follows:

      $ mkdir ~/.postgresql
      $ wget "" -O ~/.postgresql/root.crt
      $ chmod 0600 ~/.postgresql/root.crt
    7. You can connect to the database using the psql command (for more information, see Connecting to a database in a cluster PostgreSQL):

      $ psql "host=<host address> \
            port=6432 \
            sslmode=verify-full \
            dbname=<DB name> \
            user=<DB user name>"