hdfs dfs-是否覆盖? [英] hdfs dfs -put with overwrite?

查看:1056
本文介绍了hdfs dfs-是否覆盖?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用

hdfs dfs -put myfile mypath

对于某些文件,我得到

put: 'myfile': File Exists

  • 这是否意味着已经存在一个具有相同名称的文件,或者意味着已经存在相同的确切文件(大小,内容)?
  • 如何在此处指定-overwrite选项?
  • 谢谢!

    推荐答案

    put: 'myfile': File Exists

    意味着,hdfs中已经存在名为"myfile"的文件. hdfs中不能有多个同名文件

    Means,the file named "myfile" already exists in hdfs. You cannot have multiple files of the same name in hdfs

    您可以使用hadoop fs -put -f /path_to_local /path_to_hdfs

    这篇关于hdfs dfs-是否覆盖?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆