Support Questions
Find answers, ask questions, and share your expertise

ambari-server sync-ldap --all

Hi, there is a question about ambari-server sync-ldap.
When I execute ambari-server sync-ldap --all there is no user created or updated. My operation as follows:

[root@bigdata013 centos]# ambari-server stop
Using python  /usr/bin/python
Stopping ambari-server
Ambari Server stopped
[root@bigdata013 centos]# ambari-server setup-ldap
Using python  /usr/bin/python
Setting up LDAP properties...
Primary URL* {host:port} ( 
Secondary URL {host:port} : 
Use SSL* [true/false] (false): 
User object class* (posixAccount): 
User name attribute* (uid): 
Group object class* (posixGroup): 
Group name attribute* (cn): 
Group member attribute* (memberUid): 
Distinguished name attribute* (dn): 
Base DN* (dc=istuary,dc=com): 
Referral method [follow/ignore] : 
Bind anonymously* [true/false] (false): 
Manager DN* (uid=admin,ou=People,dc=istuary,dc=com): 
Enter Manager Password* : 
Re-enter password: 
Review Settings
authentication.ldap.managerDn: uid=admin,ou=People,dc=istuary,dc=com
authentication.ldap.managerPassword: *****
Save settings [y/n] (y)? y
Ambari Server 'setup-ldap' completed successfully.
[root@bigdata013 centos]# ambari-server start
Using python  /usr/bin/python
Starting ambari-server
Ambari Server running with administrator privileges.
Organizing resource files at /var/lib/ambari-server/resources...
Ambari database consistency check started...
No errors were found.
Ambari database consistency check finished
Server PID at: /var/run/ambari-server/
Server out at: /var/log/ambari-server/ambari-server.out
Server log at: /var/log/ambari-server/ambari-server.log
Waiting for server start....................
Ambari Server 'start' completed successfully.
[root@bigdata013 centos]# ambari-server sync-ldap --all
Using python  /usr/bin/python
Syncing with LDAP...
Enter Ambari Admin login: admin
Enter Ambari Admin password: 
Syncing all...
Completed LDAP Sync.

    removed = 0
    created = 0
    updated = 0
    removed = 0
    created = 0
    updated = 0
    removed = 0
    created = 0

Ambari Server 'sync-ldap' completed successfully.

Hi @Zhao Chaofeng,

I believe the problem is with your base dn, it seems that with the one provided there is no user matching your parameters. Based on your manager dn, you may want to try with


as base dn if all your users are in People ou.

Hope this helps.


OK, I retry as yours. Thank.