From dev-return-69484-archive-asf-public=cust-asf.ponee.io@zookeeper.apache.org Tue May 8 10:11:07 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id 768ED18063B for ; Tue, 8 May 2018 10:11:06 +0200 (CEST) Received: (qmail 28641 invoked by uid 500); 8 May 2018 08:11:04 -0000 Mailing-List: contact dev-help@zookeeper.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@zookeeper.apache.org Delivered-To: mailing list dev@zookeeper.apache.org Received: (qmail 28630 invoked by uid 99); 8 May 2018 08:11:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 May 2018 08:11:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 4B923C0286 for ; Tue, 8 May 2018 08:11:02 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -110.311 X-Spam-Level: X-Spam-Status: No, score=-110.311 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01, USER_IN_DEF_SPF_WL=-7.5, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id NGVPNZbQQ-yo for ; Tue, 8 May 2018 08:11: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 014D85F405 for ; Tue, 8 May 2018 08:11: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 8E1ADE0338 for ; Tue, 8 May 2018 08:11: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 48FB72129C for ; Tue, 8 May 2018 08:11:00 +0000 (UTC) Date: Tue, 8 May 2018 08:11:00 +0000 (UTC) From: "Flavio Junqueira (JIRA)" To: dev@zookeeper.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (ZOOKEEPER-2982) Re-try DNS hostname -> IP resolution MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/ZOOKEEPER-2982?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16467049#comment-16467049 ] Flavio Junqueira commented on ZOOKEEPER-2982: --------------------------------------------- Based on this comment, I'm +1 from this change: https://issues.apache.org/jira/browse/ZOOKEEPER-2982?focusedCommentId=16371886&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-16371886 It would have been good to have a test case, but we haven't been able to come up with anything, so I suggest we leave it for future work. We also have a +1 from [~andorm] in the pull request. > Re-try DNS hostname -> IP resolution > ------------------------------------ > > Key: ZOOKEEPER-2982 > URL: https://issues.apache.org/jira/browse/ZOOKEEPER-2982 > Project: ZooKeeper > Issue Type: Bug > Components: server > Affects Versions: 3.5.0, 3.5.1, 3.5.3 > Reporter: Eron Wright > Assignee: Flavio Junqueira > Priority: Blocker > Fix For: 3.5.4, 3.6.0 > > Attachments: 3.5.3-beta.zip, fixed.log > > > ZOOKEEPER-1506 fixed a DNS resolution issue in 3.4. Some portions of the fix haven't yet been ported to 3.5. > To recap the outstanding problem in 3.5, if a given ZK server is started before all peer addresses are resolvable, that server may cache a negative lookup result and forever fail to resolve the address. For example, deploying ZK 3.5 to Kubernetes using a StatefulSet plus a Service (headless) may fail because the DNS records are created lazily. > {code} > 2018-02-18 09:11:22,583 [myid:0] - WARN [QuorumPeer[myid=0](plain=/0:0:0:0:0:0:0:0:2181)(secure=disabled):Follower@95] - Exception when following the leader > java.net.UnknownHostException: zk-2.zk.default.svc.cluster.local > at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184) > at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) > at java.net.Socket.connect(Socket.java:589) > at org.apache.zookeeper.server.quorum.Learner.sockConnect(Learner.java:227) > at org.apache.zookeeper.server.quorum.Learner.connectToLeader(Learner.java:256) > at org.apache.zookeeper.server.quorum.Follower.followLeader(Follower.java:76) > at org.apache.zookeeper.server.quorum.QuorumPeer.run(QuorumPeer.java:1133) > {code} > In the above example, the address `zk-2.zk.default.svc.cluster.local` was not resolvable when the server started, but became resolvable shortly thereafter. The server should eventually succeed but doesn't. -- This message was sent by Atlassian JIRA (v7.6.3#76005)