欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

No such file or directory

程序员文章站 2022-03-01 14:54:32
...
hadoop fs -copyFromLocal /Users/ruigong/text.txt \ hdfs-rui/text2.txt

报错

WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
copyFromLocal: ` hdfs-rui/text2.txt': No such file or directory: `file:/Users/ruigong/%20hdfs-rui/text2.txt'

其中%20表示空格。

修改为:

hadoop fs -copyFromLocal /Users/ruigong/text.txt \hdfs-rui/text2.txt

hadoop fs -copyFromLocal /Users/ruigong/text.txt hdfs-rui/text2.txt

则正常,文件存储在/Users/ruigong/hdfs-rui/text2.txt