Help Center/ Data Warehouse Service/ Troubleshooting/ Database Connections/ What Do I Do If gsql: command not found Is Displayed When I Run gsql to Connect to the Database?
Updated on 2025-04-10 GMT+08:00
What Do I Do If gsql: command not found Is Displayed When I Run gsql to Connect to the Database?
Symptom
The following error information is displayed when running the gsql -d postgres -p 26000 -r command:
1 | gsql: command not found... |
Possible Causes
- The command is not executed in the bin directory of gsql.
- The environment variable is not executed.
Handling Procedure
- Run the environment variable in the client directory, for example, in the /opt directory.
1 2
cd /opt source gsql_env.sh

- Go to the bin directory of gsql and run the gsql command to connect to the database.
cd bin gsql -d gaussdb -h Database_IP_address -p 8000 -U dbadmin -W Database_user_password -r;

Parent topic: Database Connections
What is your overall rating for this page?
0
1
2
3
4
5
6
7
8
9
10
Very dissatisfiedVery satisfied
Thank you very much for your feedback. We will continue working to improve the documentation.
The system is busy. Please try again later.