You are viewing a plain text version of this content. The canonical link for it is here.
Posted to mapreduce-issues@hadoop.apache.org by "Devaraj Das (JIRA)" <ji...@apache.org> on 2010/03/02 21:21:27 UTC

[jira] Created: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

UGI.doAs should not be used for getting the history file of jobs
----------------------------------------------------------------

                 Key: MAPREDUCE-1550
                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
             Project: Hadoop Map/Reduce
          Issue Type: Bug
          Components: jobtracker
    Affects Versions: 0.22.0
            Reporter: Devaraj Das
             Fix For: 0.22.0


When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Vinod K V (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vinod K V updated MAPREDUCE-1550:
---------------------------------

        Status: Resolved  (was: Patch Available)
    Resolution: Invalid

Ravi and I sat together to see if it is really valid on trunk. And we reached the conclusion that it isn't after an elaborate analysis of the order of patches that went into trunk and yahoo distribution.

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>            Assignee: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch, 1550.trunk.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Ravi Gummadi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ravi Gummadi updated MAPREDUCE-1550:
------------------------------------

    Status: Patch Available  (was: Reopened)

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>            Assignee: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch, 1550.trunk.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Ravi Gummadi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ravi Gummadi reopened MAPREDUCE-1550:
-------------------------------------


ugi.doAs() is there JSPUtil.getJobInfo() in current trunk also. So this fix needs to go into trunk also.

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>            Assignee: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Devaraj Das (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Devaraj Das updated MAPREDUCE-1550:
-----------------------------------

    Attachment: 1550-2.patch

This patch fixes a bug to do with getting the right user for the authorization check.

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Devaraj Das (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Devaraj Das updated MAPREDUCE-1550:
-----------------------------------

    Attachment: 1550-2.1.patch

Fixes a bug in the earlier patch (assumes the earlier patch)

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Ravi Gummadi (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ravi Gummadi updated MAPREDUCE-1550:
------------------------------------

    Attachment: 1550.trunk.patch

Attaching patch for trunk.
 This is forward port of merge of 1550-2.patch and 1550-2.1.patch to trunk. A small change needed to TestJobRetire because JSPUtil.getJobInfo() is used there.

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>            Assignee: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch, 1550.trunk.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Devaraj Das (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12840503#action_12840503 ] 

Devaraj Das commented on MAPREDUCE-1550:
----------------------------------------

I should add that at the point where the ugi for the remote user is constructed, the JobTracker doesn't have the tokens to add to it. In contrast, during job submission (in the JobInProgress constructor), the remote user's credentials are available and the ugi created there is populated with it. That ugi is then used to talk to the namenode. 

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Vinod K V (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Vinod K V resolved MAPREDUCE-1550.
----------------------------------

    Resolution: Invalid

This bug is there not on trunk but on the ydist branch for which patch was attached at MAPREDUCE-1455. Closing this as invalid.

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Jakob Homan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jakob Homan reassigned MAPREDUCE-1550:
--------------------------------------

    Assignee: Devaraj Das

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>            Assignee: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch, 1550-2.1.patch, 1550-2.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (MAPREDUCE-1550) UGI.doAs should not be used for getting the history file of jobs

Posted by "Devaraj Das (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MAPREDUCE-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Devaraj Das updated MAPREDUCE-1550:
-----------------------------------

    Attachment: 1550-1.patch

This fixes the problem. The problem is that, in a secure env, the FileSystem.get() would require user's credentials to talk to the NameNode if the get() was done within a UGI.doAs. Removing the doAs would mean that the JobTracker's credentials would be used which is the right thing to do since the JobHistory files are owned by the JobTracker anyway..

> UGI.doAs should not be used for getting the history file of jobs
> ----------------------------------------------------------------
>
>                 Key: MAPREDUCE-1550
>                 URL: https://issues.apache.org/jira/browse/MAPREDUCE-1550
>             Project: Hadoop Map/Reduce
>          Issue Type: Bug
>          Components: jobtracker
>    Affects Versions: 0.22.0
>            Reporter: Devaraj Das
>             Fix For: 0.22.0
>
>         Attachments: 1550-1.patch
>
>
> When the jobtracker tries to open a job history file it does a doAs to get the filesystem for the user (that had submitted the job). This should not be done since the job history files are owned by the jobtracker.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.