Results 1 to 5 of 5
Hello all, long time lurker, first time poster. Sorry to bug you, but I'm stumped and could use an assist.
I'm running RHEL5 w/ Apache 2.
I was updating my ...
- 12-08-2009 #1Just Joined!
- Join Date
- Dec 2009
- Posts
- 4
Httpd won't start -- shared library not found
Hello all, long time lurker, first time poster. Sorry to bug you, but I'm stumped and could use an assist.
I'm running RHEL5 w/ Apache 2.
I was updating my virtual hosts in httpd.conf and needed to restart Apache. Httpd stopped and then returned the following error message upon attempting restart:
Starting httpd: /usr/sbin/httpd: error while loading shared libraries: libpcre.so.0: cannot open shared object file: No such file or directory [FAILED]
I figured at first that I messed something up in httpd.conf, so I restored the backup and the error persisted.
So I tried the following: ldd /usr/sbin/httpd
Sure enough:
libpcre.so.0 => not found
So I ran yum to install/update and was informed the package was already installed and up to date
Next I tried looking for the file:
ls -l `locate libpcre.so.0` which showed that the file does exist
/lib/libpcre.so.0 -> libpcre.so.0.0.1
/lib/libpcre.so.0.0.1
So I ran rm /etc/ld.so.cache ; /sbin/ldconfig, but that didn't work either. ldd still shows it as 'not found'.
I'm not sure what even caused the problem. The server has been stable forever and aside from some routine updates, nothing has been changed (or at least there's no sign of foul play at the moment).
I'm running out of ideas here and I need to get this server back online. Can anyone lend a hand? Thanks!!
- 12-08-2009 #2Just Joined!
- Join Date
- Nov 2009
- Posts
- 6
does the ldd output show other libraries that are located in /lib/?
- 12-08-2009 #3Just Joined!
- Join Date
- Dec 2009
- Posts
- 4
Yes. Here's the full ldd:
# ldd /usr/sbin/httpd
linux-gate.so.1 => (0x00660000)
libm.so.6 => /lib/libm.so.6 (0x00110000)
libpcre.so.0 => not found
libselinux.so.1 => not found
libaprutil-1.so.0 => not found
libcrypt.so.1 => /lib/libcrypt.so.1 (0x0067f000)
libldap-2.3.so.0 => not found
liblber-2.3.so.0 => not found
libdb-4.3.so => not found
libexpat.so.0 => /lib/libexpat.so.0 (0x008a3000)
libapr-1.so.0 => not found
libpthread.so.0 => /lib/libpthread.so.0 (0x008fc000)
libdl.so.2 => /lib/libdl.so.2 (0x00d14000)
libc.so.6 => /lib/libc.so.6 (0x002c1000)
/lib/ld-linux.so.2 (0x007bd000)
Whatever is going on, it looks like I'm going to have to fix a few other libraries after libpcre, too =/
- 12-08-2009 #4Just Joined!
- Join Date
- Dec 2009
- Posts
- 4
Update:
Hmm. I had a look at my /etc/ld.so.conf file and there was no reference to /lib there. So I created a httpd-test.conf file in /etc/lib.so.conf.d/ and then reran ldconfig and now libpcre shows up in ldd!!
Of course now httpd is grousing about libselinux.so.1
(which also happens to live in /lib, yum says it's up to date, and ls -l `locate libselinux.so.1` shows it in /lib).
- 12-08-2009 #5Just Joined!
- Join Date
- Dec 2009
- Posts
- 4
Found it! SELinux was enabled and messing everything up. I have no idea how it re-enabled itself (perhaps one of the updates?), but disabling it fixed the problem. ldd no longer shows 'no found', displays the missing dependencies that weren't even in the list, and most importantly /sbin/services httpd start works.
Hopefully this thread can/will help someone else out in the future.


Reply With Quote