[Samba] share access problem with %G

Miguel Da Silva - Servicio de Informática cibonato at fcien.edu.uy
Fri Aug 11 21:09:39 GMT 2006


On Sat, 12 Aug 2006 00:14:37 +0800
"Jacky Chan" <bigserpent at gmail.com> wrote:

> Hi Jerry,
> 
> I followed the example (
> http://de.samba.org/samba/docs/man/Samba-Guide/small.html) to study Samba.
> The configuration is came from the Samba example and I may not fully
> understood the configuration.
> 
> I have a unix user "jackyacct" and assigned "acctsdep" as primary group.
> 
> The unix directory access right is 775 and the group owner is "acctsdep".
> 
> The example mentioned "Network users will be given access to these shares by
> way of group membership".
> 
> Is %G means, all user within the group can access the share "accounts" ?
> 
> I have tried %G and it does't work, after I did some research, I changed it
> to @unixgroup and it work finally.
> 
> What %G means in this Samba example ?
> 
> On 8/11/06, Gerald (Jerry) Carter <jerry at samba.org> wrote:
> >
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA1
> >
> > Jacky Chan wrote:
> >
> > > [finsvcs]
> > > comment = Financial Service Files
> > > path = /data/finsvcs
> > > valid users = %G
> > > read only = No
> >
> > This makes no sense.  It says to only allow whatever the user's
> > primary group is.  What are you trying to achieve?
> >
> >
> >
> >
> > cheers, jerry

%G returns the primary group of an user and "valid users" accepts @<group_name> as a valid value (there are others). I've never tested something like "@%G".

At smb.conf man page you'll find an explanation of how this stanza works, the values you can use and also how they can be used.

If used correctly it will help you a lot.

Good luck.

-- 
Miguel Da Silva.
Servicio de Informatica.
Facultad de Ciencias.


More information about the samba mailing list