[ 
https://issues.apache.org/jira/browse/HDFS-7563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14262480#comment-14262480
 ] 

Hadoop QA commented on HDFS-7563:
---------------------------------

{color:red}-1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12689720/HDFS-7563.001.patch
  against trunk revision e7257ac.

    {color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

    {color:green}+1 tests included{color}.  The patch appears to include 1 new 
or modified test files.

    {color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

    {color:green}+1 javadoc{color}.  There were no new javadoc warning messages.

    {color:green}+1 eclipse:eclipse{color}.  The patch built with 
eclipse:eclipse.

    {color:red}-1 findbugs{color}.  The patch appears to introduce 2 new 
Findbugs (version 2.0.3) warnings.

    {color:green}+1 release audit{color}.  The applied patch does not increase 
the total number of release audit warnings.

    {color:red}-1 core tests{color}.  The patch failed these unit tests in 
hadoop-common-project/hadoop-common:

                  org.apache.hadoop.metrics2.impl.TestMetricsSystemImpl
                  
org.apache.hadoop.security.token.delegation.web.TestWebDelegationToken

Test results: 
https://builds.apache.org/job/PreCommit-HDFS-Build/9137//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HDFS-Build/9137//artifact/patchprocess/newPatchFindbugsWarningshadoop-common.html
Console output: https://builds.apache.org/job/PreCommit-HDFS-Build/9137//console

This message is automatically generated.

> NFS gateway parseStaticMap NumberFormatException
> ------------------------------------------------
>
>                 Key: HDFS-7563
>                 URL: https://issues.apache.org/jira/browse/HDFS-7563
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: nfs
>    Affects Versions: 2.6.0
>         Environment: HDP 2.2
>            Reporter: Hari Sekhon
>            Assignee: Yongjun Zhang
>         Attachments: HDFS-7563.001.patch, UID_GID_Long_HashMaps.patch
>
>
> When using the new NFS UID mapping for the HDFS NFS gateway I've discovered 
> that my Windows 7 workstation at this bank is passing UID number 4294xxxxxx 
> but entering this in the /etc/nfs.map in order to remap that to a Hadoop UID 
> prevents the NFS gateway from restarting with the error message:
> {code}Exception in thread "main" java.lang.NumberFormatException: For input 
> string: "4294xxxxxx"
>         at 
> java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
>         at java.lang.Integer.parseInt(Integer.java:495)
>         at java.lang.Integer.parseInt(Integer.java:527)
>         at 
> org.apache.hadoop.security.ShellBasedIdMapping.parseStaticMap(ShellBasedIdMapping.java:318)
>         at 
> org.apache.hadoop.security.ShellBasedIdMapping.updateMaps(ShellBasedIdMapping.java:229)
>         at 
> org.apache.hadoop.security.ShellBasedIdMapping.<init>(ShellBasedIdMapping.java:91)
>         at 
> org.apache.hadoop.hdfs.nfs.nfs3.RpcProgramNfs3.<init>(RpcProgramNfs3.java:176)
>         at org.apache.hadoop.hdfs.nfs.nfs3.Nfs3.<init>(Nfs3.java:45)
>         at org.apache.hadoop.hdfs.nfs.nfs3.Nfs3.startService(Nfs3.java:66)
>         at org.apache.hadoop.hdfs.nfs.nfs3.Nfs3.main(Nfs3.java:72)
> {code}
> The /etc/nfs.map file simply contains
> {code}
> uid 4294xxxxxx 1yyyy
> {code}
> It seems that the code at 
> {code}hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/ShellBasedIdMapping.java{code}
> is expecting an integer at line 318 of the parseStaticMap method: {code}int 
> remoteId = Integer.parseInt(lineMatcher.group(2));
> int localId = Integer.parseInt(lineMatcher.group(3));{code}
> This UID does seem very high to me but it has worked successfully on a 
> MapR-FS NFS share and stores files created with that UID over NFS.
> The UID / GID mappings for the HDFS NFS gateway will need to be switched to 
> using Long to accomodate this, I've attached a patch for the parsing and 
> UID/GID HashMaps.
> Regards,
> Hari Sekhon
> http://www.linkedin.com/in/harisekhon



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to