Return-Path: Delivered-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Received: (qmail 53771 invoked from network); 17 Mar 2010 00:49:51 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 17 Mar 2010 00:49:51 -0000 Received: (qmail 7920 invoked by uid 500); 17 Mar 2010 00:49:51 -0000 Delivered-To: apmail-hadoop-hdfs-issues-archive@hadoop.apache.org Received: (qmail 7845 invoked by uid 500); 17 Mar 2010 00:49:51 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hdfs-issues@hadoop.apache.org Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 7699 invoked by uid 99); 17 Mar 2010 00:49:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Mar 2010 00:49:50 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Mar 2010 00:49:48 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 8089629A0012 for ; Wed, 17 Mar 2010 00:49:27 +0000 (UTC) Message-ID: <322514079.305051268786967525.JavaMail.jira@brutus.apache.org> Date: Wed, 17 Mar 2010 00:49:27 +0000 (UTC) From: "Rodrigo Schmidt (JIRA)" To: hdfs-issues@hadoop.apache.org Subject: [jira] Commented: (HDFS-1032) Extend DFSck with an option to list corrupt files using API from HDFS-729 In-Reply-To: <875908419.167721268183787985.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HDFS-1032?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D12846= 245#action_12846245 ]=20 Rodrigo Schmidt commented on HDFS-1032: --------------------------------------- It doesn't have to be that complicated, right? What about the following change to the code you had on your current patch: {code} String pathdir =3D path.endsWith(Path.SEPARATOR) ? path : path + Path.SEPAR= ATOR; //directory representation of path for(FileStatus fileStatus:corruptedFileStatuses){ =09String currentPath =3D fileStatus.getPath().toString(); =09if(currentPath.equals(path) || currentPath.startsWith(pathdir)){ =09=09matchedCorruptedFilesCount++; =09=09out.println(currentPath); =09}=09 } {code} That looks simpler to me. What do you think? > Extend DFSck with an option to list corrupt files using API from HDFS-729 > ------------------------------------------------------------------------- > > Key: HDFS-1032 > URL: https://issues.apache.org/jira/browse/HDFS-1032 > Project: Hadoop HDFS > Issue Type: Improvement > Components: tools > Reporter: Rodrigo Schmidt > Assignee: Andr=C3=A9 Oriani > Attachments: hdfs-1032_aoriani.patch > > > HDFS-729 created a new API to namenode that returns the list of corrupt f= iles. > We can now extend fsck (DFSck.java) to add an option (e.g. --list_corrupt= ) that queries the namenode using the new API and lists the corrupt blocks = to the users. --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.