LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-14-2003, 02:40 PM   #1
tarballed
Member
 
Registered: Jun 2002
Distribution: RH, FC, FreeBSD,OpenBSD
Posts: 326

Rep: Reputation: 30
Exclamation Shared libraries question...need help


Hello everyone. I have a question on shared libraries.
I was installing some software and everything went fine, until I tried to execute the problem.

Here is what happened when I tried to run the program:

error while loading shared libraries: liblber.so.2: cannot open shared object file: No such file or directory

So I did a whereis to see where liblber.so.2 is which returned this:

liblber.so: /usr/local/lib/liblber.so.2 /usr/local/lib/liblber.so

My question is, what do I need to do to correct this so I can run the program?
Secondly, can someone explain to me what the problem is and how to correct this/learn from this so if I run into this again in the future, I know how to correc t it.

Thanks

Tarballed
 
Old 03-14-2003, 03:46 PM   #2
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,697

Rep: Reputation: 232Reputation: 232Reputation: 232
It looks you don't have /usr/local/lib in LD_LIBRARY_PATH variable or ld.so.conf file. They work the same way as PATH for executables. When your library is not in one of them, it cannot be easily used (without the whole path).

The easiest solution: add '/usr/local/lib' to ld.so.conf and run 'ldconfig' (to re-read the file).
 
Old 03-14-2003, 04:22 PM   #3
tarballed
Member
 
Registered: Jun 2002
Distribution: RH, FC, FreeBSD,OpenBSD
Posts: 326

Original Poster
Rep: Reputation: 30
Mara,

Thanks for your help. I remember having a similar problem before. I had thought I entered the correct information into the ld.so.conf file, but I actually put the full path. Whoops!

Once I put the full path in and ran ldconfig, it fixed it.

Do you happen to have any links that explain this in more detail? I would like to know more about this file so I can increase my knowledge.

Thanks.

Tarballed
 
Old 03-15-2003, 01:04 PM   #4
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,697

Rep: Reputation: 232Reputation: 232Reputation: 232
man ldconfig
I don't know any other links. The idea is very simple and I hope the man page has all the info you need.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
error while loading shared libraries: libstdc++.so.5: cannot open shared object file: Franziss Linux - Newbie 10 06-28-2010 05:47 AM
Urgent !!! rpm: error while loading shared libraries: libelf.so.1: cannot open shared tinaa Linux - Software 5 12-02-2008 03:19 PM
shared libraries question rhb327 Slackware 2 09-23-2005 10:49 AM
error while loading shared libraries: libdb-4.1.so: cannot open shared object file putquery8581 Linux - Software 1 10-01-2004 07:03 AM
mplayer: error while loading shared libraries: libdvdread.so.3: cannot open shared ob Bruce Hill Slackware 6 12-11-2003 08:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration