How to update your centos7 to the latest kernel

Windows Articles

How to install Vanilla Forum on Ubuntu 20.04?

Hello, folks. This post is about how to install Vanilla Forum on Ubuntu 20.04. Vanilla is an opensource discussion...

How to backup and restore Group Policy Objects in Windows Server 2016/2019.

Hi! Previously we have mentioned that Windows Server pursues a centralized administration of each role and service. In this way, a fluid...

How to use the ls command?

The ls commands list the content and optional information of the directories and files. When you execute the Ls command without options,...

How to Install APK file on Android

Hello Friends! Today we bring you a simple guide on how to install an APK file in Android. What...

How to Install the Latest version of FFmpeg on Ubuntu 20.04 / Debian 10?

Knowing how to install the latest version of FFmpeg is important if you know how to work with multimedia files. So in...
Mel Khamlichi
Mel Khamlichihttp://www.osradar.com
Founder of Osradar, from Amsterdam Netherlands

This  Tutorial is  about how to update your centos7  to  the latest kernel release. any  new kernels is coming wit bug fixes , security fixes and  new hardware drivers support.

To update your centos  Server u need SSH access /Root / and  Internet  to add the needed repos.

This is my actual system :

to Update kernel to last release you have to add news Centos Repo

Now We’ll Start the procedure of Kernel upgrade on CentOS 7 :

We need to enable the ELRepo repository on CentOS 7, run the below commands :

[root@osradar ~]# rpm --import http://www.elrepo.org/RPM-GPG-KEY-elrepo.org
[root@osradar ~]# rpm -Uvh http://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
Retrieving http://www.elrepo.org/elrepo-release-7.0-3.el7.elrepo.noarch.rpm
Preparing... ################################# [100%]
Updating / installing...
1:elrepo-release-7.0-3.el7.elrepo ################################# [100%]
[root@osradar ~]#

and checkl  if repo had  beed  added with command  yum repolist

 

You can retrieve latest download links on official page here

Now we’ll install Kernel 4.17 with the below command :

** at the time kernel 4.17 was available as latest version, for latest versions the procedure will be the same.

[root@osradar ~]# yum --enablerepo=elrepo-kernel install kernel-ml -y
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.yourwebhoster.eu
* elrepo: mirrors.ircam.fr
* elrepo-kernel: mirrors.ircam.fr
* extras: mirror.yourwebhoster.eu
* updates: mirror.yourwebhoster.eu
elrepo-kernel | 2.9 kB 00:00:00 
elrepo-kernel/primary_db | 1.7 MB 00:00:00 
Resolving Dependencies
--> Running transaction check
---> Package kernel-ml.x86_64 0:4.17.0-1.el7.elrepo will be installed
--> Finished Dependency Resolution

 

Now kernel 4.17 will downloaded and installed .

Now we need to add/modify config under /etc/default/grub :

vi  /etc/default/grub

And put this line or modify the line if  exists to :

GRUB_DEFAULT=0
[root@osradar ~]# cat /etc/default/grub
GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet"
GRUB_DISABLE_RECOVERY="true"
[root@osradar ~]#

 

Save   and exit  and run this command to create the kernel configs :

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

[root@osradar ~]# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-4.17.0-1.el7.elrepo.x86_64
Found initrd image: /boot/initramfs-4.17.0-1.el7.elrepo.x86_64.img
Found linux image: /boot/vmlinuz-3.10.0-862.3.2.el7.x86_64
Found initrd image: /boot/initramfs-3.10.0-862.3.2.el7.x86_64.img
Found linux image: /boot/vmlinuz-3.10.0-862.el7.x86_64
Found initrd image: /boot/initramfs-3.10.0-862.el7.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-77ba7edb9afc4a8cb0705febd9ed3064
Found initrd image: /boot/initramfs-0-rescue-77ba7edb9afc4a8cb0705febd9ed3064.img
done

 

That’s it.  now you can reboot your server and check the  new kernel  in the grub menu :

boot  , login and check if  system start   without issues

Please  Enjoy

More articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest article

How to install Vanilla Forum on Ubuntu 20.04?

Hello, folks. This post is about how to install Vanilla Forum on Ubuntu 20.04. Vanilla is an opensource discussion...

How to backup and restore Group Policy Objects in Windows Server 2016/2019.

Hi! Previously we have mentioned that Windows Server pursues a centralized administration of each role and service. In this way, a fluid...

How to use the ls command?

The ls commands list the content and optional information of the directories and files. When you execute the Ls command without options,...

How to Install APK file on Android

Hello Friends! Today we bring you a simple guide on how to install an APK file in Android. What...

How to Install the Latest version of FFmpeg on Ubuntu 20.04 / Debian 10?

Knowing how to install the latest version of FFmpeg is important if you know how to work with multimedia files. So in...
x