Improve the active loop that waits for the samba LDAP task to start