From yarn-issues-return-138998-archive-asf-public=cust-asf.ponee.io@hadoop.apache.org Fri Mar 2 07:06: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 98D5518062F for ; Fri, 2 Mar 2018 07:06:06 +0100 (CET) Received: (qmail 8743 invoked by uid 500); 2 Mar 2018 06:06:04 -0000 Mailing-List: contact yarn-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list yarn-issues@hadoop.apache.org Received: (qmail 8727 invoked by uid 99); 2 Mar 2018 06:06:04 -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; Fri, 02 Mar 2018 06:06:04 +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 A4B8EC0611 for ; Fri, 2 Mar 2018 06:06:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -109.511 X-Spam-Level: X-Spam-Status: No, score=-109.511 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, KAM_ASCII_DIVIDERS=0.8, 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-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id xY7c56nSBgCM for ; Fri, 2 Mar 2018 06:06:02 +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 95D1E5F2A8 for ; Fri, 2 Mar 2018 06:06: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 A8161E022F for ; Fri, 2 Mar 2018 06:06: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 575B224765 for ; Fri, 2 Mar 2018 06:06:00 +0000 (UTC) Date: Fri, 2 Mar 2018 06:06:00 +0000 (UTC) From: "Suma Shivaprasad (JIRA)" To: yarn-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (YARN-7987) Docker container name(--name) needs to be DNS friendly for DNS resolution to work in user defined networks. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/YARN-7987?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D16383= 223#comment-16383223 ]=20 Suma Shivaprasad commented on YARN-7987: ---------------------------------------- Thanks [~shanekumpf@gmail.com] for your inputs. yes you are right - The FQD= N is being set to the=C2=A0. as you mentioned= in case of both qualified and non-qualified container names and not from t= he domain-name specified in --name or --hostName. Sorry for not being clear= in the previous comment, I meant YARN sets --name to non-qualified name wh= ich fails DNS resolution. Tested --network-alias with all the=C2=A0available docker network modes=C2= =A0and user defined network types i.e bridge, overlay and macvlan. Here are= the observations. # network-alias is not a valid option in the "default bridge"and "host" ne= tworking modes and adding this flag fails. Will need to check and add this = to docker container runs only in the case of user defined networks.=C2=A0 N= ot sure what is the behaviour in case of third party network plugins. This = will need to be validated. # --network-alias is not being checked for unique-ness by docker embedded = DNS while starting a container. However --name values are validated to be u= nique across the network. I could start two containers with the --network-a= lias having the same value and the DNS resolution points to the container's= IP which started first. However, since=C2=A0the YARN generated hostnames (= generated from container-id) are unique, this should not be a major issue I= MO.=C2=A0 =C2=A0 > Docker container name(--name) needs to be DNS friendly for DNS resolution= to work in user defined networks.=20 > -------------------------------------------------------------------------= ----------------------------------- > > Key: YARN-7987 > URL: https://issues.apache.org/jira/browse/YARN-7987 > Project: Hadoop YARN > Issue Type: Sub-task > Reporter: Suma Shivaprasad > Assignee: Suma Shivaprasad > Priority: Major > > User defined networks like overlays support DNS resolution through Docker= Embedded DNS which needs the container name (=E2=80=93name parameter value= in docker run)=C2=A0to be a FQDN for container names to be resolved - Plea= se refer documentation [https://docs.docker.com/v17.09/engine/userguide/net= working/configure-dns/] > However Yarn sets the container name to the container's id which is not D= NS friendly(eg:=C2=A0container_e26_1519402686002_0035_01_000003) and is not= a FQDN.=C2=A0 > The proposal is to set a FQDN(eg:=C2=A0ctr-e26-1519402686002-0035-01-0000= 03.domain-name) as=C2=A0the docker container's name for containers to be ab= le to communicate to each other via hostnames=C2=A0in user defined networks= like overlays, bridges etc. The domain name will be picked up from the YAR= N DNS registry configuration (hadoop.registry.dns.domain-name) > =C2=A0 > =C2=A0 > =C2=A0 > =C2=A0 > =C2=A0 > =C2=A0 > =C2=A0 > =C2=A0 -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: yarn-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: yarn-issues-help@hadoop.apache.org