change default kernel version RHEL/CentOS 8
change default kernel version RHEL/CentOS 8
List installed kernel versions
[root@b1s ~]# rpm -qa | grep kernel | sort
kernel-4.18.0-193.28.1.el8_2.x86_64
kernel-4.18.0-240.10.1.el8_3.x86_64
kernel-4.18.0-240.1.1.el8_3.x86_64
kernel-core-4.18.0-193.28.1.el8_2.x86_64
kernel-core-4.18.0-240.10.1.el8_3.x86_64
kernel-core-4.18.0-240.1.1.el8_3.x86_64
kernel-devel-4.18.0-193.28.1.el8_2.x86_64
kernel-devel-4.18.0-240.10.1.el8_3.x86_64
kernel-devel-4.18.0-240.1.1.el8_3.x86_64
kernel-headers-4.18.0-240.10.1.el8_3.x86_64
kernel-modules-4.18.0-193.28.1.el8_2.x86_64
kernel-modules-4.18.0-240.10.1.el8_3.x86_64
kernel-modules-4.18.0-240.1.1.el8_3.x86_64
kernel-tools-4.18.0-240.10.1.el8_3.x86_64
kernel-tools-libs-4.18.0-240.10.1.el8_3.x86_64
[root@b1s ~]# grubby --info=ALL | grep ^kernel
kernel="/boot/vmlinuz-4.18.0-240.10.1.el8_3.x86_64"
kernel="/boot/vmlinuz-4.18.0-240.1.1.el8_3.x86_64"
kernel="/boot/vmlinuz-4.18.0-193.28.1.el8_2.x86_64"
kernel="/boot/vmlinuz-0-rescue-7919fe4e4b09483bab8b9140dcd8a82e"
To check the currently active kernel version we will useuname
with-r
which will give us kernel release information:
[root@b1s ~]# uname -r
4.18.0-193.28.1.el8_2.x86_64
[root@b1s ~]# grubby --info="/boot/vmlinuz-4.18.0-193.28.1.el8_2.x86_64"
index=2
kernel="/boot/vmlinuz-4.18.0-193.28.1.el8_2.x86_64"
args="ro crashkernel=auto resume=/dev/mapper/cl_b1s-swap rd.lvm.lv=cl_b1s/root rd.lvm.lv=cl_b1s/swap rhgb quiet amd_iommu=on $tuned_params"
root="/dev/mapper/cl_b1s-root"
initrd="/boot/initramfs-4.18.0-193.28.1.el8_2.x86_64.img $tuned_initrd"
title="CentOS Linux (4.18.0-193.28.1.el8_2.x86_64) 8 (Core)"
id="7919fe4e4b09483bab8b9140dcd8a82e-4.18.0-193.28.1.el8_2.x86_64"
Check the kernel version which is going to be activated post reboot
[root@b1s ~]# grubby --grub2 --default-title
CentOS Linux (4.18.0-193.28.1.el8_2.x86_64) 8 (Core)
[root@b1s ~]# grubby --default-kernel
/boot/vmlinuz-4.18.0-193.28.1.el8_2.x86_64
# grubby --default-index 0
Change the default kernel
[root@b1s ~]# grubby --set-default "/boot/vmlinuz-4.18.0-193.14.3.el8_2.x86_64"
Verify the new default kernel
# grubby --default-kernel
# grubby --default-index
# uname -r
10 Commands to Check Disk Partitions and Disk Space on Linux
1. fdisk
Fdisk is the most commonly used command to check the partitions on a disk. The fdisk command can display the partitions and details like file system type. However it does not report the size of each partitions.
$ sudo fdisk -l
2. sfdisk
Sfdisk is another utility with a purpose similar to fdisk, but with more features. It can display the size of each partition in MB.
$ sudo sfdisk -l -uM
3. cfdisk
Cfdisk is a linux partition editor with an interactive user interface based on ncurses. It can be used to list out the existing partitions as well as create or modify them.
Here is an example of how to use cfdisk to list the partitions.
linux cfdisk disk partitions
Cfdisk works with one partition at a time. So if you need to see the details of a particular disk, then pass the device name to cfdisk.
$ sudo cfdisk /dev/sdb
4. parted
Parted is yet another command line utility to list out partitions and modify them if needed.
Here is an example that lists out the partition details.
$ sudo parted -l
5. df
Df is not a partitioning utility, but prints out details about only mounted file systems. The list generated by df even includes file systems that are not real disk partitions.
Here is a simple example
$ df -h
$ df -h | grep ^/dev
$ df -h --output=source,fstype,size,used,avail,pcent,target -x tmpfs -x devtmpfs
6. pydf
Improved version of df, written in python. Prints out all the hard disk partitions in a easy to read manner.
$ pydf
7. lsblk
Lists out all the storage blocks, which includes disk partitions and optical drives. Details include the total size of the partition/block and the mount point if any.
Does not report the used/free disk space on the partitions.
$ lsblk
8. blkid
Prints the block device (partitions and storage media) attributes like uuid and file system type. Does not report the space on the partitions.
$ sudo blkid
9. hwinfo
The hwinfo is a general purpose hardware information tool and can be used to print out the disk and partition list.
The output however does not print details about each partition like the above commands.
$ hwinfo --block --short
10. Inxi
Inxi is a very useful command line program that can display information about various hardware components present on the system. To display information about the disk drives and storage devices use the "-D" option with inxi.
$ inxi -D -xx
Najlepsze górnicze GPU 2021
Najlepsze górnicze GPU 2021
1.MSI Gaming GeForce RTX 2070
SPECYFIKACJE
2. Nvidia GeForce RTX 2080 Ti
SPECYFIKACJE
3.MSI Gaming GeForce GTX 1080 Ti
SPECYFIKACJE
4. ASUS ROG Strix AMD Radeon RX 5700XT
SPECYFIKACJE
5. Karta graficzna FX AMD Radeon RX 580 GTS XXX Edition
Minerstat
Minerstat - aplikacja służąca do monitorowania i zarządzania oprogramowaniem do wydobywania kryptowalut. Umożliwia ustawienie zysku przełączania między NiceHash, multi-algo baseny, i inne monety. Otrzymujesz zapłatę w walucie, która jest obsługiwana przez pulę / opcję, którą wybierzesz. Minerstat koncentruje się na pełnym zdalnym monitorowaniu i zarządzaniu z pulpitu nawigacyjnego dla platform Linux i Windows.