Use Yum to Upgrade PHP and MySQL in centos)

Source: Internet
Author: User
Tags gpg vps
Upgrade PHP and MySQL in centos with yum
After umvps is used, many times you have to deal with the virtual host without doing anything on your own, such as upgrading PHP and MySQL. Because you don't need to do it yourself, you cannot do it. Therefore, binggu is not sure whether the PHP and MySQL of the VM will be updated in a timely manner. However, if you use VPs, you can do it for a while to ensure security. binggu is happy to update it. The following describes how to use Yum to Upgrade PHP and MySQL in centos:
Yum is a tool that comes with centos to conveniently add, delete, and update RPM packages. It automatically solves the dependency problem of packages.
To update PHP with Yum, you only need to use one command:
# Yum update PHP
But the problem arises. After using this command, the system tells me that no updatable package is found. The current PHP version is only 5.2.1, and PHP has been officially updated to 5.2.6.
After some inquiry, I realized that PHP is still 5.2.1 In the original centos system source, and an additional source is required to Upgrade PHP.
According to foreign netizens, binggu adds additional sources:
After logging on to SSH, run the following commands in sequence:
# Rpm -- import http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka
# Vi/etc/yum. Repos. d/utterramblings. Repo #
In this article, Nano is used, but VPs cannot start Nano. It is also possible to use VI instead.
Add the following content to the open document:
[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.
Run the following command again to complete the PHP upgrade.
# Yum update PHP
Similarly, run the following command to upgrade MySQL
# Yum update MySQL

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.