Return-Path: X-Original-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 60674DC5F for ; Tue, 24 Jul 2012 13:02:21 +0000 (UTC) Received: (qmail 5055 invoked by uid 500); 24 Jul 2012 13:02:20 -0000 Delivered-To: apmail-hadoop-hdfs-user-archive@hadoop.apache.org Received: (qmail 4585 invoked by uid 500); 24 Jul 2012 13:02:16 -0000 Mailing-List: contact hdfs-user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hdfs-user@hadoop.apache.org Delivered-To: mailing list hdfs-user@hadoop.apache.org Received: (qmail 4551 invoked by uid 99); 24 Jul 2012 13:02:15 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Jul 2012 13:02:15 +0000 X-ASF-Spam-Status: No, hits=-0.1 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_MED,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of brahmareddy.battula@huawei.com designates 119.145.14.64 as permitted sender) Received: from [119.145.14.64] (HELO szxga01-in.huawei.com) (119.145.14.64) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 24 Jul 2012 13:02:06 +0000 Received: from 172.24.2.119 (EHLO szxeml202-edg.china.huawei.com) ([172.24.2.119]) by szxrg01-dlp.huawei.com (MOS 4.3.4-GA FastPath queued) with ESMTP id ALY63980; Tue, 24 Jul 2012 21:01:39 +0800 (CST) Received: from SZXEML418-HUB.china.huawei.com (10.82.67.157) by szxeml202-edg.china.huawei.com (172.24.2.42) with Microsoft SMTP Server (TLS) id 14.1.323.3; Tue, 24 Jul 2012 21:01:34 +0800 Received: from SZXEML534-MBX.china.huawei.com ([169.254.2.243]) by szxeml418-hub.china.huawei.com ([10.82.67.157]) with mapi id 14.01.0323.003; Tue, 24 Jul 2012 21:01:38 +0800 From: Brahma Reddy Battula To: "hdfs-user@hadoop.apache.org" Subject: Starting NameNode with finalize option Thread-Topic: Starting NameNode with finalize option Thread-Index: Ac1plUe8kyizmGJRTLuKSWMlvxRINQ== Date: Tue, 24 Jul 2012 13:01:37 +0000 Message-ID: <8AD4EE147886274A8B495D6AF407DF6910E3E509@szxeml534-mbx.china.huawei.com> Accept-Language: en-US, zh-CN Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.18.96.93] Content-Type: multipart/alternative; boundary="_000_8AD4EE147886274A8B495D6AF407DF6910E3E509szxeml534mbxchi_" MIME-Version: 1.0 X-CFilter-Loop: Reflected --_000_8AD4EE147886274A8B495D6AF407DF6910E3E509szxeml534mbxchi_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi ALL, Can Anyone tell me when following finalize option will be used. case FINALIZE: { boolean aborted =3D finalize(conf, true); System.exit(aborted ? 1 : 0); return null; // avoid javac warning private static boolean finalize(Configuration conf, boolean isConfirmationNeeded ) throws IOException { String nsId =3D DFSUtil.getNamenodeNameServiceId(conf); String namenodeId =3D HAUtil.getNameNodeId(conf, nsId); initializeGenericKeys(conf, nsId, namenodeId); FSNamesystem nsys =3D new FSNamesystem(conf, new FSImage(conf)); System.err.print( "\"finalize\" will remove the previous state of the files system.\n= " + "Recent upgrade will become permanent.\n" + "Rollback option will not be available anymore.\n"); if (isConfirmationNeeded) { if (!confirmPrompt("Finalize filesystem state?")) { System.err.println("Finalize aborted."); return true; } } nsys.dir.fsImage.finalizeUpgrade(); return false; } I thought after up-gradation it'll be used to finalize filesystem instead o= f finalize upgrade. But it was failing by logging following in .out log and= it process got hang since it's expecting input which we can't give. Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: Finalize filesystem state? (Y or N) Invalid input: --_000_8AD4EE147886274A8B495D6AF407DF6910E3E509szxeml534mbxchi_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hi ALL,

Can  Anyone tell me when following finalize option will be used.<= /div>

 case FINALIZE: {         boolean aborted =3D finali= ze(conf, true); 
        System.exit(aborted ? 1 : 0); 
        return null// avoid javac warning 




 private static = ;boolean<= /b> finalize(Configuratio= n conf, 
          &n= bsp;                    <= /font>boolean isConfirmationNeeded&nb= sp;
          &n= bsp;                    )=  thr= ows IOException {&nbs= p;
    String nsId =3D DFSUtil= .getNamenodeNameServiceId(conf); 
    String namenodeId =3D H= AUtil.getNameNodeId(conf, nsId); 
    initializeGener= icKeys(conf, nsId, namenodeId); 

    FSNamesystem nsys =3D&n= bsp;new FSNamesystem(conf,&nbs= p;new=  FSImage(conf)); 
    System.err.print( 
        "\"fin= alize\" will remove the previous state of the files system.\n"&nb= sp;
        +&nbs= p;"Rece= nt upgrade will become permanent.\n" 
        +&nbs= p;"Roll= back option will not be available anymore.\n"); 
    if (isConfirmationNeeded) { 
      if
 (!confirmPrompt("Finalize filesystem s= tate?")) {         System.err.println("Finalize aborted."<= font size=3D"2" face=3D"Courier New">); 
        return true; 
      }      } 
    nsys.dir.fsImage.finalizeUpgrad= e(); 
    return false; 
  } 
      
I thought after up-gradatio= n it'll be used to finalize filesystem instead of finalize upgrad= e. But it was failing by logging following in .out log and it process got h= ang since it's expecting input which we can't give. 


Finalize filesystem state? (Y or N) Invalid input: 

Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 
Finalize filesystem state? (Y or N) I= nvalid input: 




--_000_8AD4EE147886274A8B495D6AF407DF6910E3E509szxeml534mbxchi_--