Rocky linux upgrade kernel

How to upgrade Linux Kernel on Rocky Linux/AlmaLinux/CentOS 8

In this guide I will show you how to upgrade our Linux Kernel to the latest version on our Rocky Linux/ AlmaLinux and CentOS.

Linux Kernel is a free and open source, monolithic, modular, multitasking unix-like operating system. It is the main component of a Linux operating system and is the core interface between the computer’s hardware and its processes. It makes communication possible between computer hardware and processes running on it and it manages resources effectively.

Prerequisites

  1. Rocky Linux server/AlmaLinux
  2. User with sudo privileges
  3. Strong internet connection

Table of Contents

  1. Update the operating system repositories
  2. Check current installed Linux Kernel
  3. Import ElRepo GPG key
  4. Install ElRepo repository for Rocky Linux
  5. Install latest Linux Kernel

1. Pass Updates on Rocky Linux/AlmaLinux

To begin our installation process, we need to update our repositories to reflect the new state of our operating system. We can do the update by issuing the following command on our terminal.

When the update is complete, we can then check our current Linux Kernel to know where we are starting from.

2. Check current installed Linux Kernel

To check the current running Linux Kernel in our system we can pass the following command in our terminal. It will show us the current installed Linux Kernel.

You out should look like this

# uname -r 4.18.0-305.3.1.el8_4.x86_64

Now that we have seen the current installed Linux Kernel, let’s now begin the installation process but first we need to add the GPG key to our repository.

3. Import ELRepo GPG Key

The ELRepo project uses a GPG key to sign all RPM packages that is released. Each ELRepo project is sign with a GPG signature. To ensure autenticity of the signature you must verify it before installation. It must match with the following fingerprint.

# Fingerprint: 96C0 104F 6315 4731 1E0B B1AE 309B C305 BAAD AE52

To verify your fingerprint you can use the following command on our terminal.

$ gpg --quiet --with-fingerprint RPM-GPG-KEY-elrepo.org

If you have a matching key with the fingerprint then you can now import it. Use the below command to do the import.

$ sudo rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org

Next we can install ELRepo in our repository.

Читайте также:  Rhel linux yum install

4. Install ELRepo repository on Rocky Linux

If your import was successful, you can now move ahead and install it in your system with the following command.

$ sudo dnf install https://www.elrepo.org/elrepo-release-8.el8.elrepo.noarch.rpm

Press Y to allow installation to continue. The output you will get will be as follows

# sudo dnf install https://www.elrepo.org/elrepo-release-8.el8.elrepo.noarch.rpm DigitalOcean Droplet Agent 43 kB/s | 3.3 kB 00:00 elrepo-release-8.el8.elrepo.noarch.rpm 52 kB/s | 13 kB 00:00 Dependencies resolved. ================================================================================================================= Package Architecture Version Repository Size ================================================================================================================= Installing: elrepo-release noarch 8.2-1.el8.elrepo @commandline 13 k Transaction Summary ================================================================================================================= Install 1 Package Total size: 13 k Installed size: 5.0 k Is this ok [y/N]: y Downloading Packages: Running transaction check Transaction check succeeded. Running transaction test Transaction test succeeded. Running transaction Preparing : 1/1 Installing : elrepo-release-8.2-1.el8.elrepo.noarch 1/1 Verifying : elrepo-release-8.2-1.el8.elrepo.noarch 1/1 Installed: elrepo-release-8.2-1.el8.elrepo.noarch Complete!

When all the prerequisites had been meet we can now install the latest kernel which is Linux Kernel 5.15 as of this writing.

5. Install latest Linux Kernel

We are going to install the mainline version because that is always the latest release by the Kernel maintainers. You can use the following command.

$ sudo dnf --enablerepo=elrepo-kernel install kernel-ml kernel-ml-devel kernel-ml-headers

After the installation is complete you must reboot the system for the new changes to take effect.

Check again to see if the changes have been effected.

You will see the following output

# uname -r 5.15.2-1.el8.elrepo.x86_64

Hurray! we have successfully upgrade to Linux Kernel 5.15.2.

Conclusion

Congratulations! You have learn how to upgrade Linux Kernel to the latest release on Rocky Linux. To learn more please consult the documentation.

Источник

How to Upgrade your Servers from Rocky Linux 8 to 9

In this tutorial, you will learn how to upgrade your servers from Rocky Linux 8 to 9.

Table of Contents:

What is Rocky Linux?:

Rocky Linux is a Linux distribution developed by Rocky Enterprise Software Foundation. It is intended to be a downstream, complete binary-compatible release using the Red Hat Enterprise Linux (RHEL) operating system source code. The project’s aim is to provide a community-supported, production-grade enterprise operating system. Rocky Linux, along with Red Hat Enterprise Linux and SUSE Linux Enterprise, has become popular for enterprise operating system use.

Rocky Linux 9.0, the latest version of the open source enterprise operating system designed to be fully bug-for-bug compatible with Red Hat Enterprise Linux (RHEL), is now generally available. The update includes new security and networking features, and a new open source build system called Peridot.

Released on 14 July 2022, Rocky Linux 9.0 has all of the build chain infrastructure tools for developers to pick up Rocky Linux or extend or reproduce the Operating system, should a developer want to do something independently of the community or any upstream supporting organization. A primary goal behind developing the new, cloud-native build system was assuring that new versions of Rocky can be released within one week of new RHEL version releases.

Читайте также:  Listing files and directories in linux

What’s New in Rocky Linux 9?:

Some of the new features of Rocky Linux 9 are:

  • Rocky Linux 9 will be supported until May 31st, 2032
  • Ships with GNOME 40 as the default desktop environment
  • XFS now supports Direct Access (DAX) operations
  • NFS introduces the “eager write” mount option to help reduce latency
  • Rocky Linux 9 has many of the latest runtimes and compilers, including GCC 11.2.1, LLVM (13.0.1), Rust (1.58.1), and Go (1.17.1)
  • Python 3.9 will be supported for the entire lifecycle of Rocky Linux 9 and comes with many new features
  • Node.js 16 include an upgrade to the V8 engine to version 9.2
  • Ruby 3.0.3 provides several performance improvements, along with bug and security fixes
  • Perl 5.32 provides bug fixes and enhancements, including Unicode version 13
  • PHP 8.0 provides bug fixes and enhancements, including the use of structured metadata syntax
  • Root user authentication with a password over SSH has been disabled by default
  • OpenSSL 3.0 adds a provider concept, a new versioning scheme, and improved HTTPS
  • The Cockpit web console has an improved performance metrics page that helps identify causes of high CPU, memory, disk, and network resource usage spikes.

System Requirements:

With Rocky Linux 9.0, some older CPUs will not work well, or perhaps at all. The following architectures are considered minimum requirements for a successful install:

  • AMD and Intel 64-bit architectures (x86-64-v2)
  • The 64-bit ARM architecture (ARMv8.0-A)
  • IBM Power Systems, Little Endian (POWER9)
  • 64-bit IBM Z (z14)

Environment Specification:

We are using a minimal Rocky Linux 8 virtual machine with following specifications.

  • CPU — 3.4 Ghz (2 cores)
  • Memory — 2 GB
  • Storage — 20 GB
  • Operating System — Rocky Linux 8.6 (Green Obsidian)
  • Hostname – rockylinux-01.centlinux.com
  • IP Address — 192.168.116.128 /24

Updating Software Packages:

By using a ssh client, connect with rockylinux-01.centlinux.com as root user.

Rebuild cache of enabled yum repositories.

Execute following dnf command to update software packages in your Rocky Linux server.

Gathering System Information:

Here, you are going to upgrade your server operating system from Rocky Linux 8 to 9.

Therefore, it is good to note down the information about your existing system components before starting upgrade process.

Check versions of Linux operating system, Linux Kernel and other installed applications as follows.

# cat /etc/rocky-release Rocky Linux release 8.6 (Green Obsidian) # uname -r 4.18.0-372.16.1.el8_6.0.1.x86_64 # mysql -V mysql Ver 15.1 Distrib 10.3.32-MariaDB, for Linux (x86_64) using readline 5.1 # httpd -v Server version: Apache/2.4.37 (rocky) Server built: Jun 22 2022 14:17:54 # php -v PHP 7.2.24 (cli) (built: Oct 22 2019 08:28:36) ( NTS ) Copyright (c) 1997-2018 The PHP Group Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies

Upgrading Yum Repositories from Rocky Linux 8 to 9:

For upgrading your yum repositories from Rocky Linux 8 to 9, you have to upgrade following three software packages.

Читайте также:  Установка skype linux mint

You can either download above software packages from Rocky Linux website.

Or you can execute following dnf command to install all three of them on your Linux operating system.

# dnf install -y https://download.rockylinux.org/pub/rocky/9/BaseOS/x86_64/os/Packages/r/

You can safely ignore the warning during the execution of above command.

Upgrading Rocky Linux 8 to 9:

Now you can easily upgrade your Linux operating system by executing following command at Linux Bash prompt.

# dnf -y --releasever=9 --allowerasing --setopt=deltarpm=false distro-sync

Above command takes a couple of minutes to complete and successfully upgrades your server operating system from Rocky Linux 8 to 9. It also upgrade software applications and Linux Kernel as well.

In Rocky Linux 9, the RPM backend database format has been changed from Berkley Database Backend to SQLite.

Therefore, you need to rebuild your RPM database once to upgrade it to SQLite backend.

# rpm --rebuilddb warning: Converting database from bdb_ro to sqlite backend

Reboot your Linux operating system with the new Linux kernel.

Verify Software Versions after Upgrade:

During system boot, you may observe the Old Linux Kernel 4.18 is still listed in the GRUB boot menu.

It is the default behavior of Linux operating system to keep two previous Kernels for fallback support.

Although if you don’t like it there, you can remove it by following our guide on how to remove old Linux kernels.

Check versions of Linux operating system, Linux Kernel and installed applications as follows.

# cat /etc/rocky-release Rocky Linux release 9.0 (Blue Onyx) # uname -r 5.14.0-70.17.1.el9_0.x86_64 # mysql -V mysql Ver 15.1 Distrib 10.5.13-MariaDB, for Linux (x86_64) using EditLine wrapper # httpd -v Server version: Apache/2.4.51 (Rocky Linux) Server built: Mar 21 2022 00:00:00 # php -v PHP 8.0.13 (cli) (built: Nov 16 2021 18:07:21) ( NTS gcc x86_64 ) Copyright (c) The PHP Group Zend Engine v4.0.13, Copyright (c) Zend Technologies with Zend OPcache v8.0.13, Copyright (c), by Zend Technologies

You can see that your Linux operating system alongwith Linux Kernel and installed applications has been upgraded from Rocky Linux 8 to 9.

Conclusion:

In this tutorial, you have learned how to upgrade your servers from Rocky Linux 8 to 9.

Buy Me A Coffee

If you find this article useful? Consider supporting us by

Источник

Оцените статью
Adblock
detector