aryangupta1998 opened a new pull request, #12193:
URL: https://github.com/apache/ozone/pull/12193

   ## What changes were proposed in this pull request?
   
   Problem
   ofs and o3fs always report files as 666 (readable by everyone), even when 
ACLs allow only the owner to read them.
   
   Some applications trust this value. For example, Spark and MapReduce on YARN 
check whether a job's staging files are readable by everyone. If they are, the 
files are treated as public, and the NodeManager downloads them as its own user 
instead of the job's user. With ACLs enabled, the NodeManager user has no 
access to the job owner's files, so the download fails and the job fails before 
it starts:
   
   ```
   PERMISSION_DENIED ... User yarn doesn't have READ permission to access key
   Volume:user Bucket:alice 
Key:.sparkStaging/application_<id>/__spark_conf__.zip
   ```
   Giving the NodeManager user read access to all users' files works around 
this, but it exposes private job files through the NodeManager's shared public 
cache.
   
   Proposed change
   Add a client setting, ozone.fs.file.permission.reported (default 666, so 
nothing changes unless it is set). With ACLs enabled, setting it to 600 makes 
files appear owner-only, so YARN downloads them as the job's user and the job 
works. Directories are still reported as 777.
   
   This only changes the reported value. Access is still controlled by ACLs.
   
   ## What is the link to the Apache JIRA
   
   https://issues.apache.org/jira/browse/HDDS-17951
   
   ## How was this patch tested?
   
   Unit and Integration Tests.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to