0
votes

I know there is a samiliar title question but whta we ask is different. I Tried this

hduser@tong-VirtualBox:/usr/local/hadoop$ bin/hadoop dfs -copyFromLocal /tmp/Text /home/hduser/Text

And I get this:

DEPRECATED: Use of this script to execute hdfs command is deprecated.
Instead use the hdfs command for it.

15/10/14 10:15:21 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
copyFromLocal: `/home/hduser/Text': No such file or directory
​

However, I do have the /home/hduser/Text And I'm using hdfs command What does the error mean? How can i fix it

1
Have you tried to specify server and port in the destination path: hdfs://<server>:<port>/home/hduser/Text ? - Aleksei Shestakov
I'm woring on single node. Do I need to specify server and port? - Gavin Niu

1 Answers

1
votes

However, I do have the /home/hduser/Text And I'm using hdfs command What does the error mean? How can i fix it

Either /home/hduser/Text doesn't exist or Syntax is incorrect. For later case, try below:

hduser@tong-VirtualBox:/usr/local/hadoop$ bin/hadoop dfs -copyFromLocal /home/hduser/Text /tmp/Text

 To get rid of warning - DEPRECATED: Use of this script to execute hdfs command is deprecated. Instead use the hdfs command for it.

hduser@tong-VirtualBox:/usr/local/hadoop$ hdfs dfs -copyFromLocal /home/hduser/Text /tmp/Text

copyFromLocal:

Usage: hdfs dfs -copyFromLocal <localsrc> URI

Similar to put command, except that the source is restricted to a local file reference.

Options:

    The -f option will overwrite the destination if it already exists.