Return-Path: X-Original-To: apmail-hbase-user-archive@www.apache.org Delivered-To: apmail-hbase-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EC6DC1180E for ; Mon, 22 Sep 2014 18:13:14 +0000 (UTC) Received: (qmail 23097 invoked by uid 500); 22 Sep 2014 18:13:12 -0000 Delivered-To: apmail-hbase-user-archive@hbase.apache.org Received: (qmail 23021 invoked by uid 500); 22 Sep 2014 18:13:12 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 23010 invoked by uid 99); 22 Sep 2014 18:13:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 22 Sep 2014 18:13:12 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS,T_REMOTE_IMAGE X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of bharathv@cloudera.com designates 209.85.218.48 as permitted sender) Received: from [209.85.218.48] (HELO mail-oi0-f48.google.com) (209.85.218.48) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 22 Sep 2014 18:12:46 +0000 Received: by mail-oi0-f48.google.com with SMTP id e131so3663014oig.21 for ; Mon, 22 Sep 2014 11:12:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=9eOeL9hT0cmHoiMtB+6qBU6bwDw+9PUb2WocCaa/jAM=; b=EzjurPH8Z7pyHAWai0LQ8QOVtNcHZMqRhX4NJ4bMdlOPfL/wuLwGQ1QB12jimJn+Hq FSUUg5tQ3MXGMrIg05nTRCWvKjn7IgBA31oEB4J7u4Sgy+6NsdyFYhcsctMstZsHUgvI WyXRtw9Bo7HsjYp2pGdRJwvI5vaWNe4ZHPgIZYg9PDW559lriZrgewW0XGKiW5i6XMvN +nVErkpH7qMuyERFRJnUn0tiSHgRrtWpCbECtF1jFzprxqsA94m7ohC7HqzTfnfglGQL Y7pPDn64PE6zGYSq3UO5Q+owOxIrQJH8yNOAJbz/R2kfxcqItN1Iryd+ZejCJSWzweq+ Ouig== X-Gm-Message-State: ALoCoQm26ScR1UJbbLBoyDSeDMoQG1c03u1xvGYz6+QR3jq/o2RzGUKHS0ddFRd6p6C+OyyFxwkG X-Received: by 10.60.58.193 with SMTP id t1mr22030403oeq.20.1411409565103; Mon, 22 Sep 2014 11:12:45 -0700 (PDT) MIME-Version: 1.0 Received: by 10.76.101.71 with HTTP; Mon, 22 Sep 2014 11:12:24 -0700 (PDT) In-Reply-To: References: From: Bharath Vissapragada Date: Mon, 22 Sep 2014 11:12:24 -0700 Message-ID: Subject: Re: Help: RegionTooBusyException: failed to get a lock in 60000 ms To: hbase-user Content-Type: multipart/alternative; boundary=089e013cb946c2c9d80503ab6590 X-Virus-Checked: Checked by ClamAV on apache.org --089e013cb946c2c9d80503ab6590 Content-Type: text/plain; charset=UTF-8 https://issues.apache.org/jira/browse/HBASE-11368 related to the original issue too. On Mon, Sep 22, 2014 at 10:18 AM, Ted Yu wrote: > As you noted in the FIXME, there're some factors which should be tackled by > balancer / assignment manager. > > Please continue digging up master log so that we can find the cause for > balancer not fulfilling your goal. > > Cheers > > On Mon, Sep 22, 2014 at 10:09 AM, Jianshi Huang > wrote: > > > Ok, I fixed this by manually reassign region servers to newly created > ones. > > > > def reassignRegionServer(admin: HBaseAdmin, regions: Seq[HRegionInfo], > > regionServers: Seq[ServerName]): Unit = { > > val rand = new Random() > > regions.foreach { r => > > val idx = rand.nextInt(regionServers.size) > > val server = regionServers(idx) > > // FIXME: what if selected region server is dead? > > admin.move(r.getEncodedNameAsBytes, > > server.getServerName.getBytes("UTF8")) > > } > > } > > > > er... > > > > Jianshi > > > > On Tue, Sep 23, 2014 at 12:24 AM, Jianshi Huang > > > wrote: > > > > > Hmm...any workaround? I only want to do this: > > > > > > Rebalance the new regions *evenly* to all servers after manually adding > > > splits, so later bulk insertions won't cause contention. > > > > > > P.S. > > > Looks like two of the region servers which had majority of the regions > > > were down during Major compaction... I guess it had too much data. > > > > > > > > > Jianshi > > > > > > On Tue, Sep 23, 2014 at 12:13 AM, Jianshi Huang < > jianshi.huang@gmail.com > > > > > > wrote: > > > > > >> Yes, I have access to Master UI, however logs/*.log cannot be opened > or > > >> downloaded, must be some security restrictions in the proxy... > > >> > > >> Jianshi > > >> > > >> On Tue, Sep 23, 2014 at 12:06 AM, Ted Yu wrote: > > >> > > >>> Do you have access to Master UI ? > > >>> > > >>> :60010/logs/ would show you list of log files. > > >>> > > >>> The you can view > > :60010/logs/hbase--master-XXX.log > > >>> > > >>> Cheers > > >>> > > >>> On Mon, Sep 22, 2014 at 9:00 AM, Jianshi Huang < > > jianshi.huang@gmail.com> > > >>> wrote: > > >>> > > >>> > Ah... I don't have access to HMaster logs... I need to ask the > admin. > > >>> > > > >>> > Jianshi > > >>> > > > >>> > On Mon, Sep 22, 2014 at 11:49 PM, Ted Yu > > wrote: > > >>> > > > >>> > > bq. assign per-table balancer class > > >>> > > > > >>> > > No that I know of. > > >>> > > Can you pastebin master log involving output from balancer ? > > >>> > > > > >>> > > Cheers > > >>> > > > > >>> > > On Mon, Sep 22, 2014 at 8:29 AM, Jianshi Huang < > > >>> jianshi.huang@gmail.com> > > >>> > > wrote: > > >>> > > > > >>> > > > Hi Ted, > > >>> > > > > > >>> > > > I moved setBalancerRunning before balancer and run them twice. > > >>> However > > >>> > I > > >>> > > > still got highly skewed region distribution. > > >>> > > > > > >>> > > > I guess it's because of the StochasticLoadBalancer, can I > assign > > >>> > > per-table > > >>> > > > balancer class in HBase? > > >>> > > > > > >>> > > > > > >>> > > > Jianshi > > >>> > > > > > >>> > > > On Mon, Sep 22, 2014 at 9:50 PM, Ted Yu > > >>> wrote: > > >>> > > > > > >>> > > > > admin.setBalancerRunning() call should precede the call to > > >>> > > > > admin.balancer(). > > >>> > > > > > > >>> > > > > You can inspect master log to see whether regions are being > > >>> moved off > > >>> > > the > > >>> > > > > heavily loaded server. > > >>> > > > > > > >>> > > > > Cheers > > >>> > > > > > > >>> > > > > On Mon, Sep 22, 2014 at 1:42 AM, Jianshi Huang < > > >>> > > jianshi.huang@gmail.com> > > >>> > > > > wrote: > > >>> > > > > > > >>> > > > > > Hi Ted and others, > > >>> > > > > > > > >>> > > > > > I did the following after adding splits (without data) to > my > > >>> table, > > >>> > > > > however > > >>> > > > > > the region is still very imbalanced (one region server has > > 221 > > >>> > > regions > > >>> > > > > and > > >>> > > > > > other 50 region servers have about 4~8 regions each). > > >>> > > > > > > > >>> > > > > > admin.balancer() > > >>> > > > > > admin.setBalancerRunning(true, true) > > >>> > > > > > > > >>> > > > > > The balancer class in my HBase cluster is > > >>> > > > > > > > >>> > > > > > > > org.apache.hadoop.hbase.master.balancer.StochasticLoadBalancer > > >>> > > > > > > > >>> > > > > > So, is this behavior expected? Can I assign different > > balancer > > >>> > class > > >>> > > to > > >>> > > > > my > > >>> > > > > > tables (I don't have HBase admin permission)? Which one > > should > > >>> I > > >>> > use? > > >>> > > > > > > > >>> > > > > > I just want HBase to evenly distribute the regions even > they > > >>> don't > > >>> > > have > > >>> > > > > > data (that's the purpose of pre-split I think). > > >>> > > > > > > > >>> > > > > > > > >>> > > > > > Jianshi > > >>> > > > > > > > >>> > > > > > > > >>> > > > > > On Sat, Sep 6, 2014 at 12:45 AM, Ted Yu < > yuzhihong@gmail.com > > > > > >>> > wrote: > > >>> > > > > > > > >>> > > > > > > Yes. See the following method in HBaseAdmin: > > >>> > > > > > > > > >>> > > > > > > public boolean balancer() > > >>> > > > > > > > > >>> > > > > > > > > >>> > > > > > > On Fri, Sep 5, 2014 at 9:38 AM, Jianshi Huang < > > >>> > > > jianshi.huang@gmail.com > > >>> > > > > > > > >>> > > > > > > wrote: > > >>> > > > > > > > > >>> > > > > > > > Thanks Ted! > > >>> > > > > > > > > > >>> > > > > > > > Didn't know I still need to run the 'balancer' command. > > >>> > > > > > > > > > >>> > > > > > > > Is there a way to do it programmatically? > > >>> > > > > > > > > > >>> > > > > > > > Jianshi > > >>> > > > > > > > > > >>> > > > > > > > > > >>> > > > > > > > > > >>> > > > > > > > On Sat, Sep 6, 2014 at 12:29 AM, Ted Yu < > > >>> yuzhihong@gmail.com> > > >>> > > > wrote: > > >>> > > > > > > > > > >>> > > > > > > > > After splitting the region, you may need to run > > balancer > > >>> to > > >>> > > > spread > > >>> > > > > > the > > >>> > > > > > > > new > > >>> > > > > > > > > regions out. > > >>> > > > > > > > > > > >>> > > > > > > > > Cheers > > >>> > > > > > > > > > > >>> > > > > > > > > > > >>> > > > > > > > > On Fri, Sep 5, 2014 at 9:25 AM, Jianshi Huang < > > >>> > > > > > jianshi.huang@gmail.com > > >>> > > > > > > > > > >>> > > > > > > > > wrote: > > >>> > > > > > > > > > > >>> > > > > > > > > > Hi Shahab, > > >>> > > > > > > > > > > > >>> > > > > > > > > > I see, that seems to be the right way... > > >>> > > > > > > > > > > > >>> > > > > > > > > > > > >>> > > > > > > > > > On Sat, Sep 6, 2014 at 12:21 AM, Shahab Yunus < > > >>> > > > > > > shahab.yunus@gmail.com> > > >>> > > > > > > > > > wrote: > > >>> > > > > > > > > > > > >>> > > > > > > > > > > Shahab > > >>> > > > > > > > > > > > >>> > > > > > > > > > > > >>> > > > > > > > > > > > >>> > > > > > > > > > > > >>> > > > > > > > > > > > >>> > > > > > > > > > -- > > >>> > > > > > > > > > Jianshi Huang > > >>> > > > > > > > > > > > >>> > > > > > > > > > LinkedIn: jianshi > > >>> > > > > > > > > > Twitter: @jshuang > > >>> > > > > > > > > > Github & Blog: http://huangjs.github.com/ > > >>> > > > > > > > > > > > >>> > > > > > > > > > > >>> > > > > > > > > > >>> > > > > > > > > > >>> > > > > > > > > > >>> > > > > > > > -- > > >>> > > > > > > > Jianshi Huang > > >>> > > > > > > > > > >>> > > > > > > > LinkedIn: jianshi > > >>> > > > > > > > Twitter: @jshuang > > >>> > > > > > > > Github & Blog: http://huangjs.github.com/ > > >>> > > > > > > > > > >>> > > > > > > > > >>> > > > > > > > >>> > > > > > > > >>> > > > > > > > >>> > > > > > -- > > >>> > > > > > Jianshi Huang > > >>> > > > > > > > >>> > > > > > LinkedIn: jianshi > > >>> > > > > > Twitter: @jshuang > > >>> > > > > > Github & Blog: http://huangjs.github.com/ > > >>> > > > > > > > >>> > > > > > > >>> > > > > > >>> > > > > > >>> > > > > > >>> > > > -- > > >>> > > > Jianshi Huang > > >>> > > > > > >>> > > > LinkedIn: jianshi > > >>> > > > Twitter: @jshuang > > >>> > > > Github & Blog: http://huangjs.github.com/ > > >>> > > > > > >>> > > > > >>> > > > >>> > > > >>> > > > >>> > -- > > >>> > Jianshi Huang > > >>> > > > >>> > LinkedIn: jianshi > > >>> > Twitter: @jshuang > > >>> > Github & Blog: http://huangjs.github.com/ > > >>> > > > >>> > > >> > > >> > > >> > > >> -- > > >> Jianshi Huang > > >> > > >> LinkedIn: jianshi > > >> Twitter: @jshuang > > >> Github & Blog: http://huangjs.github.com/ > > >> > > > > > > > > > > > > -- > > > Jianshi Huang > > > > > > LinkedIn: jianshi > > > Twitter: @jshuang > > > Github & Blog: http://huangjs.github.com/ > > > > > > > > > > > -- > > Jianshi Huang > > > > LinkedIn: jianshi > > Twitter: @jshuang > > Github & Blog: http://huangjs.github.com/ > > > -- Bharath Vissapragada --089e013cb946c2c9d80503ab6590--