Updated on 2022-07-26 GMT+08:00

Using gsql to Connect to DWS

Connecting to DWS Cluster Using gsql

  1. Go to the /opt directory of the ECS and run the environment variables.

    1
    2
    cd /opt
    source gsql_env.sh
    

  2. Run the following command to connect to the GaussDB(DWS) database. Obtain the GaussDB(DWS) private network IP address and the password of user dbadmin from Creating a DWS Data Warehouse.

    1
    gsql -d gaussdb -h  GaussDB(DWS)_private_network_IP_address -U dbadmin -p 8000 -r -W  Password_of_user_dbadmin ;