I simulated conditions close to what you described and in my case it was caused by database config not being defined in slapd.conf. Ldapwhoami returns proper response, ldap search on anything but cn=config returns proper response, cn=config search returns err 32 no such object and Apache is unable to connect at all. Sounds about right... Make sure that you do have database config defined either way (slapd.conf or slap.d via ldif) with proper access definition to it by either rootdn or access to.
Hope it is all you need to do.
Best regards