Ownership of newly created objects?

This is a discussion on Ownership of newly created objects? within the Linux Networking forums, part of the Linux Forums category; How do I configure Samba so that any new object created in a particular Samba share always ends up with ...


Go Back   Usenet Forums > Linux Forums > Linux Networking

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 05-20-2004
arabub
 
Posts: n/a
Default Ownership of newly created objects?

How do I configure Samba so that any new object created in a
particular Samba share always ends up with a particular group
ownership?

Example:
- I have a share /home/my_project

- Directory 'contracts' inside the share, and ownership:
# ls -l /home/my_project
drwxrwx--- 2 someuser mygroup 4096 May 11 01:48 contracts

- User 'joe' is has default group 'users', and is member of the group
'mygroup'.

- A new file 'new_file' is created by user 'joe' inside the
my_projects,
folder, and ends up with the following permissions:
# ls -l /home/my_project/contracts
-rwxr-xr-x 1 joe users 529 May 12 04:08 new_file

NOTE: the ownership and permissions on the file that 'joe' created
are
those that 'joe's' user/group and umask dictate.

- The relevant part of smb.conf is:
[my_project]
path = /home/my_project
force group = mygroup
create mask = 0660
directory mask = 0770

What am I doing wrong?

Thanks,
--Ulf
Reply With Quote
  #2 (permalink)  
Old 05-21-2004
Cameron Kerr
 
Posts: n/a
Default Re: Ownership of newly created objects?

In comp.os.linux.networking arabub <arabub@yahoo.com> wrote:
> How do I configure Samba so that any new object created in a
> particular Samba share always ends up with a particular group
> ownership?


> # ls -l /home/my_project
> drwxrwx--- 2 someuser mygroup 4096 May 11 01:48 contracts


An easy way is to make the directory SetGID mygroup, which means that
any new object in that group will get the group membership of the group
of the directory.

but 'force group' ought to work as well, I would think.

--
Cameron Kerr
cameron.kerr@paradise.net.nz : http://nzgeeks.org/cameron/
Empowered by Perl!
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 04:17 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0