LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Ldap Confirguation (http://www.linuxquestions.org/questions/linux-newbie-8/ldap-confirguation-4175431683/)

gaurvrishi 10-11-2012 10:06 AM

Ldap Confirguation
 
I am trying to install ldap, but i am getting the error.
/usr/lib/libdb-4.3.so: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make[2]: *** [slapd] Error 1
make[2]: Leaving directory `/usr/local/src/openldap-2.3.32/servers/slapd'
make[1]: *** [all-common] Error 1
make[1]: Leaving directory `/usr/local/src/openldap-2.3.32/servers'
make: *** [all-common] Error 1
[root@tataclassedge openldap-2.3.32]#.

I have download openladp version openldap-2.3.32. I am using CentOS release 5.5 (Final)
Kernel \r on an \m in 32 bit arch. Kindly let me know what need to be update as i need to install it using source code.
I have done
2 STEP : tar -zxvf openldap-stable-20070110.tgz

3 STEP : ./configure --prefix=/usr/local/ldap

4 STEP : make depend ;make install

bathory 10-11-2012 11:09 AM

Quote:

/usr/lib/libdb-4.3.so: could not read symbols: File in wrong format
What gives
Code:

rpm -qa|grep db4
Quote:

4 STEP : make depend ;make install
You need to run just "make" after "make depend" to build the software. If make finishes without errors, then you can (as root) to run "make install" to install it.

gaurvrishi 10-11-2012 11:41 AM

No solution
 
HI,

I have crosscheck but no result found. Getting the same error as previous.

All packages were Install
Kindly tel me know what need to done.

openldap-2.3.32]# rpm -qa|grep db4
db4-devel-4.3.29-10.el5_5.2
db4-4.3.29-10.el5_5.2
db4-utils-4.3.29-10.el5_5.2
db4-4.3.29-10.el5_5.2
db4-devel-4.3.29-10.el5_5.2
db4-tcl-4.3.29-10.el5_5.2
db4-java-4.3.29-10.el5_5.2

bathory 10-11-2012 12:50 PM

Quote:

openldap-2.3.32]# rpm -qa|grep db4
db4-devel-4.3.29-10.el5_5.2
db4-4.3.29-10.el5_5.2
db4-utils-4.3.29-10.el5_5.2
db4-4.3.29-10.el5_5.2
db4-devel-4.3.29-10.el5_5.2
db4-tcl-4.3.29-10.el5_5.2
db4-java-4.3.29-10.el5_5.2
Why there are 2 same development db4 packages? Maybe you have to remove both of them and reinstall the package once.
BTW, why aren't you installing the Centos openldap package from your distro's repo?

gaurvrishi 10-11-2012 12:54 PM

so could you please tel me know how can i remove that duplicate rpm. However if need to install using yum then kindly refer any best link so that i can install Ldap over my server.

bathory 10-11-2012 01:18 PM

I'm not very familiar with rpm, so I don't know how you can uninstall 2 duplicate packages.
Perhaps try
Code:

rpm -e --allmatches --force db4-devel-4.3.29-10.el5_5.2
Regarding installing openldap using yum, have a look at this howto, that is written for openldap with the new config style that is using the slapd.d directory

Regards

Matthew Hardin 10-15-2012 08:51 PM

The "duplicate RPM" thing is most likely because there are 32-bit and 64-bit development packages installed. This is perfectly legal, but RPM doesn't make it easy to see a package's architecture. You can run this form of RPM to display the name and the architecture of all packages:

Code:

rpm -qa --qf "%{n}-%{arch}\n"

The original error is a 32-/64-bit mismatch error- Linking 64-bit objects and finding 32-bit db library is the most likely case.

Centos/Red Hat like to put 64-bit libs in /usr/lib64 and 32-bit libs in /usr/lib. On a 64-bit machine gcc with no -m flag will produce 64-bit object files, but we can clearly see that the linker is looking in /usr/lib and not liking what it finds.

Gcc and the linker are usually smart enough to look in the right place for libraries, so somewhere in what you're doing you're telling the linker to look in /usr/lib instead of /usr/lib64. This could be your --libdir setting in OpenLDAP's configure, or it could be your LDFLAGS environment variable.

One alternative is to disable back-bdb and back-hdb during the configure phase (--disable-bdb --disable-hdb). Instead, enable back-mdb (it is actually enabled by default) and get a screamingly fast database that doesn't require a bunch of arcane cache configuration directives. OpenLDAP won't look for Berkeley DB at all.

Another alternative is to stop messing with all that and just download one of our (free) Symas OpenLDAP Silver packages. We're still at 2.4.32 for Centos/Red Hat and it'll be a few more days before we release a 2.4.33 package.

Hope this helps,

-Matt

Matthew Hardin
Symas - The LDAP Guys
http://www.symas.com

milind_bhavsar 10-16-2012 03:21 AM

Hi gaurvrishi,


This error comes while installing LDAP when your berkeleyDB and openldap versions are mismatch .You have to dowload berkeley db compatible to your your LDAP version .Then you will not get .so files missing or not able to read related errors.

Regards,
Milind

Matthew Hardin 10-16-2012 02:03 PM

Quote:

This error comes while installing LDAP when your berkeleyDB and openldap versions are mismatch .You have to dowload berkeley db compatible to your your LDAP version .Then you will not get .so files missing or not able to read related errors.
With all due respect, No. Gauvrishi is reporting a build problem, not a run-time problem. Pretty much any version of Berkeley DB will work as long as it's less than four years old. That's not to say it's the best version to use, just that it'll build and work.

Cheers,

-Matt

Matthew Hardin
Symas - The LDAP Guys
http://www.symas.com


All times are GMT -5. The time now is 06:28 PM.