Rotten mud: centos6 yum kernel upgrade, centos6yum

Source: Internet
Author: User

Rotten mud: centos6 yum kernel upgrade, centos6yum

This document consistsIlanniwebProviding friendship sponsorship, first launchedThe world

For more articles, follow my ilanniweb

I haven't written any articles for a long time recently. Today, because I need to install docker to learn about virtual containers, I need to upgrade the OS kernel. Currently, I am using centos 2.6 and the kernel version, as shown below:

Cat/etc/issue

Uname-r

Because docker requires more than 3.0 Kernel support, and 2.6 kernel can also be used, there may be uncontrollable problems at that time, so we need to upgrade the kernel version.

To upgrade the kernel OS to 3.1 or above, follow these steps.

1. Install the yum source of elrepo

To upgrade the kernel, you need to use the elrepo yum source. Before installing the yum source, you also need to import the elrepo key, as shown below:

Rpm -- import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org

Rpm-Uvh http://www.elrepo.org/elrepo-release-6-6.el6.elrepo.noarch.rpm

After the elrepo key is installed, we will officially upgrade the kernel.

Ii. Upgrade the kernel

In yum elrepo, there are two types of kernels: ml and lt. Among them, ml (mainline) is the latest kernel version, and lt is a long-term supported kernel.

To install the ml kernel, run the following command:

Yum -- enablerepo = elrepo-kernel-y install kernel-ml

To install the lt kernel, run the following command:

Yum -- enablerepo = elrepo-kernel-y install kernel-lt

Here we install the lt kernel, as shown below:

The grub. conf file does not take effect immediately after the kernel is upgraded.

3. Modify the grub. conf file

After the kernel is upgraded, we need to modify the kernel startup sequence. The default boot sequence should be 1. After the upgrade, the kernel is inserted to the front as 0, as shown below:

Vim/etc/grub. conf

Default = 0

4. restart the system and view the system kernel

After the grub. conf file is modified, restart the system as follows:

Shutdown-r now

After the system is started, check the kernel version as follows:

Uname-r

We can easily see that centos6.5 has been upgraded to version 3.10.

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.