Help Center/ MapReduce Service/ Troubleshooting/ Using HDFS/ An Error Is Reported When the HDFS Client Is Used After the Host Is Connected Using a Public Network IP Address
Updated on 2023-01-11 GMT+08:00

An Error Is Reported When the HDFS Client Is Used After the Host Is Connected Using a Public Network IP Address

Issue

When the host is connected using a public network IP address, the HDFS client cannot be used and the message "-bash: hdfs: command not found" is displayed when the HDFS is running.

Symptom

When the host is connected using a public network IP address, the HDFS client cannot be used and the message "-bash: hdfs: command not found" is displayed when the HDFS is running.

Possible Causes

The environment variables are not set before the user logs in to the Master node and runs the command.

Procedure

  1. Log in to any Master node as user root.
  2. Run the source Client installation directory/bigdata_env command to set environment variables.
  3. Run the hdfs command to use the HDFS client.