The kernel is the interactive work between application software and computer hardware
The kernel is the interactive work between application software and computer hardware. In computer science, the kernel (English: kernel) is also called the core. It is a computer program used to manage the data I/O (input and output) requirements issued by the software. These requirements are translated into data processing instructions, which are processed by the central processing unit (CPU) and other electronic components in the computer, which are the most basic parts of modern operating systems.
It is a part of software that provides secure access to computer hardware for many applications. This access is limited, and the kernel determines when and how long a program operates on a certain part of the hardware. It is very complicated to operate directly on the hardware. So the kernel usually provides a hardware abstraction method to complete these operations. Through the inter-process communication mechanism and system calls, the application process can indirectly control the required hardware resources (especially processors and IO devices).
yum update -y
# Import public key
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
# Install version 6 of ELRepo
rpm -Uvh elrepo-release-6-8.el6.elrepo.noarch.rpm
# Install a new version of the kernel
yum --enablerepo=elrepo-kernel install kernel-lt -y
Currently only the kernel-lt version of the kernel is provided in the centos6 version, and the latest kernel is 4.4.17 (as of 20190121)
https://elrepo.org/linux/kernel/el6/x86_64/RPMS/
cp /etc/grub.conf{,.bak}
vim /etc/grub.conf
Modify the default to 0
reboot
yum update -y
# Import public key
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
# Installation 7.x version of ELRepo
rpm -Uvh https://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
# Install a new version of the kernel
yum --enablerepo=elrepo-kernel install kernel-lt -y
Currently, two versions of the kernel, ml and lt, are provided for cetnos 7.x, and you can choose according to your needs:
https://elrepo.org/linux/kernel/el7/x86_64/RPMS/
After the Centos7.x kernel is upgraded, you need to modify the boot sequence of the kernel:
vim /etc/default/grub
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved #Change the saved here to 0
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="crashkernel=auto rhgb quiet net.ifnames=0"
GRUB_DISABLE_RECOVERY="true"
Next, you need to run the grub2-mkconfig
command to recreate the kernel configuration. The command is grub2-mkconfig -o /boot/grub2/grub.cfg
, as follows:
grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file ...
Found linux image:/boot/vmlinuz-4.17.171-1.el7.elrepo.x86_64
Found initrd image:/boot/initramfs-4.17.171-1.el7.elrepo.x86_64.img
Found linux image:/boot/vmlinuz-3.10.0-693.2.2.el7.x86_64
Found initrd image:/boot/initramfs-3.10.0-693.2.2.el7.x86_64.img
Found linux image:/boot/vmlinuz-3.10.0-693.el7.x86_64
Found initrd image:/boot/initramfs-3.10.0-693.el7.x86_64.img
Found linux image:/boot/vmlinuz-0-rescue-f0f31005fb5a436d88e3c6cbf54e25aa
Found initrd image:/boot/initramfs-0-rescue-f0f31005fb5a436d88e3c6cbf54e25aa.img
done
reboot
ELRepo has two types of Linux kernel packages, kernel-lt and kernel-ml. What is the difference between them?
The kernel-ml package is built based on the sources provided by the mainline stable branch of Linux Kernel Archives. The kernel configuration is based on the default RHEL-7 configuration, with added features enabled as needed. These packages are deliberately named kernel-ml to avoid conflicts with the RHEL-7 kernel, so they can be installed and updated together with the regular kernel.
The kernel-lt package is built from the source code provided by Linux Kernel Archives, just like the kernel-ml package. The difference is that kernel-lt is based on long-term support branches, while kernel-ml is based on mainline stable branches.
You can refer to https://dwz.cn/vZotLbZD if you encounter problems during the installation process
http://elrepo.org
https://rorschachchan.github.io/2018/08/25/centos6-5 Upgrade the latest kernel 4-18 pit/
https://rorschachchan.github.io/2018/06/11/Alibaba Cloud centos7 upgrade kernel process/
https://www.admon.org/faqs/kernel-lt-and-kernel-ml/
Recommended Posts