hadoop-hdfs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kamesh <kames...@imaginea.com>
Subject Re: *****SPAM*****Get Replication level of a file in HDFS.
Date Thu, 29 Sep 2011 12:20:16 GMT
On Thursday 29 September 2011 04:49 PM, Ajit Ratnaparkhi wrote:
> Hi,
>
> Is there any way to get replication level of a file in HDFS?
>
> thanks,
> Ajit.
If you want this through program or just want to know.

1) If You  just want to know, you can do this through NN web UI or 
through CLI ( execute ls command on HDFS ) after ACLs it shows the 
replication factor of the file.
2) If you need this info through program use the following API.
                      FileStatus.getReplication();


-- 
/Thanks&Regards,/
/Bh.V.S.Kamesh/

Mime
View raw message