ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Speidel" <jspei...@hortonworks.com>
Subject Re: Review Request 29459: JobHistoryServer Fails to pass service check in Kerberized cluster
Date Mon, 05 Jan 2015 15:59:13 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29459/#review66650
-----------------------------------------------------------

Ship it!



ambari-server/src/main/java/org/apache/ambari/server/controller/AuthToLocalBuilder.java
<https://reviews.apache.org/r/29459/#comment110220>

    "ro" -> "or"



ambari-server/src/main/java/org/apache/ambari/server/controller/AuthToLocalBuilder.java
<https://reviews.apache.org/r/29459/#comment110224>

    if matches() returns true, I don't think that principal can be null or empty can it?
    
    If it can't be null/empty, the check should be removed as it makes the code less understandable
since a reader will assume that the value could be null.



ambari-server/src/main/java/org/apache/ambari/server/controller/AuthToLocalBuilder.java
<https://reviews.apache.org/r/29459/#comment110225>

    if matches() returns true, I don't think that principal can be null or empty can it?



ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelper.java
<https://reviews.apache.org/r/29459/#comment110228>

    need to use braces for body of if block, not the one line form.


- John Speidel


On Dec. 29, 2014, 9:27 p.m., Robert Levas wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/29459/
> -----------------------------------------------------------
> 
> (Updated Dec. 29, 2014, 9:27 p.m.)
> 
> 
> Review request for Ambari, John Speidel, Robert Nettleton, and Yusaku Sako.
> 
> 
> Bugs: AMBARI-8935
>     https://issues.apache.org/jira/browse/AMBARI-8935
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> JobHistoryServer Fails to pass service check in Kerberized cluster due to kerberos to
local account mapping failure 
> 
> ```
> org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.security.AccessControlException):
Permission denied: user=jhs, access=READ_EXECUTE, inode="/mr-history/done/2014":mapred:hadoop:drwxrwx---
> ```
> 
> `core-site` `auth_to_local` fails to map `jhs/_HOST` to `mapred` user.  
> 
> The solution is to dynamically create auth_to_local configuration based on kerberos descriptors.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/AuthToLocalBuilder.java
PRE-CREATION 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/KerberosHelper.java
c7d08cc 
>   ambari-server/src/main/java/org/apache/ambari/server/state/kerberos/KerberosPrincipalDescriptor.java
70bd396 
>   ambari-server/src/main/resources/stacks/HDP/2.2/services/FALCON/kerberos.json 827ce46

>   ambari-server/src/main/resources/stacks/HDP/2.2/services/HBASE/kerberos.json 4b6213e

>   ambari-server/src/main/resources/stacks/HDP/2.2/services/HDFS/kerberos.json 52c7d37

>   ambari-server/src/main/resources/stacks/HDP/2.2/services/OOZIE/kerberos.json 9cb24ca

>   ambari-server/src/main/resources/stacks/HDP/2.2/services/YARN/kerberos.json 7677a7a

>   ambari-server/src/test/java/org/apache/ambari/server/controller/AuthToLocalBuilderTest.java
PRE-CREATION 
>   ambari-server/src/test/java/org/apache/ambari/server/state/kerberos/KerberosPrincipalDescriptorTest.java
a35bad3 
>   ambari-server/src/test/resources/stacks/HDP/2.0.8/kerberos.json 64c7a8c 
>   ambari-server/src/test/resources/stacks/HDP/2.0.8/services/HDFS/kerberos.json 7271b36

> 
> Diff: https://reviews.apache.org/r/29459/diff/
> 
> 
> Testing
> -------
> 
> Manually tested on test cluster - JobHistoryServer sometimes fails the service check,
but appears to be unrelated to the auth_to_local mapping issue.
> 
> Added new test case: `org.apache.ambari.server.controller.AuthToLocalBuilderTest`
> Updated existing test case: `org.apache.ambari.server.state.kerberos.KerberosPrincipalDescriptorTest`
> 
> Waiting for Jenkins server for test results - issues with rat check in truck not related
to this patch.
> 
> Ran tests locally.
> 
> Running org.apache.ambari.server.controller.AuthToLocalBuilderTest
> Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.066 sec
> 
> Running org.apache.ambari.server.state.kerberos.KerberosPrincipalDescriptorTest
> Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.141 sec
> 
> Ambari Server test results
> Tests run: 2469, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 28:17.957s
> [INFO] Finished at: Mon Dec 29 11:27:34 EST 2014
> [INFO] Final Memory: 40M/568M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Robert Levas
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message