Re: [Samba] Unable to add a particular member to group (Samba 4.6.3)
- Date: Tue, 25 Apr 2017 20:07:13 +0100
- From: Rowland Penny via samba <samba@xxxxxxxxxxxxxxx>
- Subject: Re: [Samba] Unable to add a particular member to group (Samba 4.6.3)
On Tue, 25 Apr 2017 14:31:51 -0400
Luc Lalonde <Luc.Lalonde@xxxxxxxxxx> wrote:
> The user exists in AD:
> - I can see the user using 'wbinfo', 'samba-tool user list'
> - I can add the user to a group with 'Active Directory Users and
> Computers' in Windows 2008R2
> - It's seems impossible to use 'samba-tool group addmembers foogroup
> I looked at the user's attributes but can't find anything different
> from any other user that works properly.
> Any other ideas?
The code that is failing (if it is the code) is this:
for member in members:
targetmember = self.search(base=self.domain_dn(), scope=ldb.SCOPE_SUBTREE,
expression="(|(sAMAccountName=%s)(CN=%s))" % (
ldb.binary_encode(member), ldb.binary_encode(member)), attrs=)
if len(targetmember) != 1:
raise Exception('Unable to find "%s". Operation
cancelled.' % member)
I have a thought, but can you post the AD object of the failing user,
you can sanitize it if you like, but please keep context
You can send it to me off list, if you would rather not post it online.
To unsubscribe from this list go to the following URL and read the