Article 57EWF [SOLVED] [openLdap 2.4.40] LDAP connecting to wrong IP/host after clone VPS

[SOLVED] [openLdap 2.4.40] LDAP connecting to wrong IP/host after clone VPS

by
jonaskellens
from LinuxQuestions.org on (#57EWF)
Hello

using LDAP v2.4.40 on CentOS.

I have taken a clone "slap02" of a running LDAP-server (VPS) "slap01".

Now I notice that LDAP can not connect :
Code:[root@slap02 openldap]# ldapsearch -x -d 1
ldap_create
ldap_sasl_bind
ldap_send_initial_request
ldap_new_connection 1 1 0
ldap_int_open_connection
ldap_connect_to_host: TCP slap01.domain.tld:389
ldap_new_socket: 3
ldap_prepare_socket: 3
ldap_connect_to_host: Trying 11.22.33.44:389
ldap_pvt_connect: fd: 3 tm: -1 async: 0
attempting to connect:
connect errno: 111
ldap_close_socket: 3
ldap_int_open_connection
ldap_connect_to_host: TCP slap01.domain.tld:636
ldap_new_socket: 3
ldap_prepare_socket: 3
ldap_connect_to_host: Trying 11.22.33.44:636
ldap_pvt_connect: fd: 3 tm: -1 async: 0
attempting to connect:
connect errno: 111
ldap_close_socket: 3
ldap_err2string
ldap_sasl_bind(SIMPLE): Can't contact LDAP server (-1)Where can I adjust these parameters that 'ldap_connect_to_host' uses ?!

So I can point to the correct address.

For info, hostname has been changed after cloning :
Code:[root@slap02 openldap]# hostname
slap02.domain.tldCode:[root@slap02 openldap]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain
99.88.77.66 slap02.domain.tld slap02But LDAP proces does not see this.latest?d=yIl2AUoC8zA latest?i=7tFv-LiyNp0:TePzgCpXaXI:F7zBnMy latest?i=7tFv-LiyNp0:TePzgCpXaXI:V_sGLiP latest?d=qj6IDK7rITs latest?i=7tFv-LiyNp0:TePzgCpXaXI:gIN9vFw7tFv-LiyNp0
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments