From owner-freebsd-questions@FreeBSD.ORG Fri Sep 22 20:38:23 2006 Return-Path: X-Original-To: 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 2FC6B16A407 for ; Fri, 22 Sep 2006 20:38:23 +0000 (UTC) (envelope-from calebflynn@gmail.com) Received: from carter.lisco.com (carter.lisco.com [69.18.32.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id D996E43D53 for ; Fri, 22 Sep 2006 20:38:22 +0000 (GMT) (envelope-from calebflynn@gmail.com) Received: from [192.168.10.148] (69-18-51-220.lisco.net [69.18.51.220]) by carter.lisco.com (Postfix) with ESMTP id 2CD0B5480F; Fri, 22 Sep 2006 15:38:22 -0500 (CDT) Message-ID: <451449BD.4000601@gmail.com> Date: Fri, 22 Sep 2006 15:38:21 -0500 From: Caleb Flynn User-Agent: Thunderbird 1.5.0.2 (Windows/20060308) MIME-Version: 1.0 To: questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Subject: File and folder 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: Fri, 22 Sep 2006 20:38:23 -0000 Hello list, This has probably come up before, but I can't seem to find any entries for it. I'm helping a new public radio station to implement a shared music library via NFS (& Samba for 1 Windows box) on 6.1. The library needs to be accessible by everyone in the station, and we'd like volunteers to be able to write files to the library, but not delete them. Files will be organized into folders by artist first name: library/a/artist/album/track.ogg. I found this: http://www.greenend.org.uk/rjk/2004/perms.html Some platforms, e.g. FreeBSD, optionally take note of the setuid bit on a directory: any files or directories created in that directory use the directory's user ID as their user ID and new directories have the setuid bit turned on. I've tried this approach and it does not seem to work, or maybe I'd doing something wrong. The setup is: drwsrwxr-x 2 test2 wheel 512 Sep 22 02:16 test When I create a file as another user i get this: -rw-r--r-- 1 test1 wheel 0 Sep 22 01:39 uid When I create a directory: drwxr-xr-x 2 test2 wheel 512 Sep 22 15:29 yo The other problem is that if the folder is writable by the group then I can `rm -R test` and I can override the deletion for files inside the folder, but not the folder itself: override rwxr-xr-x test2/wheel for /test/yo? y $ ls -l /test total 0 Any thoughts or tips regarding the method I describe or another method that will be appreciated. Thanks, Caleb