简体   繁体   English

更改Hadoop HDFS文件名

[英]Change Hadoop HDFS name of file

I want to change the automatically saved filename of a HDFS block on a cluster. 我想更改群集上HDFS块的自动保存的文件名。 So when I upload a file to the HDFS and it'll divided into blocks, they get generated names with several numbers. 因此,当我将文件上传到HDFS并将其划分为多个块时,它们将生成带有多个数字的名称。 I searched the code but couldn't find it. 我搜索了代码,但找不到。

It should be somewhere in the java code, not a configuration file, right? 它应该在Java代码中的某个地方,而不是配置文件,对吗?

Can someone may tell me in which classes this creation or definition of the filename happens? 有人可以告诉我文件名的创建或定义在哪些类中发生?

Thanks a lot! 非常感谢!

edit: 编辑:

Ok found it. 确定找到了。

FSNameSystem.randBlockId.nextLong()

确定找到了。

FSNameSystem.randBlockId.nextLong()

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM