Return-Path: X-Original-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id F03E79E32 for ; Sun, 11 Mar 2012 19:11:19 +0000 (UTC) Received: (qmail 45087 invoked by uid 500); 11 Mar 2012 19:11:19 -0000 Delivered-To: apmail-hadoop-hdfs-issues-archive@hadoop.apache.org Received: (qmail 44947 invoked by uid 500); 11 Mar 2012 19:11:18 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hdfs-issues@hadoop.apache.org Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 44889 invoked by uid 99); 11 Mar 2012 19:11:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 Mar 2012 19:11:17 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 11 Mar 2012 19:11:03 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id BF5E51A112 for ; Sun, 11 Mar 2012 19:10:41 +0000 (UTC) Date: Sun, 11 Mar 2012 19:10:41 +0000 (UTC) From: "Todd Lipcon (Resolved) (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: <1228803743.510.1331493041802.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1581845800.48845.1331450638776.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Resolved] (HDFS-3074) HDFS ignores group of a user when creating a file or a directory, and instead inherits MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HDFS-3074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Todd Lipcon resolved HDFS-3074. ------------------------------- Resolution: Won't Fix For whatever strange historic reason, Hadoop uses BSD semantics instead of Linux semantics for group ownership at creation. I filed this "bug" once, too :) > HDFS ignores group of a user when creating a file or a directory, and instead inherits > -------------------------------------------------------------------------------------- > > Key: HDFS-3074 > URL: https://issues.apache.org/jira/browse/HDFS-3074 > Project: Hadoop HDFS > Issue Type: Bug > Components: name-node > Affects Versions: 0.23.1 > Reporter: Harsh J > Priority: Minor > > When creating a file or making a directory on HDFS, the namesystem calls pass {{null}} for the group name, thereby having the parent directory permissions inherited onto the file. > This is not how the Linux FS works at least. > For instance, if I have today a user 'foo' with default group 'foo', and I have my HDFS home dir created as "foo:foo" by the HDFS admin, all files I create under my directory too will have "foo" as group unless I chgrp them myself. This makes sense. > Now, if my admin were to change my local accounts' default/primary group to 'bar' (but did not change so on my homedir on HDFS, and I were to continue writing files to my home directory or any subdirectory that has 'foo' as group, all files still get created with group 'foo' - as if the NN has not realized the primary group of the mapped shell account has already changed. > On linux this is the opposite. My login session's current primary group is what determines the default group on my created files and directories, not the parent dir owner. > If the create and mkdirs call passed UGI's group info (UserGroupInformation.getCurrentUser().getGroupNames()[0] should give primary group?) along into their calls instead of a null in the PermissionsStatus object, perhaps this can be avoided. > Or should we leave this as-is, and instead state that if admins wish their default groups of users to change, they'd have to chgrp all the directories themselves? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira