To Improve RHEL 8.5

Posted on Nov 17, 2021

After installing RHEL, there is something that must be done. Actually, I have tested the latest RHEL 9, but as a comsumer, I think it is to hard to use, because EPEL packages are not as much as that in RHEL 8.5. So I switch my OS to RHEL 8.5.

Enable EPEL

dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
dnf clean all
dnf update
subscription-manager repos --enable "codeready-builder-for-rhel-8-$(arch)-rpms"

Install NVIDIA driver

lspci -vnn | grep VGA
# Download NVIDIA driver for Linux x86_64 from [official website](https://www.nvidia.com/Download/index.aspx?lang=en-us).
cd Download
dnf group install "Development Tools"
# Disable nouveau
nano /etc/modprobe.d/blacklist.conf 
blacklist nouveau
mv  /boot/initramfs-$(uname -r).img   /boot/initramfs-$(uname -r).img.bak
dracut --force /boot/initramfs-$(uname -r).img
reboot
lsmod | grep nouveau # Check if you have disabled nouveau correctly. No responce is right.
init 3 #to go to no-graphic mode
# alt + F2 to enter tty2 and then login
su
./(nvidia_driver).run
# do not install 32-bit and press "yes" to restart x.
reboot
# Check if NVIDIA driver is installed.
nvidia-smi
nvidia-settings

Install Google-Chrome

Download google-chrome installation package from google.

dnf install liberation-fonts
dnf install libvulkan.so.1
rpm -ivh ./(google-chrome).rpm

Mount NTFS disk

To mount NTFS disk, I need a package called NTFS-3G. When I search for solution, it is amazing that almost everyone says that “yum install ntfs-3g” after adding EPEL to yum can work, but actually it do works!
hhh.

yum install ntfs-3g
# then double-click the disk in file manager, and you can access to it.
# you can still mount the disk manually
mkdir /mnt/win/temp
mkdir /mnt/win/doc
mount -t ntfs-3g /dev/nvme0n1p4 /mnt/win/temp
mount -t ntfs-3g /dev/sda1 /mnt/win/doc

OneDriver

I use OneDrive to sync my files so I struggled to find an easy use tool to access to onedrive, until I find OneDriver.

sudo dnf copr enable jstaf/onedriver
sudo dnf install onedriver

Gridea

Gridea is what I use to build my blog, however, no rpm version is provided. I need to convert deb or dmg to rpm, or I will need to use the “junk” AppImage. Jesus! I finally take .snap.

sudo yum install snapd
sudo systemctl enable --now snapd.socket
sudo ln -s /var/lib/snapd/snap /snap
wget https://github.com/getgridea/gridea/releases/download/v0.9.2/gridea_0.9.2_amd64.snap
sudo snap install (gricea).snap --dangerous
snap run gridea

V2rayA

There is no version for RHEL8 actually, so you cannot add copr by dnf copr enable zhullyb/v2rayA. Follow these:

dnf copr enable zhullyb/v2rayA centos-steam-8-x86_64
dnf install v2ray-core v2rayA

Convert deb to rpm

yum install alien
alien --to-rpm --scripts xxx.deb
rpm -Uvh xxx.rpm
# if some errors occur
yum install https://rpmfind.net/linux/fedora/linux/releases/35/Everything/x86_64/os/Packages/r/rpmrebuild-2.16-1.fc35.noarch.rpm
rpmrebuild -pe xxx.rpm
# remove the error path
rpm -e --nodeps xxx

RAR

yum install unar
unar xxx.rar