我通过给出下面的命令将本地系统中的pig处理文件复制到hdfs路径(链接到配置单元表),但它没有复制。
步骤1:数据在我的本地路径中
[root@quickstart plantoutput]# ll
total 4
-rw-r--r-- 1 root root 1469 Dec 3 02:37 part-m-00000
-rw-r--r-- 1 root root 0 Dec 3 02:37 _SUCCESS
[root@quickstart plantoutput]# pwd
/home/cloudera/Desktop/dealer/plantoutput
步骤2:应用命令后,如下所示
[root@quickstart plantoutput]# hadoop fs -put '/home/cloudera/Desktop/dealer/plantoutput' /tabplant
[root@quickstart plantoutput]# hadoop fs -ls /tabplant
找到1个项目
drwxr-xr-x-根超群0 2018-12-04 21:52/tabplant/plantoutput
实际上在我的目标中 hdfs
路径不包含 part-m-00000
以及 _SUCCESS
有人能告诉我我做错了什么吗?是报价吗?
1条答案
按热度按时间5rgfhyps1#
@塞哈尔,
仅复制中存在的文件
/home/cloudera/Desktop/dealer/plantoutput
您应该提到您可以使用的绝对文件路径,如下所示,当您只提到目录时,它将以父目录的名称复制为目录。