Installing PHP5.4 on Centos 5.8

10,547

That's because download.fedoraproject.org is redirecting to a mirror. RPM in RHEL 5 doesn't follow that (yet). Try to replace it with a direct hostname (dl.fedoraproject.org for example).

Share:
10,547
user1032531
Author by

user1032531

Updated on June 23, 2022

Comments

  • user1032531
    user1032531 almost 2 years

    Attempting to upgrade from PHP 5.3 to 5.4 using a tutorial found at http://www.how2centos.com/installing-php-5-4-on-centos-5-8/. I basically says to do the following:

    yum install yum-priorities
    rpm -Uvh http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
    rpm -Uvh http://dl.iuscommunity.org/pub/ius/stable/Redhat/5/x86_64/ius-release-1.0-10.ius.el5.noarch.rpm
    yum install php54 php54-common php54-devel 
    

    When executing the second line, I get the following error:

    [root@localhost ~]# rpm -Uvh http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
    Retrieving http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm
    error: skipping http://download.fedoraproject.org/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm - transfer failed - Unknown or unexpected error
    warning: u 0xc073650 ctrl 0xc074a20 nrefs != 0 (download.fedoraproject.org http)
    

    What am I doing wrong? Thanks

  • user1032531
    user1032531 over 11 years
    rpm -Uvh dl.fedoraproject.org/pub/epel/5/x86_64/… worked. First had to remove old PHP using yum remove php php-cgi php-cli php-common