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

Ashutosh Chauhan commented on TEZ-4185:
---------------------------------------

Thinking more about this, functionally there is no need to check umask while 
setting permissions since you all always  want to set permissions needed. 
However, checking umask will provide a performance advantage since check is 
in-memory and avoids a system call on local FS when its not needed. Seems like 
after HADOOP-11347 conf's umask can also be used on local fs. So, from that 
perspective I suggest to modify the patch to use correct {{conf}} to keep that 
performance advantage.

> Tez may skip file permission update on intermediate output
> ----------------------------------------------------------
>
>                 Key: TEZ-4185
>                 URL: https://issues.apache.org/jira/browse/TEZ-4185
>             Project: Apache Tez
>          Issue Type: Bug
>    Affects Versions: 0.9.2, 0.10.1, 0.9.3
>            Reporter: Attila Magyar
>            Assignee: Attila Magyar
>            Priority: Major
>         Attachments: TEZ-4185.1.patch
>
>
> Before updating file permissions TEZ check if the permission change is needed 
> with the following conditional:
> {code:java}
> if 
> (!SPILL_FILE_PERMS.equals(SPILL_FILE_PERMS.applyUMask(FsPermission.getUMask(conf))))
>  {
>   rfs.setPermission(filename, SPILL_FILE_PERMS);
> } {code}
> The problem is that the config object used by this conditional can be 
> different than the config used by the file system (rfs). The reason for this 
> is the underlaying file system instance cache in hadoop.
> Either we should remove this conditional altogether (it's a local file 
> system, it won't generate NN calls) or modify it to use rfs.getConf().
> The end result is a file, which is not readable by the group, because the 
> permission change was skipped due to the umask mismatch between the 2 configs.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to