LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-29-2004, 11:44 AM   #1
TexasDex
Member
 
Registered: Feb 2003
Location: The Attic. Nowhere near Texas.
Distribution: Gentoo, Kubuntu, formerly LFS, SuSE, and RedHat
Posts: 133

Rep: Reputation: 15
Error loading shared libraries--everything's broken!


When I boot up my computer, a whole lot of services that rely on shared libraries fail to load, with some variation of the following message:

Code:
 
Starting sshd:/usr/sbin/sshd: error while loading shared libraries:
libkrb5.so.3: cannot open shared object file: No such file or director
[FAILED]
But all of the files that they need do exist, in the same directories as they've always been in:
Code:
[root@Meg root]# locate libkrb5.so.3
/usr/kerberos/lib/libkrb5.so.3.1
/usr/kerberos/lib/libkrb5.so.3
[root@Meg root]#
It all started when I tried to install the latest version of Enlightenment on my RH8 server. I got the latest RPM, then downloaded the src tarball for imlib2. I didn't notice if it failed (with the following error message) or not, so I installed it, and then installed the enlightenment RPM, forcing it to ignore dependencies because rpm never seems to detect it when I compile something from the tarball. But it had compiled without PNG support, so I had to install the newest version of that. When I finally was able to start compiling it with PNG support, it gave me the following error message:
Code:
gcc -g -O2 -o .libs/imlib2 main.o  -L/usr/X11R6/lib ../src/.libs/libImlib2.so
/usr/bin/ld: warning: libXext.so.6, needed by
../src/.libs/libImlib2.so, not found (try using -rpath or -rpath-link)
Then things started failing left and right. I quit enlightenment and tried to open TWM, only to find that:
Code:
twm: error while loading shared libraries: libX11.so.6:
cannot open shared object file: No such file or directory
Enlightenment failed with the same message. I tried going to INIT 3 and back to init 5, and X seemed to start normally, but when I put my password in, I got booted back to the graphical login screen, even when trying to login to xterm-only mode. So I killed a 90+ day uptime and rebooted, only to find that most of my services failed to start because of the error message at the top!

Because of something I vaugely remember from trying LFS a while back, I ran this command to see if my dynamic loader was still there:
Code:
[root@Meg imlib2-1.1.2]# readelf -l /bin/cat | grep interpreter
      [Requesting program interpreter: /lib/ld-linux.so.2]
The file exists, in fact all of the required files seem to exist and be in the right places, so I really don't know what else to do

HELP!

Last edited by TexasDex; 12-29-2004 at 11:51 AM.
 
Old 12-29-2004, 04:14 PM   #2
Ironica
Member
 
Registered: Jan 2003
Distribution: LFS
Posts: 64

Rep: Reputation: 15
Is the path to the libraries (/usr/kerberos/lib) in /etc/ld.so.conf ? If not, add it, run ldconfig, and try again. If it's already there, try running ldconfig anyway. Also, try adding the path to the LD_LIBRARY_PATH variable.

I experienced some weird problems, which were quite similar, and this worked for me.
 
Old 12-29-2004, 04:15 PM   #3
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 53
the only thing i can think of is a
chmod -R
gone bad bogus permission bobulation

or destroyed /etc/ld.so.conf and it's binaries made with "ldconfig"
easy enough to rebuild to see
 
Old 12-29-2004, 04:34 PM   #4
TexasDex
Member
 
Registered: Feb 2003
Location: The Attic. Nowhere near Texas.
Distribution: Gentoo, Kubuntu, formerly LFS, SuSE, and RedHat
Posts: 133

Original Poster
Rep: Reputation: 15
I don't know how it happened, but it turns out that I had somehow reset my /etc/ld.so.conf file. Adding the required paths to it and running ldconfig worked nicely. Big thanks!
 
  


Reply



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 Off
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
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
linux init error in loading shared shared libraries akaran Linux - Software 1 05-28-2003 04:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:03 PM.

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
Open Source Consulting | Domain Registration