Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Chapter 1 Nine Analysis takes you to upgrade linux kernel easily

2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

Note: linux kernel can be downloaded from the network disk. Version 4.14

Catalogue

1 Why upgrade the kernel

2 kernel version view

3 automatic upgrade

4 upgrade manually

4.1 download the installation package

4.2 extract the installation package

4.3 compilation and installation

4.4 restart

5 postscript

5.1 install the elrepo yum source

5.2 View kernel packages

5.3 upgrade the kernel

5.4 modify the kernel boot sequence

5.5 restart

1 Why upgrade the kernel

In order to meet the growing material and spiritual needs. The development of science and technology is changing with each passing day, and the technology is upgrading by leaps and bounds. New software and hardware have been developed, and the kernel is constantly developing in order to be compatible with various requirements.

First explain the difference between the kernel and the distribution. The kernel is the soul of the operating system, which is used to operate and manage the computer's hardware and software. It mainly provides network protocol stack, memory management, disk management, file system, interrupt handling, process management and other functions.

But the kernel is unfriendly to users because it is too professional. For users, what they need to enjoy is real service. For example, some men are infatuated with Japanese movies, it doesn't matter whether you have a kernel or not, he needs a player, but the player can't be stuffed into the kernel. What should I do? So there are good people to disk in, configure some software, toolkits, applications, etc., on the kernel to form a software package for human use. Because everyone's taste is different, so the choice of software is not the same, and gradually developed into a different software package, which we call the distribution of the operating system.

2 kernel version view

Uname-r

3 automatic upgrade

Yum install-y kernel

Upgrading the kernel using yum is the relatively safest way to upgrade, because it is a version verified by the distribution vendor. In general, it is not the latest, but it is the most stable.

4 upgrade manually

Manual upgrade is a more exciting thing. First of all, go to the linux kernel website to worship God. Click the URL to view:

See, how simple, absolutely will not be close to you, if you want more soil, more soil. I like this kind of dirt. That was the way it was at that time. Back in those days, in order to get on the net, I got up secretly while my parents were asleep and connected the cat to the phone line. When I heard the drip sound like Moore's code, I was excited, just like today's little slut sister saw Li Jiaqi.

4.1 download the installation package

Download website: https://mirrors.edge.kernel.org/pub/linux/kernel/v4.x/.

4.2 extract the installation package

Tar-zxvf linux-4.14.tar.gz

4.3 compilation and installation

Yum install-y gcc bc openssl-devel perl

Make mrproper # deletes compiled files, including kernel configuration files and various configuration files, and generally uses this command only before the first kernel compilation is performed

Make oldconfig # uses the original kernel configuration. You need to interact with each other during execution, and you can enter all the way.

Make # compiles the source code. The most time-consuming part of all operations. You can take a nap.

Make modules_install # copies the compiled kernel module to / lib/modules

Make install # make is compiled; make install is installed to the specified location (/ boot)

4.4 restart

Select version 4.14 in grub after reboot.

After booting successfully, check the kernel version again and find that it is easy to explode:

5 postscript

Of course, online upgrades can be used in order to be lazy. The upgrade steps are as follows:

5.1 install the elrepo yum source

Elrepo is a stable software source for CentOS, through which you can easily upgrade the kernel to a specified version. For the elrepo project website, please click:

Yum install-y https://www.elrepo.org/elrepo-release-7.0-4.el7.elrepo.noarch.rpm

5.2 View kernel packages

Yum-disablerepo= "*"-enablerepo= "elrepo-kernel" list available

5.3 upgrade the kernel

There are ml and lt kernels in the elrepo source. Ml (mainline) is the latest version of the kernel, and lt is a long-supported kernel. Choose the ml kernel here.

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

5.4 modify the kernel boot sequence

Modify the / etc/default/grub file to change GRUB_DEFAULT to 0:

After editing, execute the following command to make the configuration take effect:

Grub2-mkconfig-o / boot/grub2/grub.cfg

5.5 restart the system

Reboot

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report