Return-Path: X-Original-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-common-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 EF21711534 for ; Wed, 9 Jul 2014 19:45:06 +0000 (UTC) Received: (qmail 54868 invoked by uid 500); 9 Jul 2014 19:45:06 -0000 Delivered-To: apmail-hadoop-common-issues-archive@hadoop.apache.org Received: (qmail 54793 invoked by uid 500); 9 Jul 2014 19:45:06 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-issues@hadoop.apache.org Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 54634 invoked by uid 99); 9 Jul 2014 19:45:06 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Jul 2014 19:45:06 +0000 Date: Wed, 9 Jul 2014 19:45:06 +0000 (UTC) From: "Colin Patrick McCabe (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (HADOOP-10806) ndfs: need to implement umask, pass permission bits to hdfsCreateDirectory MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HADOOP-10806?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14056656#comment-14056656 ] Colin Patrick McCabe commented on HADOOP-10806: ----------------------------------------------- This patch adds some code for parsing {{fs.permissions.umask-mode}} and sending permission bits in the {{hdfsCreateDirectory}} rpc to the NameNode. This fixes a bug whereby {{hdfsCreateDirectory}} would fail with this message: {code} org.apache.hadoop.native.HadoopCore.IOException: conn_process_response: error com.google.protobuf.UninitializedMessageException: Message missing required fields: masked.perm at com.google.protobuf.AbstractMessage$Builder.newUninitializedMessageException(AbstractMessage.java:770) {code} Clearly we'll also need this for the file write path, when we're creating new files. We don't handle "fancy" {{fs.permissions.umask-mode}} values like "rw-r--r--" etc. yet. It's not too difficult to do that, but it's better to do it in a follow-on JIRA to avoid complicating this one. For now, we just deal with numeric umasks. > ndfs: need to implement umask, pass permission bits to hdfsCreateDirectory > -------------------------------------------------------------------------- > > Key: HADOOP-10806 > URL: https://issues.apache.org/jira/browse/HADOOP-10806 > Project: Hadoop Common > Issue Type: Sub-task > Components: native > Affects Versions: HADOOP-10388 > Reporter: Colin Patrick McCabe > Assignee: Colin Patrick McCabe > Attachments: HADOOP-10806-pnative.001.patch > > > We need to pass in permission bits to {{hdfsCreateDirectory}}. Also, we need to read {{fs.permissions.umask-mode}} so that we know what to mask off of the permission bits (umask is always implemented client-side) -- This message was sent by Atlassian JIRA (v6.2#6252)