LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 10-29-2009, 10:21 AM   #1
TheYanster
LQ Newbie
 
Registered: Oct 2009
Posts: 16

Rep: Reputation: 0
httpd: error while loading shared libraries: libaprutil-1.so.0


Hi,

This is my first post, so forgive me if I sound a little noobish. I have searched the Web for the answer I'm looking for and so far I haven't found anything that pertains to my issue.

My environment:

I'm running Apache/PHP/MySQL on an intranet development server. I support the application (Apache), but not the server itself, so I don't have root access. Everything we support on that server is installed from source and contained in the /data filesystem (using ./configure --prefix=[PATH] ...) using a generic account we su to. We can't use any package management software because of this (since you can't specify the prefix with them).

Apache is installed in my case in /data/apache-2.2.3, and linked as /data/apache.

Note: The server is running RHEL 4 ES, and doesn't have access to the Internet.

My problem:

Recently, I had to upgrade PHP, which meant recompiling it completely including some of the dependencies I needed (such as libpng, freetype, libmcrypt, libmhash, etc...).

Those libraries were previously not installed at all, or were installed in their own folder right at the root of /data. I didn't like this so I used a different prefix when I recompiled them so they are all under /data/lib/[lib_name].

To make sure Apache would still be able to find the shared libraries, I linked the old directories to the new locations (deleted the dirs and created symlinks instead with the same name).

For example, the apr library was installed in /data/apr-httpd, and I compiled the new one in /data/lib/apr, and then created /data/apr-httpd as a link pointing to it.

That didn't work so well... After restarting Apache, I got this error:
Code:
/data/apache-2.2.3/bin/httpd: error while loading shared libraries: libaprutil-1.so.0: cannot open shared object file: No such file or directory
I don't understand why it can't find it since the file it's looking for is in the /data/lib/apr-util/lib folder, and that the original folder it was in is linked properly to the new one!?

I managed to work around the issue by adding a direct link to libaprutil-1.so.0 in /data/apache/modules, but I would rather like not having to do this.

My question(s):

So what can I do to fix this properly without having to recompile Apache with --with-apr-util=/data/lib/apr-util and --with-apr=/data/lib/apr ?

Is there something I can just add in the httpd.conf file?

Last edited by TheYanster; 10-29-2009 at 10:25 AM.
 
Old 11-03-2009, 01:01 PM   #2
jphilput
Member
 
Registered: Nov 2007
Posts: 58

Rep: Reputation: 15
Is it possible that this might be a permissions issue? Every time I've run into a similar issue the problem has turned out to be either problems with the file ownership, or problems with the permissions.
 
Old 11-03-2009, 01:26 PM   #3
WhisperiN
Member
 
Registered: Jun 2009
Location: Middle East
Distribution: Slackware 13.1, CentOS 5.5
Posts: 137

Rep: Reputation: 17
Quote:
Originally Posted by jphilput View Post
Is it possible that this might be a permissions issue? Every time I've run into a similar issue the problem has turned out to be either problems with the file ownership, or problems with the permissions.
Same thing here.. lol..
 
Old 11-03-2009, 04:47 PM   #4
TheYanster
LQ Newbie
 
Registered: Oct 2009
Posts: 16

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by jphilput View Post
Is it possible that this might be a permissions issue? Every time I've run into a similar issue the problem has turned out to be either problems with the file ownership, or problems with the permissions.
It wasn't that, the permissions were the same as before, both owner and group and all the other flags were identical.

Either way, I ended up restoring a backup of that entire filesystem to revert the changes. I'll have to play around with it later if I want to do the same.

Consider this issue somewhat resolved.
 
Old 11-03-2009, 06:58 PM   #5
gpm1982
LQ Newbie
 
Registered: Apr 2008
Posts: 3

Rep: Reputation: 0
Talking Fixing the missing shared libraries issue

Not quite related to PHP, but I did experience this issue when running Blender3D (open source 3D software). What I did was I edited the file
Quote:
/etc/ld.so.conf
by adding the path where the shared library resides, and then I run the command
Quote:
ldconfig
to reload the shared libraries. After that, I get to run Blender3D successfully.
For more info, check this site: http://linux.die.net/man/8/ldconfig

Hope this helps
 
  


Reply

Tags
apache, configure, error


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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are 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
error while loading shared libraries: libhid.so.0: cannot open shared object file: No misungs Linux - Software 4 06-10-2009 12:05 PM
Urgent !!! rpm: error while loading shared libraries: libelf.so.1: cannot open shared tinaa Linux - Software 5 12-02-2008 03:19 PM
gxine: error while loading shared libraries: libmozjs.so: cannot open shared object.. empcrono Slackware 10 11-10-2008 07:33 PM
error while loading shared libraries: libgvc.so.3: cannot open shared object file coolrock Slackware 6 01-17-2007 05:10 PM


All times are GMT -5. The time now is 10:20 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration