hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Wang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-10480) Add an admin command to list currently open files
Date Tue, 04 Oct 2016 00:33:20 GMT

    [ https://issues.apache.org/jira/browse/HDFS-10480?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15543881#comment-15543881
] 

Andrew Wang commented on HDFS-10480:
------------------------------------

Hi Rushabh, thanks for working on this, I took a brief look at this patch. Some review comments:

* Is there a reason for dumping the info to a file on the NN? This makes it more difficult
for admins to get the information, and is more complicated than just printing it out on the
command line. Allowing a user-specified name that isn't validated is also a possible security
issue. This also means normal users can't use this, since they won't have access to the NN's
log directory.
* Let's not change the import to a wildcard, it makes backports harder.
* Shouldn't this only go to the active NN, since it has up-to-date info about writers? This
is in reference to the Operation.UNCHECKED and the HA logic in DFSAdmin.
* Nit: "getUnderconstructionFiles" -> "getUnderConstructionFiles"
* Could you also add a Java API to HdfsAdmin?

One more thing that would be nice here is to filter the output on a passed path or DN. Usecases:

* An admin might already know a stale file by path (perhaps from fsck's {{-openforwrite}}),
and wants to figure out who the lease holder is.
* A DN might be blocked from decommissioning by an open-for-write file, and the admin wants
to figure out what files those are.

> Add an admin command to list currently open files
> -------------------------------------------------
>
>                 Key: HDFS-10480
>                 URL: https://issues.apache.org/jira/browse/HDFS-10480
>             Project: Hadoop HDFS
>          Issue Type: Bug
>            Reporter: Kihwal Lee
>            Assignee: Rushabh S Shah
>         Attachments: HDFS-10480-trunk-1.patch, HDFS-10480-trunk.patch
>
>
> Currently there is no easy way to obtain the list of active leases or files being written.
It will be nice if we have an admin command to list open files and their lease holders.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: hdfs-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: hdfs-issues-help@hadoop.apache.org


Mime
View raw message