In addition to connecting to a POLARDB cluster compatible with Oracle through the ApsaraDB for POLARDB console, you can also connect to the cluster through the pgAdmin 4 client. This topic describes how to use the pgAdmin 4 client to connect to a POLARDB cluster compatible with Oracle.

Prerequisites

  • You have created a privileged or standard account for an existing database cluster. For more information, see Create an account for a POLARDB cluster compatible with Oracle cluster.
  • You have installed pgAdmin 4 in a server that can connect to POLARDB clusters compatible with Oracle such as ECS.
  • POLARDB compatible with Oracle only provides the private endpoint. You must connect to the POLARDB cluster compatible with Oracle by using an ECS instance that is in the same VPC.
  • You must use a Windows-based ECS instance.

Procedure

  1. Start the pgAdmin 4 client.
  2. Right-click Servers and choose Create > Server from the shortcut menu, as shown in the following figure.创建服务器
  3. On the General tab of the Create - Server dialog box, enter the name of the server, as shown in the following figure.输入服务器名称
  4. Click the Connection tab and enter the information of the destination instance, as shown in the following figure.输入实例信息
    Parameters:
    • Hostname or endpoint: the primary endpoint of the POLARDB cluster compatible with Oracle. You can view the endpoint on the Basic Information page in the ApsaraDB for POLARDB console, as shown in the following figure.
      Note Do not include the port number when specifying the endpoint. Example: abc.o.polardb.cn.rds.aliyuncs.com.
    • Port: The port of the POLARDB cluster compatible with Oracle is 1521.
    • Username: the account name of the cluster.
    • Password: the password of the cluster.
  5. Confirm the settings and click Save.
Note

Additionally, you can run commands on clients to connect to a POLARDB cluster compatible with Oracle. For more information about how to download and install the clients, see Download clients and drivers.