Help Center/ DataArts Studio/ FAQs/ DataArts Factory/ What Should I Do If a Shell Script Debugged on an ECS Fails to Be Executed in DataArts Factory?
Updated on 2025-06-05 GMT+08:00

What Should I Do If a Shell Script Debugged on an ECS Fails to Be Executed in DataArts Factory?

Symptom

A shell script that has been debugged on an ECS fails to be executed in DataArts Factory.

The script is used to connect to GaussDB(DWS) through gsql to query the number of data rows in a database table.

Debugging result on an ECS

Execution result of script in DataArts Factory

Figure 1 Script execution result

Solution

Add the following two commands:

export LD_LIBRARY_PATH=/usr/local/dws_client_8.1.x_x64/lib:${LD_LIBRARY_PATH}
export PATH=/usr/local/dws_client_8.1.x_x64/bin:${PATH}

/usr/local/dws_client_8.1.x_x64 is the path where the GaussDB(DWS) client is installed.