Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 90821200C39 for ; Thu, 2 Mar 2017 00:13:51 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 8F212160B7F; Wed, 1 Mar 2017 23:13:51 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id D759E160B70 for ; Thu, 2 Mar 2017 00:13:50 +0100 (CET) Received: (qmail 90949 invoked by uid 500); 1 Mar 2017 23:13:49 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 90938 invoked by uid 99); 1 Mar 2017 23:13:49 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Mar 2017 23:13:49 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 5F7801895B9 for ; Wed, 1 Mar 2017 23:13:49 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -2.347 X-Spam-Level: X-Spam-Status: No, score=-2.347 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-2.999, SPF_NEUTRAL=0.652] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id 9e7RtPg9TNtQ for ; Wed, 1 Mar 2017 23:13:48 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id E1EF45F23D for ; Wed, 1 Mar 2017 23:13:47 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 2FF64E0A12 for ; Wed, 1 Mar 2017 23:13:46 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 65F2924170 for ; Wed, 1 Mar 2017 23:13:45 +0000 (UTC) Date: Wed, 1 Mar 2017 23:13:45 +0000 (UTC) From: "Kahlil Oppenheimer (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HBASE-17707) New More Accurate TableSkew Balancer/Generator MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 01 Mar 2017 23:13:51 -0000 [ https://issues.apache.org/jira/browse/HBASE-17707?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Kahlil Oppenheimer updated HBASE-17707: --------------------------------------- Attachment: HBASE-17707-04.patch > New More Accurate TableSkew Balancer/Generator > ---------------------------------------------- > > Key: HBASE-17707 > URL: https://issues.apache.org/jira/browse/HBASE-17707 > Project: HBase > Issue Type: New Feature > Components: Balancer > Affects Versions: 1.2.0 > Environment: CentOS Derivative with a derivative of the 3.18.43 kernel. HBase on CDH5.9.0 with some patches. HDFS CDH 5.9.0 with no patches. > Reporter: Kahlil Oppenheimer > Priority: Minor > Labels: patch > Attachments: HBASE-17707-00.patch, HBASE-17707-01.patch, HBASE-17707-02.patch, HBASE-17707-03.patch, HBASE-17707-04.patch > > > This patch includes new version of the TableSkewCostFunction and a new TableSkewCandidateGenerator. > The new TableSkewCostFunction computes table skew by counting the minimal number of region moves required for a given table to perfectly balance the table across the cluster (i.e. as if the regions from that table had been round-robin-ed across the cluster). This number of moves is computer for each table, then normalized to a score between 0-1 by dividing by the number of moves required in the absolute worst case (i.e. the entire table is stored on one server), and stored in an array. The cost function then takes a weighted average of the average and maximum value across all tables. The weights in this average are configurable to allow for certain users to more strongly penalize situations where one table is skewed versus where every table is a little bit skewed. To better spread this value more evenly across the range 0-1, we take the square root of the weighted average to get the final value. > The new TableSkewCandidateGenerator generates region moves/swaps to optimize the above TableSkewCostFunction. It first simply tries to move regions until each server has the right number of regions, then it swaps regions around such that each region swap improves table skew across the cluster. > We tested the cost function and generator in our production clusters with 100s of TBs of data and 100s of tables across dozens of servers and found both to be very performant and accurate. -- This message was sent by Atlassian JIRA (v6.3.15#6346)