Upgrading to the next level of Linux experience
Published:
My quest to find the best Linux distro for the new PC.
Update (Aug 30, 2023): I have moved to Windows 11 with WSL. We have Microsoft Windows supporters like SUSE (openSUSE), Ubuntu (Debian Sid), and RedHat/Oracle Linux (Fedora) for WSL, Azure,… and competitors like Apple macOS (UNIX) and Google chromeOS (ChromiumOS).
Open-source software is better
Open-source softwares are great because they have scope for technical superiority by allowing transparency. In fact, this is good enough incentive for many big corporations like Intel (server processors), IBM (Red Hat Enterprise Linux), Microsoft (Azure), Google (Chrome), Novell (SUSE Linux), etc. and smaller companies like Canonical (Ubuntu), etc. to sponsor Linux Foundation and other commmunity-driven Linux projects like GNOME (with major contributions coming from Red Hat), KDE (with major contributions coming from SUSE), and Debian (with major contributions coming from Canonical). However, there are still some popular Linux related projects like Arch Linux, Gentoo, Cinnamon DE and Xfce that are being developed by the community at a steady pace without any corporate funding. Though these community-only projects are really powerful and allow the user to create a custom workflow, they tend to attract only the ones with considerable knowledge of Linux and a desire to contribute.
For normal consumer products like desktops and laptops, Microsoft Windows has the monopoly because it comes pre-installed for free and is supported by all softwares (games) and the latest hardware. However, in the enterprise world where mainframe computers and servers need to be really secure, Linux distributions like Ubuntu, RHEL, CentOS, SUSE, and Debian tend to be more popular. Among these, Debian is the only one which is not owned by any specific company, but companies can directly fund the long-term-support. Ubuntu, which derives its source from Debian Sid, is quite popular among tech start-ups because of its freemium kind of business model where anyone can download it for free and one only needs to pay for extended service (similar to the extreme popularity of the free-to-play games like Fortnite and PUBG). In fact, it was marketed so well that it is the most popular Linux distribution among people who just wants a better OS than Windows but can’t afford to be a part of the Mac ecosystem.
Ubuntu’s major contribution has been the LightDM display manager. However, neither Ubuntu nor Debian is the market leader because they lack fast-paced innovation. RHEL has been the market leader for enterprise linux for a long time, mainly because it has invested a lot in innovation. Following is a rough representation of how it works in present:
Update: CentOS development was stopped on Dec 08, 2020 after being bought by IBM. However, the development of Rocky Linux has started.
The second most popular enterprise Linux distro is SUSE, it is the oldest commercial Linux distro. In recent years, it has also reorganized itself by starting community driven openSUSE project similar to the successful Fedora project to speed up innovation:
This new Tumbleweed was a result of the ‘merger’ of Old Tumbleweed and Factory in November 2014. Recently, AMD to complement its great technological advancements have started making significant contributions to the Linux kernel. In fact, it is also one of the primary sponsors of openSUSE project. In my opinion, openSUSE Tumbleweed is a good comeptitor for Fedora since it strives to provide access to latest packages using rolling release instead of short lived point release. On the other hand, openSUSE Leap is a good competitor for Ubuntu LTS since it gives an option for upgrading to much superior SUSE enterprise.
I especially like the open-source softwares like these, which let individual users access them for free while charging big corporations for techincal support. Some other examples are, Anaconda by Travis Oliphant (it also helps fund development of NumPy etc. via NumFOCUS) and MySQL by Oracle Corp.
Mix and Match
Now a days there are many emerging comeptitors like Manjaro and Solus competing with Ubuntu and its forks for the non-technical users. I was introduced to linux as a non-techincal user in 2006 when I ran Ubuntu in a virtual box on my Windows XP desktop PC, thanks to the free CD I got with the PC World magazine I had bought during summer vacations. I have been using Ubuntu-based distros (I replaced Windows 7 with Lubuntu on my Netbook) since Windows XP died in 2014, and it has been a nice journey. Whenever I ran into some trouble, I just copy-pasted codes from some blog/forum and ignored issues as long as work got done. For example, I chose not to use WiFi over using Windows 8 when Realtek drivers were breaking on Ubuntu (had no idea it has to do something with Linux Kernel). But now since I have built my own PC for the first time, I have a much better knowledge of the hardware and find it difficult to just shrug shoulders as long as system boots. Theorefore, Ubuntu can no more fulfill my needs and I will have to move to a little less stable distro.
The main use of my new PC is to write documents in LaTeX, hence I would really like to have easy access to the latest version of texlive and text-editor (like Vim, though you will always get some version of vim-minimal pre-installed). However, stable distros like Ubuntu LTS and openSUSE Leap tend to have outdated repositories of both of these and Ubuntu tries to mitigate this with untrusted PPAs, unstable Snaps and useless Flatpaks. Moreover, compiling them from sources can be a bit tricky (eg: installing TexLive and Vim). Hence I felt the need to migrate to a distro which can give easy access to latest version of these programs. But I don’t have enough time and knowledge to be able to maintain the stability and security of rolling-release distros like Arch, openSUSE TW and Gentoo. Therefore, since I don’t need any proprietary drivers for my PC, I decided to take a middle ground and move to the pseudo-rolling/stable-release distro Fedora (13 month life cycle, new release every 6 months) which is the upstream source of the commercial Red Hat Enterprise Linux distribution. Another reason for choosing Fedora was that its community is more knowledgebable (RedHat is one of the biggest contributer to Linux kernel) and the bugs acutally get resolved (for Ubuntu there can exist an year old bugs like the initramfs bug with temporary solution in forums). One bug that has followed me in Ubuntu and Linux Mint is the momentary blackout of screen when some pop-up menu opens in applications like Google Chrome and TexMaker Settings, however I have no hope of it getting solved since there is this similar three years old bug report in the forums.
For the desktop environment I decided to go with Xfce because most of my applications use GTK (hence not KDE or LXQt), didn’t want to waste RAM for customizability (hence not GNOME 3 or MATE which are resource heavy but still lack simple in-built customization options like desktop wallpaper slideshow, requires separate pacakges like GNOME Tweaks and GNOME Extensions) and needed stability (hence not Cinnamon which lacks proper documentation and bug resolving mechanism, eg: this an year old zombie-windows bug which requires restarting cinnamon to troubleshoot, moreover most appearance tweaks depend on themes and applets created by volunteers which are not guaranteed to be actively maintained). Cinnamon is an attempt to mimic Xfce while staying close to GNOME, however its lack of documentation ability to tweak easily is a big negative. One thing I miss in Xfce is the absence of dock (using Plank is fissible but not ideal). However, it can easily be mitigated by setting up keyboard shortcuts for the frequently used applications.
I installed Fedora Xfce using Server Netinstall instead of the official Spins since they tend to be bloated and will have to install lots of updates afterwards. Fedora comes with Ubuntu’s LightDM display manager which manages the login screen, in the case of Xfce Fedora uses the Xubuntu’s LightDM GTK+ Greeter.
Update (June 22, 2021): My university changed their wired internet connection protocol and now it requires unsername and password. Hence can’t use this Netinstall method anymore. Back to using the livecd image.
Differences between Ubuntu and Fedora
Most of my Linux experience is based on Ubuntu. Following are some differences that I experienced:
Administrator vs. User
Users have the option of setting a root password in when installing a non-GNOME Fedora, but it is not required if the user creates an initial user account and selects the option to add it to the wheel group. If root password is set, then the root
account is the account for the system admin. This account is disabled in Ubuntu. In Ubuntu, one performs actions that require root
privileges using sudo, while in a Fedora spin, sudo is not the default method of gaining administrative permissions. Therefore, in Fedora Xfce spin with root password, root
access can only be gained with su
. su will ask for the root
password, not the regular user password. After logging in successfully as root
, one has administrative rights until terminal is closed or logged out with exit
. However, for GNOME Fedora, it’s just like Ubuntu i,e. no root password set by default and user account is handled by gnome-initial-setup. Having a root password is not useful for nontechnical users.
Package management
Fedora uses different tools for package management to Debian. Here is a quick overview of how to accomplish common tasks in Fedora: (source)
Debian command | Fedora command |
---|---|
apt update | dnf check-update |
apt upgrade | dnf upgrade |
apt dist-upgrade | dnf system-upgrade |
apt install | dnf install |
apt remove | dnf remove |
apt purge | N/A |
apt-cache search | dnf search |
In older versions, apt-get
in Ubuntu corresponded to yum
in Fedora. To know if a reboot is needed after doing a dnf update
use either tracer or needs-restarting plugin. Unlike Debian/ubuntu, I don’t need to remeber to use autoremove
after removing some package.
Moreover, like in Ubuntu we use dpkg
for installing .deb files, we can use rpm
in Fedora for installing .rpm files. Following is a comparison of commands:
Command Details | Fedora Command | Ubuntu Command |
---|---|---|
Install a package | rpm -i package.rpm | dpkg -i package.deb |
Update package | rpm -U package_name | dpkg -i {file.deb} |
Remove an installed package | rpm -e package_name | dpkg -r package_name |
List all installed packages | rpm -qa | dpkg -l |
List files in an installed package | rpm -ql package_name | dpkg –listfiles package_name |
Show information about installed package | rpm -qi package_name | dpkg –status package_name |
Show information about package file | rpm -qpi package.rpm | dpkg –info package.deb |
List files in a package file | rpm -qpl package.rpm | dpkg –contents package.deb |
Verify all installed packages | rpm -Va | N/A |
Verify installed package | rpm -V package_name | N/A |
You can also use dnf
instead of rpm
, just like we can use apt
instead of dpkg
. You can find an outdate but more extensive list in Ubuntu Wiki.
Finding packages using GUI
Fedora’s equivalent to Debian’s Synaptic package manager is dnfdragora which uses the widget abstraction library written by SUSE. Unfortuately it’s nowhere as good as Synaptic. Moreover it is extremely RAM hungry. However, in GNOME edition of Fedora there is GNOME Software Centre which makes things smoother, but requires PC reboot for installing updates. In the RPM world opeSUSE has YaST as a worthy competitor of Synaptic (but that feels too nosey, it is much more than just a package manager).
Installing packages not in repository
The equivalent of the Ubuntu restricted
and multiverse
repositories, that include patented and closed-source technologies and programs, is the RPMFusion repository. free is the equivalent of universe
and contains potentially patent-encumbered software like gstreamer-plugins-bad
or the VLC media player
, while nonfree includes non-free software like proprietary 3D graphics drivers.
These repositories can easily be enabled by typing (as root
):
dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm dnf install https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
Moreover, the equivalent of the PPAs in Ubuntu is Copr. This repository can be added with
dnf copr enable user/project.
Note that just like Ubuntu PPA and Arch AUR, there is no way to verify that a package in Copr does not contain anything malicious unless you review the source code.
Linux Security Modules
Ubuntu uses AppArmor (which was earlier developed by SUSE), whereas Fedora uses SELinux. AppAromor is said to be easier to maintain than SELinux.
Installing Fedora
Firstly download and verify the iso file. Then make a bootable pendrive using the Qt app Fedora Media Writer, unfortunately it requires KDE so will install that also. I decided to use ext4 file system, which is the current default file system for Workstation and Spins, instead of the dfault file system xfs for Server/Netinstall (there are benchmarks claiming either xfs is better or ext4 is better). I followed Fedora’s recommended partitioning scheme and created the following GUID partition table:
Mount Point | Parition Type | File System | Size | % of total space (500 GB) |
---|---|---|---|---|
/boot | Standard | ext4 | 500 MB | 0.1% |
/boot/efi | Standard | EFI System Partition | 200 MB | 0.04 % |
swap | Standard | swap | 4 GB | 0.8 % |
/ | Standard | ext4 | 60 GB | 12 % |
/home | Standard | ext4 | 435.4 GB | 87 % |
Note that modern Linux OS don’t require separate partitions for both /boot
and /boot/efi
(EFI System Partition) directories. The only requirement for suing GRUB2 boot loader is that /boot
directory must be on a plain ext4 or xfs partition and /boot/efi
directory must be on a plain vfat partition. If one wants to install Fedora with only two paritions /
and /boot
then it is recommended to use systemd-boot boot loader instead. However, since we were following Fedora’s recommended partitoning scheme we created separate /boot
and /home
paritions with standard ext4 format instead of leaving them with /
. Also, I alloted thrice the recommended size for 20 GB for /
because I plan to use Timeshift which saves snapshots in root directory itself and works only with GRUB2 (very important tool, was fixed later).
Select Xfce Fedora without any extra software programs, we will manually install the ones we want. To bypass creating root password in netinstall mode, just create a user account and mark it as administrator. After installing, the first think we will do is set-up drop-down terminal following this guide. Also consider changing first day of week to Monday by following this guide.
Free and open source softwares
Vim, PulseAudio Volume Control and dnfdragora are already installed.
Purpose | Software | dnf Package |
---|---|---|
Web browser | Firefox | firefox |
Privacy Web browser | Tor browser | torbrowser-launcher |
Login screen modification tool | LightDM GTK+ Greeter settings | lightdm-gtk-greeter-settings |
System Restore | Timeshift | timeshift |
Calculator | Galculator | galculator |
File searching tool | Catfish | catfish |
Basic GUI Text Editor | Mousepad | mousepad |
Archiving tool | Xarchiver | xarxhiver |
PDF editor with tablet support | Xournal++ | xournalpp |
PDF and DjVu viewer with poppler backend | Evince | evince |
eBook reader | Foliate | foliate |
Spreadsheet viewer and editor | Gnumeric | gnumeric |
Word processor | AbiWord | abiword |
PDF split/merge | PDF-Arranger | pdfarranger |
Image viewer and editor | gThumb | gthumb |
Webcam | Cheese | cheese |
Car racing game | SuperTuxKart | supertuxkart |
First-person shooter game | Xonotic | xonotic |
LaTeX | TeX Live | texlive-scheme-full |
Tool for drawing figures for LaTeX | Inkscape | inkscape |
Non-poppler pdf viewer with Vim keybinding option | MuPDF | mupdf |
Computer Algebra System | SageMath | sagemath |
Disk space cleaner | Bleachbit | bleachbit |
Note that Firefox also lets you use streaming services like Netflix which require h264/mp3/aac and widevine. Also, you can remove “Pocket” from Firefox following these steps.
Unfortunately, Signal doesn’t have an official Fedora repo, however it can be installed using Copr.
To find more softwares, use: dnfdragora > Groups > Xfce desktop option.
Finally, if you need Windows to access applications like OneNote instead of Xournal++ then you can install it by running Win 10 virtual machine, by using virtIO drivers along with virtualization, that is choose i440FX chipset, UEFI without secure boot, QXL video and virtio for Virtual Disk and Virtual Network Interface (make sure to update all the missing Windows drivers using the virtIO iso file). Alternatively, dual-boot Fedora with Windows following this guide and remember to disable HDCP support overrride in Display settings of AMD Radeon driver if not using HDMI port.
Restricted softwares
Purpose | Software | Installation guide |
---|---|---|
Playing videos with patented multimedia codecs | Celluloid | RPM Fusion Free Repository |
Access Chromebook and Android bookmarks | Google Chrome | fedora-workstation-repositories |
Note that Google Chrome poorly integrates with the Linux. For example, if you change the default DPI of 96 or font scaling for the display then Google Chrome text and images get blurred and you have to fix it yourself (possible solution 1 and solution 2).
/usr/bin/google-chrome-stable --force-device-scale-factor=1 %U
It also poorly integrates with Xfce since it attempts to creat its own default keyring for password encryption, so either you will have to create another password or disable it.
DNF plugins
We will install the following two plugins:
Purpose | Plugin | dnf package |
---|---|---|
To check which services need to be restarted after update | tracer | dnf-plugins-extras-tracer |
To upgrade Fedora to the latest version | system-upgrade | dnf-plugin-system-upgrade |
Xfce panel plugins appearance
Few panel plugins like Datetime, Places, PulseAudio and ScreenShooter are already installed.
Purpose | Plugin | dnf Package |
---|---|---|
Clipboard manager | Clipman | xfce4-clipman-plugin |
Weather indicator on taskbar | Weather | xfce4-weather-plugin |
Note that the weather plugin has known bugs, like using inaccurate data from Meteorologisk institutt instead of actual data from OpenWeatherMap and co-ordinating day/night icon with UTC instead of local time. None of these bugs are there in Cinnamon’s weather plugin.
Appearance: Themes and Wallpapers
We will install the following themes and wallpapers:
Purpose | Name | dnf Package |
---|---|---|
GTK+ Theme | Numix | numix-gtk-theme and numix-icon-theme |
Wallpapers | Fedora 32 Supplemental Wallpapers | f32-backgrounds-extras-xfce |
To apply this theme select “Numix” in
- Settings Manager > Window Manager > Style
- Settings Manager > Appearance > Style
- Settings Manager > Appearance > Icons
- Settings Manager > LightDM GTK+ Greeter settings > Appearance
Note that the default appearance editor can only edit GTK2 themes/icons. Therefore, to edit GTK3 themes/icons either edit the ~/.config/gtk-3.0/settings.ini
or use the LXDE appearance editor lxappearance
. You might also have to make changes in Settings Manager > Windows Manager Tweaks > Accessibility
.
Finally, to change background use “Settings Manager > Desktop > Background” and select the folder /usr/share/backgrounds/f32/extras/
.
Introspection
The plan is to upgrade to next version of Fedora three months after its release so that maximum bugs can be avoided (eg: initial release of Fedora 32 had a bug which has been corrected later using system updates). Hence I will get a system wide update twice a year. Fedora is going to change to btrfs as default filesystem in the next release of Fedora 33 (something default in SUSE but abandoned by Red Hat). One annoying thing is that I have to install lots of updates everyday since Fedora pushes bug fixes as soon as they are found, irrespective of how important they are. Moreover, the supported releases are updated to the latest stable version of the Linux kernel, increasing the chances of unstability.
Though Xfce is highly customizable and has a great documentation, it lacks GUI for basic things like system info viewer, individual CPU core usage, user login picture manager (though Fedora has Whisker menu plugin, it lacks the required Mugshot package) and tablet pen-pressure settings (which can also be done in GNOME 3, Cinnamon and KDE). However, these can easily be done using manually via Terminal:
For system info we have CLI tools like
inxi
(doc),neofetch
andlshw
.To view system usage information we can use tool like
top
in terminal, and get individual core usage bytop 1
(doc).We can manually edit the profile picture configuration
$ sudo mkdir /var/lib/AccountsService/icons/<your_user_name>
$ sudo cp ~/home/<my_picture_of_size_96x96>.png /var/lib/AccountsService/icons/<your_user_name>
$ sudo mousepad /var/lib/AccountsService/users/<your_user_name>
Add the line: Icon=/var/lib/AccountsService/icons/<your_user_name>/<my_picture_of_size_96x96>.png
.
- For Wacom tablet pen-pressure on X Window System we can use
xsetwacom
(doc)
xsetwacom set "Wacom One by Wacom S Pen stylus" PressureCurve 0 50 50 100
However, any setting changed by xsetwacom
will be reset to default (or a statically configured setting) whenever the device is unplugged, disabled or the X Server is restarted. One can make Linux run the command automatically when hot-plugging the device by entering the above command to Settings Manager > Removable Drives and Media > Input Devices > Automatically run this command when a tablet is connected
. Note that, these CLI methods won’t work when using Wayland instead of Xorg. I could’t make CLI work in Cinnamon, only GUI settings worked and provided the following options:
0 75 25 100 # very soft
0 50 50 100 # soft
0 25 75 100 # little soft
0 0 100 100 # default
25 0 100 75 # little firm
50 100 100 50 # firm
75 0 100 25 # very firm
Though main advantage of Fedora is that it is much more customizable. However, the following three errors were still logged:
AMD-Vi: Most likely this is a false alarm from the Linux kernel. However, turning off IOMMU in BIOS is not an option (which somehow is suggested in forums) since it is needed for HSA used by AMD for making GPU and CPU work together in its APUs. If I end up with black-screen during boot then I will consider updating AGESA drivers in the BIOS.
Watchdog: Another AMD Ryzen related bug in Linux Kernel. We can just silence it. If I end up with black-screen during boot then I will consider updating AGESA drivers in the BIOS.
GNOME key-ring: Issue originating from GNOME which have crept into LightDM.
Epilogue
After one year of using Fedora 32 and 33 with Xfce 4.14, in June 2021, I moved to OpenSUSE Leap 15.3 with KDE 5.18 instead of Fedora 34 with Xfce/GNOME. It was mainly because of the issues with Xfce 4.16 (unable to control power settings for idle time) and Linux kernel 5.12 (messing with swap partition, hanging since not freeing the RAM). I was also annoyed by the large number of updates I received everyday on Fedora (but stuck with TexLive 2017, which was always up-to-date in Fedora). However, I do miss the package information system and documentation of Fedora. Other than that, OpenSUSE and KDE have worked great out of the box (DON’T ENCRYPT THE HARD DRIVE, disable secureboot and disable NVRAM). I had to install OpenSUSE in virtual machine first, in order to make the installation USB using SUSE Studio Image Writer (moreover, change in college internet connection policy made it impossible to use netinstall). Another option would be to use Ventoy.
After installing, I used windows to reformat the USB stick to exFAT format. Then to access USB stick in openSUSE, install fuse-exfat
package.
If Konsole starts in super user mode, then go to Settings > Manage Profiles > Edit profile > General it is important that in ‘Command’ it does not say su- but /bin/bash.
Disable automatic screen locking: System Settings > Workspace behavior > screen locking
Adjust screen off time: System Settings > Power management > energy saving
Disable the auto-updater PackageKit
since it can interfere with the manual software installation: Configure System Tray > Software Updates > Disabled.
Replace Firefox’s Extended Support Release (ESR) with the latest version from the Mozilla repository using YaST or terminal:
> sudo zypper ar -f http://download.opensuse.org/repositories/mozilla/openSUSE_Leap_15.3/ mozilla
> sudo zypper ref
> zypper up --from mozilla
Unfortunately, the fonts don’t render properly sometimes due to KDE integration limitations. Also install Plasma integration add-on. Then, to watch Netflix, also install the KDE multimedia codecs from Packman using 1-click. Somehow, vlc-lang
package didn’t swtich the repository so had to do it manually.
> sudo zypper up --allow-vendor-change
Loading repository data...
Reading installed packages...
The following package is going to be upgraded:
vlc-lang
The following package is going to change vendor:
vlc-lang openSUSE -> http://packman.links2linux.de
Also, had to build SageMath from the source, took 4 hours (for reference: 6000+ packages of texlive-scheme-full
take 1 hour to download and install)
> sudo zypper install gcc gcc-c++ make m4 binutils perl tar python3 dvipng ffmpeg texlive-scheme-full
> ./configure
# we will skip installing the suggested packages, openSUSE Leap has a limted collection of packages.
# will rather build everything from source, hence the long build time.
> make
-----
[2021-07-14 22:12:09] SageMath version 9.3, Release Date: 2021-05-09
Yes, Sage starts.
real 225m36.799s
user 229m31.133s
sys 13m38.360s
Sage build/upgrade complete!
-----
> ./sage --testall
> sudo ln -s /path/to/sage-x.y/sage /usr/local/bin/sage
There is color-scheme bug. Ceate a file called 50-color.ipy
in .sage/ipython-X.Y.Z/profile_default/startup
with the following content:
%colors Linux
Also, KDE icon can be created using the folliwing command for launching in Applications tab:
konsole -T "sage" -e /path/to/sage-x.y/sage