I have some scripts where I go and do some LDAP/NIS queries to report on users on Unix servers. What I am trying to figure out is, how do I know which server is the LDAP? The configs have been in place long before I took over so was hoping someone had some insight on how to figure this out. I must admit it has been quite some time since I have touched either, but for the life of me can't remember which files to check to figure this out.
I do know that for NIS I can use the "ypwhich" command to figure out which is the master device and then compare it to the local hostname, what I can't figure out is how to do something similarly slick in the LDAP world.