将分隔 table 的文本输出写入本地 unix 时,hadoop fs -cat 命令出错
Errors in hadoop fs -cat command while writing output of text delimited table into local unix
我有非常大量的数据存储在文本分隔 table 中,其 DDL
我通过 Impala
创建,我用 Hive
中的数据写入它并且我想在单个文件中将其添加到 Unix
中的 local file system
。
我在 HDFS
table 位置路径中有多个文件,这是我使用的命令:
hadoop fs -cat '<tablelocationinHDFS>/*' > /unixlocalpathandfilename.csv
我收到 2 个错误:
cat: is a directory error
因为里面有一个impala_insert_staging目录,如何避免这个错误?
cat: Unable to write to output stream
或者我应该使用 get
命令或 getmerge
命令将数据导入本地到单个文件中吗?
如何避免上述错误并成功执行 运行 命令。
我会做以下事情
hdfs dfs -getmerge [-nl] <localdst> /unixlocalpath
-nl Add a newline character at the end of each file.
我有非常大量的数据存储在文本分隔 table 中,其 DDL
我通过 Impala
创建,我用 Hive
中的数据写入它并且我想在单个文件中将其添加到 Unix
中的 local file system
。
我在 HDFS
table 位置路径中有多个文件,这是我使用的命令:
hadoop fs -cat '<tablelocationinHDFS>/*' > /unixlocalpathandfilename.csv
我收到 2 个错误:
cat: is a directory error
因为里面有一个impala_insert_staging目录,如何避免这个错误?cat: Unable to write to output stream
或者我应该使用 get
命令或 getmerge
命令将数据导入本地到单个文件中吗?
如何避免上述错误并成功执行 运行 命令。
我会做以下事情
hdfs dfs -getmerge [-nl] <localdst> /unixlocalpath
-nl Add a newline character at the end of each file.