DBeaver can run on major operating systems such as Windows, macOS, and Linux. This topic describes how to use DBeaver on Windows to connect to an AnalyticDB for PostgreSQL instance.
Prerequisites
The internal or public endpoint of an AnalyticDB for PostgreSQL instance is obtained.
If your client is deployed on an Elastic Compute Service (ECS) instance that resides in the same region and uses the same network type as the AnalyticDB for PostgreSQL instance, you can use the internal endpoint to connect to the AnalyticDB for PostgreSQL instance. Log on to the AnalyticDB for PostgreSQL console. In the Database Connection Information section of the Basic Information page, view the internal endpoint of the instance.
If your client is deployed on an ECS instance that resides in a different region or uses a different network type from your AnalyticDB for PostgreSQL instance or a system outside Alibaba Cloud, you must apply for a public endpoint and then use the public endpoint to connect to the AnalyticDB for PostgreSQL instance. For more information about how to apply for a public endpoint, see Manage public endpoints.
The IP address of your client is added to an IP address whitelist of the AnalyticDB for PostgreSQL instance. For more information, see Configure an IP address whitelist.
Procedure
Download and run the installation package of DBeaver Community Edition. To download the package, visit the DBeaver official website.
Start DBeaver and choose
.In the Connect to a database dialog box, select the Greenplum database type and click Next.
NoteThe first time you connect to an instance, you must download the corresponding database driver file.
On the Main tab of the Connection Settings page, configure the parameters that are described in the following table.
Parameter
Description
Example
Host
The endpoint and port number that are used to connect to the AnalyticDB for PostgreSQL instance. To obtain this information, perform the following steps:
Log on to the AnalyticDB for PostgreSQL console.
In the upper-left corner of the console, select the region where the instance resides.
Find the instance that you want to manage and click the instance ID.
In the Database Connection Information section of the Basic Information page, view Internal Endpoint and Internal Port or Public endpoint and Public Port.
gp-bp1g*************-master.gpdbmaster.rds.aliyuncs.com
Port
5432
Database
The name of the database.
postgres
Username
The database account that is used to connect to the AnalyticDB for PostgreSQL instance. For information about how to create an account, see Create a database account.
testuser
Password
The password of the database account.
PassW0rd
Click Test Connection. A Connected message indicates that the connection is established.
NoteIf an error message of
org.postgresql.Driver
is returned, you can perform the following operations to download or update the driver library of Greenplum:On the Main tab of the Connection Settings page, click Edit Driver Settings.
On the Libraries tab, click Download/Update.
Click Finish.