Re: How to replicate the behaviour of /usr/local
Dne, 16. 10. 2009 12:50:43 je Klistvud napisal(a):
> Dne, 16. 10. 2009 12:19:03 je Cameron Hutchison napisal(a):
> > Klistvud <quotations@aliceadsl.fr> writes:
> >
> > >I have a shared directory on my system; what I'd like to achieve
> is
>
> > >making every newly created (or copied from elsewhere) file belong
> to
> > >the group owner "users".
> >
> > # chgrp users /path/to/shared/directory
> > # chmod g+s /path/to/shared/directory
> >
> > The set-group-id bit on a directory causes all files created in
> that
> > directory to take the group id of the directory. Any directories
> > created
> > in that directory also take the group id of the parent directory
> and
> > automatically have the set-group-id bit set on that directory. This
> > causes the group id to propogate down the hierarchy as new
> > directories
> > are created.
> >
> >
> >
> > --
> > To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
> > with a subject of "unsubscribe". Trouble? Contact
> > listmaster@lists.debian.org
> >
> >
> >
>
> Thanx. Your solution, though, only works for newly created files.
> Files
> *copied to* my shared dir from elsewhere still retain their original
> group ownership(s)... That never happens in usr/local.
>
> --
> Certifiable Loonix User #481801
>
>
> --
> To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact
> listmaster@lists.debian.org
>
>
Anybody care to chime in? The question was: how does /usr/local manage
to assign a predefined group ownership to every file you copy to /usr/
local? Can such behaviour be replicated for an arbitrary directory in
my /home subtree?
--
Certifiable Loonix User #481801
Reply to: