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 32C61200C16 for ; Thu, 26 Jan 2017 02:40:35 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 31648160B4E; Thu, 26 Jan 2017 01:40:35 +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 79D04160B5A for ; Thu, 26 Jan 2017 02:40:34 +0100 (CET) Received: (qmail 70212 invoked by uid 500); 26 Jan 2017 01:40:33 -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 70201 invoked by uid 99); 26 Jan 2017 01:40:33 -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; Thu, 26 Jan 2017 01:40:33 +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 2ACBD189AD4 for ; Thu, 26 Jan 2017 01:40:33 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.999 X-Spam-Level: X-Spam-Status: No, score=-1.999 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id JvYKoXlZXyrd for ; Thu, 26 Jan 2017 01:40:32 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 42E15619B6 for ; Thu, 26 Jan 2017 01:40:31 +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 8D095E0608 for ; Thu, 26 Jan 2017 01:40:28 +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 BA119252B9 for ; Thu, 26 Jan 2017 01:40:27 +0000 (UTC) Date: Thu, 26 Jan 2017 01:40:27 +0000 (UTC) From: "stack (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HBASE-17538) HDFS.setStoragePolicy() logs errors on local fs MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 26 Jan 2017 01:40:35 -0000 [ https://issues.apache.org/jira/browse/HBASE-17538?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] stack updated HBASE-17538: -------------------------- Attachment: HBASE-17538.master.001.patch > HDFS.setStoragePolicy() logs errors on local fs > ----------------------------------------------- > > Key: HBASE-17538 > URL: https://issues.apache.org/jira/browse/HBASE-17538 > Project: HBase > Issue Type: Bug > Affects Versions: 2.0.0 > Reporter: Enis Soztutar > Assignee: stack > Attachments: 0002-HBASE-17538-HFS.setStoragePolicy-logs-errors-on-loca.patch, HBASE-17538.master.001.patch > > > On a master pseudo-cluster running on local disk, the log contains a lot of these: > {code} > 2017-01-25 12:30:41,542 WARN [StoreOpener-32976c3c9b7c28ad632c041da486bfc3-1] fs.HFileSystem: Failed to set storage policy of [file:/var/folders/h5/bbxg50c12r5bhsd9hf1n9hlr0000gp/T/hbase-enis/hbase/dat > java.lang.UnsupportedOperationException: Cannot find specified method setStoragePolicy > at org.apache.hadoop.hbase.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:209) > at org.apache.hadoop.hbase.fs.HFileSystem.setStoragePolicy(HFileSystem.java:161) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:497) > at org.apache.hadoop.hbase.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:207) > at org.apache.hadoop.hbase.regionserver.HRegionFileSystem.setStoragePolicy(HRegionFileSystem.java:198) > at org.apache.hadoop.hbase.regionserver.HStore.(HStore.java:237) > at org.apache.hadoop.hbase.regionserver.HRegion.instantiateHStore(HRegion.java:5265) > at org.apache.hadoop.hbase.regionserver.HRegion$1.call(HRegion.java:988) > at org.apache.hadoop.hbase.regionserver.HRegion$1.call(HRegion.java:985) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:745) > Caused by: java.lang.NoSuchMethodException: org.apache.hadoop.fs.LocalFileSystem.setStoragePolicy(org.apache.hadoop.fs.Path, java.lang.String) > at java.lang.Class.getMethod(Class.java:1786) > at org.apache.hadoop.hbase.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:205) > ... 17 more > {code} > These are coming from HFS.setStoragePolicy() or HRegionFS.setStoragePolicy() . > This check: > {code} > try { > ReflectionUtils.invokeMethod(this.fs, "setStoragePolicy", storeDir, policyName); > } catch (Exception e) { > if (!(this.fs instanceof LocalFileSystem)) { > LOG.warn("Failed to set storage policy of [" + storeDir + "] to [" + policyName + "]", e); > } > } > {code} > does not work, because fs is not a LocalFS, but an HFS. And HFS internally does not do this check. seStoragePolicy() is very HDFS specific, the logic should instead check whether the underlying fs is HDFS (as opposed to checking whether it is not local FS). There are file systems that HBase supports other than local or HDFS. -- This message was sent by Atlassian JIRA (v6.3.4#6332)