Skip to content

RHEL 5: Apache Depends On PostgreSQL Library

Apache HTTP Server

The scenario is I want to install Apache (hereafter also known as httpd) on a basic plain-installed Red Hat Enterprise Linux 5.3 (hereafter known as RHEL 5.3). I thought it was quite straight forward but somehow it didn’t.

I’m using RHEL 5.3,

[root@m020600 ~]# uname -a && cat /etc/redhat-release 
Linux m020600 2.6.18-128.el5 #1 SMP Wed Dec 17 11:42:39 EST 2008 i686 i686 i386 GNU/Linux
Red Hat Enterprise Linux Server release 5.3 (Tikanga)

I mount my RHEL 5.3 DVD and try to install httpd. Crap, it failed with well-known dependencies issue.

[root@m020600 ~]# cd /media/RHEL_5.3\ i386\ DVD/Server/
[root@m020600 Server]# rpm -ivh httpd-2.2.3-22.el5.i386.rpm
warning: httpd-2.2.3-22.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
error: Failed dependencies:
        libapr-1.so.0 is needed by httpd-2.2.3-22.el5.i386
        libaprutil-1.so.0 is needed by httpd-2.2.3-22.el5.i386

So, I try to install httpd with apr and apr-util packages. Damn, it failed too.

[root@m020600 Server]# rpm -ivh httpd-2.2.3-22.el5.i386.rpm \
> apr-1.2.7-11.i386.rpm \
> apr-util-1.2.7-7.el5.i386.rpm 
warning: httpd-2.2.3-22.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
error: Failed dependencies:
        libpq.so.4 is needed by apr-util-1.2.7-7.el5.i386

This time, I installed httpd with apr, apr-util and postgresql-libs. Yay, finally it was working!

[root@m020600 Server]# rpm -ivh httpd-2.2.3-22.el5.i386.rpm \
> apr-1.2.7-11.i386.rpm \
> apr-util-1.2.7-7.el5.i386.rpm \
> postgresql-libs-8.1.11-1.el5_1.1.i386.rpm 
warning: httpd-2.2.3-22.el5.i386.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
Preparing...                ########################################### [100%]
   1:apr                    ########################################### [ 25%]
   2:postgresql-libs        ########################################### [ 50%]
   3:apr-util               ########################################### [ 75%]
   4:httpd                  ########################################### [100%]

Legend
httpd: Apache HTTP Server
apr: Apache Portable Runtime library
apr-util: Apache Portable Runtime Utility library
postgresql-libs: The shared libraries required for any PostgreSQL clients.

httpd depends on apr and apr-util. apr and apr-util depend on postgresql-libs. So, it seems that I’m safe to say Apache (known as httpd) depends on PostgreSQL library in RHEL. wtf!

Comments

{ 11 } Comments

  1. ChristianS | May 6, 2009 at 11:04 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.0.10 on Linux Linux

    Why don’t you use yum?

    yum install httpd

    would have shown you all dependencies at once – not that I’d approve such strange dependencies. It’s a mystery to me too.

    Using Mozilla Firefox Mozilla Firefox 3.0.10 on Linux Linux
  2. Irwan | May 7, 2009 at 9:34 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.0.5 on RedHat Linux RedHat Linux

    Christian,
    This is just a testing machine whereby I don’t have valid RHN subscription.

    Using Mozilla Firefox Mozilla Firefox 3.0.5 on RedHat Linux RedHat Linux
  3. jahor | May 8, 2009 at 4:59 am | Permalink
    Using Konqueror Konqueror 3.5 on Kubuntu Linux Kubuntu Linux

    just create a file ‘/etc/yum.repos.d/iso.repo’ with folowing content
    [rhel-iso]
    name=Red Hat Enterprise Linux $releasever – $basearch – ISO
    baseurl=http://127.0.0.1/iso/Server/
    enabled=1
    gpgcheck=1
    gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release

    if you have another webserver, you could happyli use it. if not, just adopt it nad use another method than http: in baseurl.

    i used this when i was preparing production servers and didn’t have them registered in RHN at that time.

    Using Konqueror Konqueror 3.5 on Kubuntu Linux Kubuntu Linux
  4. ChristianS | May 13, 2009 at 10:02 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.0.10 on Linux Linux

    Irwan, I’m working with CentOS but eventually that’s the same. You don’t need a RHN-subscription in order to use yum. Like jahor wrote, create a .repo-file in /etc/yum.repos.d, set up a local webserver for your repo and you’re fine.

    Using Mozilla Firefox Mozilla Firefox 3.0.10 on Linux Linux
  5. Irwan | May 13, 2009 at 11:35 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.0.10 on RedHat Linux RedHat Linux

    jahor & Christian,
    Thanks for the suggestion. Nevertheless; prior to setup a webserver for my repo, I need to install httpd manually first (unless I can setup a webserver on other machine in advanced). Get what I mean ;)

    Using Mozilla Firefox Mozilla Firefox 3.0.10 on RedHat Linux RedHat Linux
  6. jahor | May 15, 2009 at 1:57 pm | Permalink
    Using Konqueror Konqueror 3.5 on Kubuntu Linux Kubuntu Linux

    hi, if https is missing after the instalation (just the base os is installed) then you could still use “baseurl=file:///media/youriso” in the repo file instead of the http:// path.

    Using Konqueror Konqueror 3.5 on Kubuntu Linux Kubuntu Linux
  7. Irwan | May 16, 2009 at 8:21 pm | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.0.10 on RedHat Linux RedHat Linux

    Thanks for the tips jahor :)

    Using Mozilla Firefox Mozilla Firefox 3.0.10 on RedHat Linux RedHat Linux
  8. ossas | December 18, 2009 at 10:17 pm | Permalink
    Using Internet Explorer Internet Explorer 7.0 on Windows Windows XP

    Thanks for the tips…Very useful help..

    David

    Using Internet Explorer Internet Explorer 7.0 on Windows Windows XP
  9. Jhonatan Rojas | February 9, 2011 at 3:20 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.6.9 on Windows Windows 7

    This post was really helpful.
    But… How did you know that?.. I mean.. “httpd depends on apr and apr-util. apr and apr-util depend on postgresql-libs”.

    Thank you!
    From Lima-Perú

    Using Mozilla Firefox Mozilla Firefox 3.6.9 on Windows Windows 7
  10. Irwan | February 9, 2011 at 4:37 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.6.13 on Windows Windows XP

    Jhonatan,
    Just google what RPM package contains the particular library.

    Using Mozilla Firefox Mozilla Firefox 3.6.13 on Windows Windows XP
  11. Deborah Dawicki | June 19, 2011 at 4:37 am | Permalink
    Using Mozilla Firefox Mozilla Firefox 3.6.17 on RedHat Linux RedHat Linux

    This was very helpful, I appreciate it! I’m onto my 2nd attempt at RHCSA on Jul 1

    Using Mozilla Firefox Mozilla Firefox 3.6.17 on RedHat Linux RedHat Linux

{ 1 } Trackback

  1. Using WordPress WordPress 2.7

    […] See the rest here:  RHEL 5: Apache Depends On PostgreSQL Library […]

Post a Comment

Your email is never published nor shared. Required fields are marked *