Jeff called me up asking for help with his dedicated server on Godaddy. He needed to update his PHP 5.1.6 to the latest stable version. His server is running Centos 5.2 (Final). He tried to call Godaddy for assistance and of course they were no help. I’m no expert myself but have played around with different systems. I found out that you can use the yum command to manage the installed packages. The problem is that the current repositories yum looks at does not contain new versions of PHP. This is why you get an error that says something like – cannot find PHP. What you need to do is add a repository that does have a newer version of PHP. We’re going to add Jason Litka‘s repository.
- Log in to the Simple Control Panel
- Log in using SSH
- Type “su – ” to log in with root privileges
- Type “nano -w /etc/yum.repos.d/utterramblings.repo”. If you’re not comfortable with nano, use whatever editor you’re more comfortable with.
- In the utterramblings.repo file type the following [utterramblings] name=Jason’s Utter Ramblings Repo baseurl=http://www.jasonlitka.com/media/EL$releasever/$basearch/ enabled=1 gpgcheck=1 gpgkey=http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka
- Save the file and close it
- Now you can use “yum update php” and it should update it to the latest that the repositories have
- Restart Apache
This tutorial is based on the one found at http://www.jasonlitka.com/yum-repository/. It took awhile for me to find the solution. I hope this helps out people who had the same problem as I did.
Show 12 comments
Comments
These comments were left on the original blog post. Comments are now closed — see About for how to get in touch.
↑ Back to top