From common-issues-return-147240-archive-asf-public=cust-asf.ponee.io@hadoop.apache.org Fri Jan 26 03:00:05 2018 Return-Path: X-Original-To: archive-asf-public@eu.ponee.io Delivered-To: archive-asf-public@eu.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by mx-eu-01.ponee.io (Postfix) with ESMTP id D853A180651 for ; Fri, 26 Jan 2018 03:00:05 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id C7F1E160C4F; Fri, 26 Jan 2018 02:00:05 +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 E7F99160C3D for ; Fri, 26 Jan 2018 03:00:04 +0100 (CET) Received: (qmail 16322 invoked by uid 500); 26 Jan 2018 02:00:04 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 16311 invoked by uid 99); 26 Jan 2018 02:00:03 -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; Fri, 26 Jan 2018 02:00:03 +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 7FD24180337 for ; Fri, 26 Jan 2018 02:00:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-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 (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id jyqw_Zdsr2Pm for ; Fri, 26 Jan 2018 02:00: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 749AE5FBED for ; Fri, 26 Jan 2018 02:00: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 9977CE015E for ; Fri, 26 Jan 2018 02:00: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 59CC2240EA for ; Fri, 26 Jan 2018 02:00:00 +0000 (UTC) Date: Fri, 26 Jan 2018 02:00:00 +0000 (UTC) From: "Bharat Viswanadham (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Comment Edited] (HADOOP-9747) Reduce unnecessary UGI synchronization 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/HADOOP-9747?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D163= 40431#comment-16340431 ]=20 Bharat Viswanadham edited comment on HADOOP-9747 at 1/26/18 1:59 AM: --------------------------------------------------------------------- Hi=C2=A0[~daryn] Thank You for the patch. I am going through the patch, have some questions when I am trying to under= stand the code and also have some review comments. * In hasKerberosCredential methods, add user!=3Dnull check, as it might th= row NPE, when user=3Dnull. * In case of loginuserfromSubject, as we pass params as null to doSubjectL= ogin, the configuration will be OS_SPECIFIC_LOGIN, but if the subject passe= d to=C2=A0this method has keytab and principal, then how login happens. So,= in this case login fallbacks to Simple Auth login? Is this the expected be= havior. ** =C2=A0@Override public AppConfigurationEntry[] getAppConfigurationEntry(String appName) { ArrayList entries =3D new ArrayList<>(); // login of external subject passes no params. technically only // existing credentials should be used but other components expect // the login to succeed with local user fallback if no principal. if (params =3D=3D null || appName.equals(SIMPLE_CONFIG_NAME)) \{ entries.a= dd(OS_SPECIFIC_LOGIN); } ** So, the AppConfigEntry will have loginModule as OS_LOGIN_MODULE, * renewTGT and=C2=A0refreshKrb5Config=C2=A0is not set in IBM_JAVA case, is= there any reason for this? * @Test annotation is missing for tests in=C2=A0TestUGILoginFromKeytab.jav= a * Following 3 methods perform login and update the static loginUser. It mi= ght make sense to add documentation that these update the global loginUser. getLoginUser, loginUserFromSubject and loginUserFromKeytab I am still going through patch, and still reviewing test cases. Will update= if I have more comments. was (Author: bharatviswa): Hi=C2=A0[~daryn] Thank You for the patch. I am going through the patch, have some questions when I am trying to under= stand the code and also have some review comments. * In hasKerberosCredential methods, add user!=3Dnull check, as it might th= row NPE, when user=3Dnull. * In case of loginuserfromSubject, as we pass params as null to doSubjectL= ogin, the configuration will be OS_SPECIFIC_LOGIN, but if it is a subject w= hich has keytab and principal, then how login happens. So, in this case log= in fallbacks to Simple Auth login? Is this the expected behavior. ** =C2=A0@Override public AppConfigurationEntry[] getAppConfigurationEntry(String appName) { ArrayList entries =3D new ArrayList<>(); // login of external subject passes no params. technically only // existing credentials should be used but other components expect // the login to succeed with local user fallback if no principal. if (params =3D=3D null || appName.equals(SIMPLE_CONFIG_NAME)) { entries.add(OS_SPECIFIC_LOGIN); } ** So, the AppConfigEntry will have loginModule as OS_LOGIN_MODULE, * renewTGT and=C2=A0refreshKrb5Config=C2=A0is not set in IBM_JAVA case, is= there any reason for this? * @Test annotation is missing for tests in=C2=A0TestUGILoginFromKeytab.jav= a * Following 3 methods perform login and update the static loginUser. It mi= ght make sense to add documentation that these update the global loginUser. getLoginUser, loginUserFromSubject and loginUserFromKeytab I am still going through patch, and still reviewing test cases. Will update= if I have more comments. > Reduce unnecessary UGI synchronization > -------------------------------------- > > Key: HADOOP-9747 > URL: https://issues.apache.org/jira/browse/HADOOP-9747 > Project: Hadoop Common > Issue Type: Bug > Components: security > Affects Versions: 0.23.0, 2.0.0-alpha, 3.0.0-alpha1 > Reporter: Daryn Sharp > Assignee: Daryn Sharp > Priority: Critical > Attachments: HADOOP-9747-trunk-03.patch, HADOOP-9747-trunk.01.pat= ch, HADOOP-9747-trunk.02.patch, HADOOP-9747.2.branch-2.patch, HADOOP-9747.2= .trunk.patch, HADOOP-9747.branch-2.patch, HADOOP-9747.trunk.patch > > > Jstacks of heavily loaded NNs show up to dozens of threads blocking in th= e UGI. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org For additional commands, e-mail: common-issues-help@hadoop.apache.org