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

zhihai xu commented on HADOOP-9989:
-----------------------------------

Hi [~tucu00], I just found out the "mapreduce.job.credentials.binary" 
configuration parameter need a path name without URI Scheme. 
{code}
    String binaryTokenFilename =
      conf.get("mapreduce.job.credentials.binary");
    if (binaryTokenFilename != null) {
      Credentials binary = Credentials.readTokenStorageFile(
          new Path("file:///" + binaryTokenFilename), conf);
      credentials.addAll(binary);
    }
{code}
the MR will add scheme "file:///" to the parameter,
I update a new patch HADOOP-9989.addendum0.patch to fix this issue:
use p.toUri().getPath() to remove the URI Scheme.
Please review it.
thanks
zhihai

> Bug introduced in HADOOP-9374, which parses the -tokenCacheFile as binary 
> file but set it to the configuration as JSON file.
> ----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HADOOP-9989
>                 URL: https://issues.apache.org/jira/browse/HADOOP-9989
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: security, util
>    Affects Versions: 2.1.0-beta
>         Environment: Red Hat Enterprise 6 with Sun Java 1.7 and IBM Java 1.6
>            Reporter: Jinghui Wang
>            Assignee: zhihai xu
>             Fix For: 2.6.0
>
>         Attachments: HADOOP-9989.001.patch, HADOOP-9989.addendum0.patch, 
> HADOOP-9989.patch
>
>   Original Estimate: 0h
>  Remaining Estimate: 0h
>
> The code in JIRA HADOOP-9374's patch introduced a bug, where the value of the 
> tokenCacheFile parameter is being parsed as a binary file and set it to the
> mapreduce.job.credentials.json parameter in GenericOptionsParser, which 
> cannot be parsed by JobSubmitter when it gets the value.



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

Reply via email to