You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Andrew Wang (JIRA)" <ji...@apache.org> on 2013/07/24 04:46:48 UTC

[jira] [Commented] (HDFS-5026) getFileStatus and getFileLinkStatus do not properly handle intermediate symlinks in a path

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

Andrew Wang commented on HDFS-5026:
-----------------------------------

Eli chatted with me about this one, and we decided it's not really a bug. getFileStatus/getFileLinkStatus are supposed to be like stat(2), not stat(1). We only recently got inodes in HDFS, so FileStatus was using this path for a similar purpose to an inode #. Thus, this path is meant to be opaque.

I suspect there's be code out there making incorrect assumptions about this path, but these functions themselves are not in error.
                
> getFileStatus and getFileLinkStatus do not properly handle intermediate symlinks in a path
> ------------------------------------------------------------------------------------------
>
>                 Key: HDFS-5026
>                 URL: https://issues.apache.org/jira/browse/HDFS-5026
>             Project: Hadoop HDFS
>          Issue Type: Bug
>    Affects Versions: 3.0.0, 2.1.0-beta
>            Reporter: Andrew Wang
>
> Imagine a filesystem with the following:
> {noformat}
> /dir
> /dir/file
> /dirLink -> /dir
> {noformat}
> When calling getFileStatus or getFileLinkStatus on {{/dirLink/file}}, the returned FileStatus incorrectly has the resolved path of {{/dir/file}}. This differs from expectations and the Unix {{stat(1)}} command, which would return {{/dirLink/file}}.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira