You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Suresh Srinivas (JIRA)" <ji...@apache.org> on 2010/04/29 00:23:51 UTC

[jira] Created: (HADOOP-6731) Octal umask with less than 3 digits is not interpreted correctly

Octal umask with less than 3 digits is not interpreted correctly
----------------------------------------------------------------

                 Key: HADOOP-6731
                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
             Project: Hadoop Common
          Issue Type: Bug
    Affects Versions: 0.21.0, 0.22.0
            Reporter: Suresh Srinivas
            Assignee: Suresh Srinivas
             Fix For: 0.22.0


Octal umask 7 is interpreted as 700 instead of 007. Octal umask 77 is interpreted as 770 instead of 077.

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


[jira] Updated: (HADOOP-6731) Octal umask with less than 3 digits is not handled

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

Suresh Srinivas updated HADOOP-6731:
------------------------------------

        Summary: Octal umask with less than 3 digits is not handled  (was: Octal umask with less than 3 digits is not interpreted correctly)
    Description: Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.  (was: Octal umask 7 is interpreted as 700 instead of 007. Octal umask 77 is interpreted as 770 instead of 077.)

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Commented: (HADOOP-6731) Octal umask with less than 3 digits is not handled

Posted by "Jakob Homan (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12862331#action_12862331 ] 

Jakob Homan commented on HADOOP-6731:
-------------------------------------

Yep, we should fix it for both umask and permissions to be consistent. If so, this is a good change to make. 

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Updated: (HADOOP-6731) Octal umask with less than 3 digits is not handled

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

Suresh Srinivas updated HADOOP-6731:
------------------------------------

    Attachment:     (was: HADOOP-6713.patch)

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Commented: (HADOOP-6731) Octal umask with less than 3 digits is not handled

Posted by "Eli Collins (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12862027#action_12862027 ] 

Eli Collins commented on HADOOP-6731:
-------------------------------------

+1  Looks good to me.

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Commented: (HADOOP-6731) Octal umask with less than 3 digits is not handled

Posted by "Jakob Homan (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12862043#action_12862043 ] 

Jakob Homan commented on HADOOP-6731:
-------------------------------------

If this change goes through, we should update the documentation in FsShell.java (in common):
{noformat}      "\tMODE\tMode is same as mode used for chmod shell command.\n" +
      "\t\tOnly letters recognized are 'rwxXt'. E.g. +t,a+r,g-w,+rwx,o=r\n\n" +
      "\tOCTALMODE Mode specifed in 3 or 4 digits. If 4 digits, the first may\n" +
      "\tbe 1 or 0 to turn the sticky bit on or off, respectively.  Unlike " +
      "\tshell command, it is not possible to specify only part of the mode\n" +{noformat}
Eli - it's always good to consider the other components as well!

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Commented: (HADOOP-6731) Octal umask with less than 3 digits is not handled

Posted by "Suresh Srinivas (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12862321#action_12862321 ] 

Suresh Srinivas commented on HADOOP-6731:
-----------------------------------------

Currently UmaskParser does not parse sticky bit. So do you see any concern in allowing less than 3 digit umask?

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Updated: (HADOOP-6731) Octal umask with less than 3 digits is not interpreted correctly

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

Suresh Srinivas updated HADOOP-6731:
------------------------------------

    Component/s: fs

> Octal umask with less than 3 digits is not interpreted correctly
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>
> Octal umask 7 is interpreted as 700 instead of 007. Octal umask 77 is interpreted as 770 instead of 077.

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


[jira] Updated: (HADOOP-6731) Octal umask with less than 3 digits is not handled

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

Suresh Srinivas updated HADOOP-6731:
------------------------------------

    Attachment: HADOOP-6713.patch

Attached patch:
# Handle single digit and two digit octal umasks
# Interprets them and applies them correctly as in the description.

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6713.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Commented: (HADOOP-6731) Octal umask with less than 3 digits is not handled

Posted by "Suresh Srinivas (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12862329#action_12862329 ] 

Suresh Srinivas commented on HADOOP-6731:
-----------------------------------------

On HDFS we do not support set-user-ID-on-execution-bit. On linux all the following is support for chmod:
7, 77, 777, 1777. Should we make chmod parser also consistent with this? I feel we should either change both creation umask and chmod umask or leave both of them as it is. Any thoughts?

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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


[jira] Updated: (HADOOP-6731) Octal umask with less than 3 digits is not handled

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

Suresh Srinivas updated HADOOP-6731:
------------------------------------

    Attachment: HADOOP-6731.patch

Renaming the patch with correct jira number.

> Octal umask with less than 3 digits is not handled
> --------------------------------------------------
>
>                 Key: HADOOP-6731
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6731
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs
>    Affects Versions: 0.21.0, 0.22.0
>            Reporter: Suresh Srinivas
>            Assignee: Suresh Srinivas
>             Fix For: 0.22.0
>
>         Attachments: HADOOP-6731.patch
>
>
> Umasks with less than three digits should be accepted as valid umask. Umask with single digit, say 7, should be handled as 007. Similarly umask with two digits, say 77, should be handled as 077.

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