Centos 6/7 Source Upgrade kernel

Source: Internet
Author: User
CentOS Source Upgrade Kernel method
Recently in the research Docker, need to upgrade the kernel, below the way to upgrade the kernel.
1. Download kernel source
Download URL for https://www.kernel.org/I use for version 3.10 download address for

Https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.12.44.tar.xz

Download command:

# wget https://www.kernel.org/pub/linux/kernel/v3.x/linux-

3.12.44.tar.xz

2. Extract source code

# TAR-XVF LINUX-3.12.44.TAR.XZ

# CD LINUX-3.12.44.TAR.XZ

3. Update system and install dependent software
# Yum Update

# Yum Upgrade

# yum Groupinstall Development Tools

# yum Install Ncurses-develqt-develhmaccalc zlib-devel binutils-devel

Elfutils-libelf-devel

4. Copy the current kernel configuration file to the current directory
Use the following command to view the kernel version

# Uname-r

3.10.0-229.1.2.el7.x86_64

Copy the corresponding kernel configuration file to the current directory

#cp/boot/config-3.10.0-229.1.2.el7.x86_64. config

The kernel version behind/boot/config-is the kernel version you just queried.

centos6.5 The default version is 2.6 Centos7 version is 3.10

5. Using the current kernel configuration
# sh-c ' Yes ' | Make Oldconfig ' #centos6中使用这个命令

# sh-c ' Y ' | Make Oldconfig ' #centos7中使用这个命令
6. Compile and install
# Make Bzimage

# Make Modules

# Make Modules_install

# make Install


Compiling the installation process may be slow please wait patiently

7. Modify Grub Modification Order
# vim/etc/grub.conf

Find the location of your new installation kernel, usually the first one, if the first one, set default = 0

Centos7 do not need to modify default to first boot entry

8. Restart the computer
# reboot










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.