[Samba] samba4 | access ldap, what password

Rowland Penny rowlandpenny at googlemail.com
Mon Nov 11 03:15:44 MST 2013


On 11/11/13 09:53, mourik jan heupink wrote:
>> I would like to browse my new samba4 ldap directory, and I am completely
>> in the dark in what share to provide my credentials. Anonymous access
> in what SHAPE I meant
>
> Anyway: I learned quite a bit using tdbdump on DC=SAMBA,DC=EXAMPLE,DC=COM
>
> I found out the correct form for my administrator account and can 
> logon. However I can still see only bits of my directory tree. No 
> CN=users, for example. (however using 
> CN=users,DC=SAMBA,DC=EXAMPLE,DC=COM as a base DN works, meaning there 
> are more CN's than I can see)
>
> What account should I use to browse the WHOLE directory? (sorry for 
> the very very basic questions)
>
> MJ
HI, What are you actually trying to do? Samba 4 is not actually ldap, it 
is AD and as such, whilst you can use ldap tools it is often better to 
use the tools that samba supplies i.e. ldbsearch instead of ldapsearch.

ldbsearch --url=/usr/local/samba/private/sam.ldb > /root/samba.ldif

Will give the same result as

ldapsearch -x -h 127.0.0.1 -b DC=example,DC=com -D 
CN=Administrator,CN=Users,DC=example,DC=com -w <yoursamba4password> > 
/root/samba.ldif

They will both dump the entire AD directory to a file.

Rowland


More information about the samba mailing list