Re: [opensuse] cifs files always created as owner root



On 10/11/2011 8:57 AM, lynn wrote:
I mount this share on a client:

[users]
comment = home folders
inherit acls = Yes
path = /home
read only = No

using this:

mount -t cifs //192.168.1.2/users /home -o rw,setuid

I then login as a user on the client authenticated via ldap. No problem. It
takes me to the mounted folder and I can see my files. When I create a file it
creates it as owner root:root. Not what I want!

How can I create files on the mount as user:group no matter who logs in?
Thanks. L x



I fought this battle some years ago, and the problem, as best I can recall was
that the normal cifs mount of a samba share would have the client trying to
set permissions and uids. This only works when uids are matched among all workstations
(the NFS mindset).

I found it necessary to force the mount commands to not allow the local workstation
to attempt to manage permissions and UIDs of files it creates on a server share.

I believe the noperm and nosetuids parameters were the key to this, but
that was at a site which I no longer manage, so I can't check on this for you.
Man mount.cifs sees to suggest this is the approach needed to allow the samba
server to manage permissions and ownership.

--
_____________________________________
---This space for rent---
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: opensuse+owner@xxxxxxxxxxxx



Relevant Pages

  • Re: [opensuse] cifs files always created as owner root
    ... trying to set permissions and uids. ... This only works when uids are matched ... the samba server to manage permissions and ownership. ...
    (SuSE)
  • Re: Why my users cant change their home folder permissions while they ...
    ... If they want to change the permissions in order to accomplish ... sharing, then provide server based sharing areas that meet their ... permission on their home folders, but one day they told me ... can't change z: drive permissions. ...
    (microsoft.public.windows.server.security)
  • Re: Permissions
    ... to create the home folders manually and assign permissions ... >> What's the best approach to the following scenario? ... >> permissions for each user eclusively. ... >> with Win2K3 permissions. ...
    (microsoft.public.windows.file_system)
  • Re: Script to set share permissions on home directories
    ... I have a directory with ~1600 home folders in it that have incorrect ... Administrators - full control ... NTFS permissions are fine, its just the share permissions that need ...
    (microsoft.public.windows.server.scripting)
  • [opensuse] cifs files always created as owner root
    ... I then login as a user on the client authenticated via ldap. ... creates it as owner root:root. ... How can I create files on the mount as user:group no matter who logs in? ...
    (SuSE)