From owner-freebsd-questions@FreeBSD.ORG Fri May 12 14:00:02 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 2273416A59F for ; Fri, 12 May 2006 14:00:02 +0000 (UTC) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from mail5.sea5.speakeasy.net (mail5.sea5.speakeasy.net [69.17.117.7]) by mx1.FreeBSD.org (Postfix) with ESMTP id 49EB043D48 for ; Fri, 12 May 2006 13:59:56 +0000 (GMT) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: (qmail 18945 invoked from network); 12 May 2006 13:59:55 -0000 Received: from dsl092-078-145.bos1.dsl.speakeasy.net (HELO be-well.ilk.org) ([66.92.78.145]) (envelope-sender ) by mail5.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 12 May 2006 13:59:55 -0000 Received: by be-well.ilk.org (Postfix, from userid 1147) id BD8F628425; Fri, 12 May 2006 09:59:54 -0400 (EDT) To: "Derrick Ryalls" References: From: Lowell Gilbert Date: Fri, 12 May 2006 09:59:54 -0400 In-Reply-To: (Derrick Ryalls's message of "Thu, 11 May 2006 18:38:56 -0700") Message-ID: <44hd3vl4x1.fsf@be-well.ilk.org> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: FreeBSD Questions Subject: Re: New folder permissions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: FreeBSD Questions List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 May 2006 14:00:03 -0000 "Derrick Ryalls" writes: > I am having issues getting correct permissions set for files in a > common area on a web/file server. I have webroot shared out via samba > and under there I have an auto-thumbnail generation script that > creates thumbnails in somefolder/.cache where somefolder is a newly > created folder. Example: > > autothumbs\ > mypics1\ > image.jpg > .cache > image_thumb.jpg > mypics2\ > .cache > ... > > What needs to happen is when a new folder is created under this > autothumb tree, the permissions need to be set correctly so that the > .cache folder can be automatically generated by the thumbnail process. > I have the main folder listed as root:wheel 777 but when new folders > are created they have user:wheel 755 permissions and the thumbnail > script fails as it cannot write to the location. > > Is there something I am missing to get this setup properly? I know a > workaround is the manually change the permissions of the folder when > it is created, but since my wife will be wanting to add pictures, that > isn't an option for her (very non-techy). The machine in question a > 5.4-Stable box. > > Any suggestions on what I need to do? There are a lot of ways to do this, but the one I would recommend is to change the main folder to be owned by a group that you, your wife, and the uid running the thumbnail script all are members of -- probably by creating a new group for the purpose. Then if you set your wife's umask to 002, directories she creates will be available to you and any other members of the group.