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 A03C9200D4A for ; Tue, 28 Nov 2017 19:47:04 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 9EA34160C15; Tue, 28 Nov 2017 18:47:04 +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 E4AAC160BE7 for ; Tue, 28 Nov 2017 19:47:03 +0100 (CET) Received: (qmail 608 invoked by uid 500); 28 Nov 2017 18:47:03 -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 594 invoked by uid 99); 28 Nov 2017 18:47:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Nov 2017 18:47:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 43A63C60D4 for ; Tue, 28 Nov 2017 18:47:02 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.011 X-Spam-Level: X-Spam-Status: No, score=-99.011 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KB_WAM_FROM_NAME_SINGLEWORD=0.2, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id k6uNrLlJhGlp for ; Tue, 28 Nov 2017 18:47:01 +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 36B8E5F3D1 for ; Tue, 28 Nov 2017 18:47:01 +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 C1965E05B7 for ; Tue, 28 Nov 2017 18:47:00 +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 7C474241C0 for ; Tue, 28 Nov 2017 18:47:00 +0000 (UTC) Date: Tue, 28 Nov 2017 18:47:00 +0000 (UTC) From: "Bar Rotstein (JIRA)" To: issues@hbase.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HBASE-14171) [HBase Thrift] ThriftServer is not shutting down if "hbase.regionserver.thrift.port" Address already in use. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Tue, 28 Nov 2017 18:47:04 -0000 [ https://issues.apache.org/jira/browse/HBASE-14171?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16269248#comment-16269248 ] Bar Rotstein commented on HBASE-14171: -------------------------------------- i will add tests but currently it seems like the thrift server shutsdown on both thrift and http mode if the port is already used. {code:java} 2017-11-28 20:43:39,484 FATAL [ThriftServer-httpServer] thrift.ThriftServerRunner$1(384): Cannot run ThriftServer org.apache.thrift.transport.TTransportException: Could not create ServerSocket on address /0.0.0.0:49689. at org.apache.thrift.transport.TServerSocket.(TServerSocket.java:109) at org.apache.hadoop.hbase.thrift.ThriftServerRunner.setupServer(ThriftServerRunner.java:640) at org.apache.hadoop.hbase.thrift.ThriftServerRunner.access$500(ThriftServerRunner.java:147) at org.apache.hadoop.hbase.thrift.ThriftServerRunner$1.run(ThriftServerRunner.java:380) at java.security.AccessController.doPrivileged(Native Method) at javax.security.auth.Subject.doAs(Subject.java:360) at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1726) at org.apache.hadoop.hbase.thrift.ThriftServerRunner.run(ThriftServerRunner.java:370) at org.apache.hadoop.hbase.thrift.ThriftServer.doMain(ThriftServer.java:106) at org.apache.hadoop.hbase.thrift.TestThriftUsedPortShutdown$2.run(TestThriftUsedPortShutdown.java:114) at java.lang.Thread.run(Thread.java:748) Caused by: java.net.BindException: Address already in use (Bind failed) at java.net.PlainSocketImpl.socketBind(Native Method) at java.net.AbstractPlainSocketImpl.bind(AbstractPlainSocketImpl.java:387) at java.net.ServerSocket.bind(ServerSocket.java:375) at org.apache.thrift.transport.TServerSocket.(TServerSocket.java:106) ... 10 more {code} > [HBase Thrift] ThriftServer is not shutting down if "hbase.regionserver.thrift.port" Address already in use. > ------------------------------------------------------------------------------------------------------------ > > Key: HBASE-14171 > URL: https://issues.apache.org/jira/browse/HBASE-14171 > Project: HBase > Issue Type: Bug > Components: Thrift > Reporter: Y. SREENIVASULU REDDY > Assignee: Bar Rotstein > Fix For: 2.0.0 > > > If "hbase.regionserver.thrift.port" Address already in use, ThriftServer should shutdown, > with out this "hbase.regionserver.thrift.port" we cant perform any operations on ThriftServer . Then there is no use of running ThriftServer process. > If port is already used then exception or message also not throwing like address already in use. > Only info port information is showing. > {code} > 2015-07-30 12:20:56,186 INFO [main] http.HttpServer: Jetty bound to port 9095 > 2015-07-30 12:20:56,186 INFO [main] mortbay.log: jetty-6.1.26 > 2015-07-30 12:20:56,227 WARN [main] mortbay.log: Can't reuse /tmp/Jetty_0_0_0_0_9095_thrift____.vqpz9l, using /tmp/Jetty_0_0_0_0_9095_thrift____.vqpz9l_4913486964252131199 > 2015-07-30 12:20:56,553 INFO [main] mortbay.log: Started HttpServer$SelectChannelConnectorWithSafeStartup@0.0.0.0:9095 {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)