Updated on 2022-08-16 GMT+08:00

Obtaining the Cluster Connection Address

Scenario

You can access GaussDB(DWS) clusters by different methods and the connection address of each connection method varies. This section describes how to view and obtain the private network address on the Huawei Cloud platform, public network address on the Internet, and JDBC connection strings.

To obtain the cluster connection address, use either of the following methods:

Obtaining the Cluster Connection Address on the Connections Page

  1. Log in to the GaussDB(DWS) management console.
  2. In the navigation pane on the left, click Connections.
  3. In the Data Warehouse Connection Information area, select an available cluster.

    You can only select clusters in the Available state.

  4. View and obtain the cluster connection information.

    • Private Network Address
    • Public Network Address
    • JDBC URL (Private Network)
    • JDBC URL (Public Network)
    • ODBC URL
    • If no EIP is automatically assigned during cluster creation, Public Network Address is empty. If you want to use a public network address (consisting of an EIP and the database port) to access the cluster from the Internet, click Bind EIP to bind one.
    • If an EIP is bound during cluster creation but you do not want to use the public network address to access the cluster, click Unbind EIP to unbind the EIP. After the EIP is unbound, Public Network Address is empty.

Obtaining the Cluster Access Addresses on the Basic Information Page

  1. Log in to the GaussDB(DWS) management console.
  2. In the navigation tree on the left, click Clusters.
  3. In the cluster list, click the name of the target cluster. The Basic Information page is displayed.
  4. In the Database Attribute area, view and obtain the cluster's access address information, including the private network address and public network address.

    Table 1 Database attribute parameters

    Parameter

    Description

    Default Database

    Database name specified when the cluster is created. When you connect to the cluster for the first time, connect to the default database.

    Initial Administrator

    Database administrator specified during cluster creation. When you connect to the cluster for the first time, you need to use the initial database administrator and password to connect to the default database.

    Port

    Port for accessing the cluster database over the public network or private network. The host port is specified when a cluster is created and used to listen to client connections.

    Connection String

    Connection string. You can click View Details to check the data warehouse connection information. Its value can be:

    • JDBC URL (Private Network). In the private network environment, you can use the JDBC URL (private network) to connect to the cluster when developing applications.
    • JDBC URL (Public Network). In the public network environment, you can use the JDBC URL (public network) to connect to the cluster when developing applications.
    • ODBC URL. In GaussDB(DWS), you can use an ODBC driver to connect to the database. The driver can connect to the database on an ECS or over the Internet.

    Private Network Domain Name

    Name of the domain for accessing the database in the cluster over the private network. The private network domain address is automatically generated when a cluster is created. When you access a data warehouse cluster using a domain name, the domain name resolver provides the load balancing function.

    You can click Modify to change the private network domain name. The access domain name contains 4 to 63 characters, which consists of letters, digits, and hyphens (-), and must start with a letter.

    Private Network IP Address

    IP address for accessing the database in the cluster over the private network.

    NOTE:
    • A private IP address is automatically generated when you create a cluster. The IP address is fixed.
    • The number of private IP addresses equals the number of CNs. You can log in to any node to connect to the cluster.
    • If you access a fixed IP address over the internal network, all the workloads will be processed on a single CN.

    Public Network Domain Name

    Name of the domain for accessing the database in the cluster over the public network.

    Public Network IP Address

    IP address for accessing the database in the cluster over the public network.

    NOTE:
    • If no EIP is assigned during cluster creation and Public Network IP Address is empty, click Bind EIP to bind an EIP to the cluster.
    • If an EIP is bound during cluster creation, click Unbind EIP to unbind the EIP.