From owner-freebsd-questions@FreeBSD.ORG Tue Mar 7 06:47:24 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2EA5416A420 for ; Tue, 7 Mar 2006 06:47:24 +0000 (GMT) (envelope-from jahilliya@gmail.com) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.202]) by mx1.FreeBSD.org (Postfix) with ESMTP id C145543D64 for ; Tue, 7 Mar 2006 06:47:20 +0000 (GMT) (envelope-from jahilliya@gmail.com) Received: by wproxy.gmail.com with SMTP id i27so1328675wra for ; Mon, 06 Mar 2006 22:47:20 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=bS+jO8pPYqvn5/JJTRwBxtyw0io/gFjo2cPJulzkAnCyHHyUIAMOBQ/j/pHaIOSJl60JKdEq+ensQfQYRgsdEznB+9zvX1/ZekRV1znrnSjDtUjW07mkhL+PyZCVj5kq7J/JeZIkrPfZp6g1+kGSalN/bufLmQvfDbhxnqQGSxY= Received: by 10.64.241.6 with SMTP id o6mr3041488qbh; Mon, 06 Mar 2006 22:47:19 -0800 (PST) Received: by 10.64.180.6 with HTTP; Mon, 6 Mar 2006 22:47:19 -0800 (PST) Message-ID: Date: Tue, 7 Mar 2006 14:47:19 +0800 From: Jahilliya To: "Pat Maddox" In-Reply-To: <810a540e0603062240m5491666eva12060fb4eeea61f@mail.gmail.com> MIME-Version: 1.0 References: <810a540e0603062240m5491666eva12060fb4eeea61f@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: FreeBSD Questions Subject: Re: A question on permissions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Mar 2006 06:47:24 -0000 On 3/7/06, Pat Maddox wrote: > > I want to make a directory writable by one user, and readable by > another. It should be owned by the web server UID, and the group > should be the gid of my normal login user. > > %ls -ld /home/pergesu/logs > drwxr-x--- 6 www pergesu 512 Feb 23 13:05 /home/pergesu/logs > > However, the www user apparently can't read/write to that dir. I gave > 'www' a real shell just to try it out: > %sudo su www > %ls -ld /home/pergesu/logs > ls: /home/pergesu/logs: Permission denied > > I don't get why it's doing Permission denied there. www has r/w/x > access to that dir. It doesn't, however, have read access to > /home/pergesu, so that's my only guess. I don't want to make > /home/pergesu readable by everyone though of course. Isn't that what > permissions are all about? Unfortunately, if you cannot access any given directory, you cannot access any of it's children either. For anything to access /home/pergesu/logs the user must have execute permissions on /home/pergesu (not read). Jal.