top of page
Writer's pictureDarius

Linux for Chess Part 2 - Debian 11 customization

In this part of the course, we will prepare Debian 11 for comfortable install and use to work with modern chess software.


Like the first part of this series, this part is also designed more for beginners. All information will be presented in sufficient detail so that anyone who has already installed Debian 11 can successfully prepare and customize the system to suit their needs.



All operations described below - are optional. If you are interested, I suggest you read about them first, and then decide whether to use them.


1. Additional respositories.


Debian by default has access to a huge base of software of all kinds. However, sometimes it can be useful to have even better drivers e.g. directly from the video card manufacturer (proprietary drivers), codecs, fonts and much more.


Once logged in, click on the Activities button that is at the top left of the screen.

As in this case - if needed - buttons and places will be marked with a red border.


Then click on the Show Applications icon.


Select and click the middle program icon with the short name: Software & Upd...


Under the Debian Software tab we should select the two options shown in the picture below.


After selecting the first option, a window will appear asking you to authorize this change. After entering the password for your account (in my case I entered the password for my chessengeria account) and clicking the Authenticate button, the system will allow you to check the options.


After making changes, click Close.


Now click on the Reload button to have the changes made immediately using your internet connection.


Good. An information window will appear and disappear shortly (depending on the speed of your internet connection).



2. Installing proprietary drivers.


This is useful if your computer uses a graphics card from AMD or Nvidia and - besides typical chess applications - you intend to use graphics acceleration or just play games.



2.1. Installing Nvidia graphics card proprietary drivers.


Open a terminal in the same way as shown in the previous section (type terminal in the search engine).


And type the command:

sudo apt install nvidia-detect

After typing, press the Enter key to run the command.


The first time using the sudo command in the terminal, Debian shows this information:

Enter the password for your account and press Enter.


Ok, the program has been installed.


Now run it by typing:

sudo nvidia-detect

If your computer does not have an Nvidia graphics card, you will get the message I received:


If your computer has an Nvidia graphics card, you will receive the same or a similar message, depending on the model of your graphics card.


So, install the proprietary driver for your Nvidia card using the command:

sudo apt install nvidia-driver

When you press the Y key or the Enter key, the drivers will be installed.


When the driver installation is complete, reboot the system.


2.2. Installing AMD graphics card proprietary drivers.


Open Terminal and type the command:


sudo apt install firmware-linux firmware-linux-nonfree libdrm-amdgpu1 xserver-xorg-video-amdgpu


When you press the Y key or the Enter key, the drivers will be installed.


Now we will add Vulkan support for AMD graphics card. Type the command:

sudo apt install mesa-vulkan-drivers libvulkan1 vulkan-tools vulkan-validationlayers

When you press the Y key or the Enter key, the drivers will be installed.

If you intend to use OpenCL, you need to install Mesa OpenCL. Type the command:


sudo apt install mesa-opencl-icd

When you press the Y key or the Enter key, the drivers will be installed.


When the driver installation is complete, reboot the system.


Proprietary drivers should improve the performance of your graphics card.



3. Installing Microcode.


Microcode is a CPU firmware that controls how CPU works.


It is a good idea to have an updated Microcode.

To make sure you have the latest version of Microcode installed, run Synaptic Package Manger and search for microcode.


Depending on the type of processor your computer has, install Mcrocode for Intel or AMD processor.

My computer uses Intel 64 bit processors, so I chose the package: intel-microcode.


Once checked, confirm with Mark the additional necessary software that must be installed from Microcode.


After clicking Apply, the Microcode will be installed.


Click Apply.


The installation progress will be visible on the bar.



4. Installing build-essential.


Build-Essential is a powerful and useful software package that is used to compile programs including chess engines. It is a good idea to install it shortly after starting a new Debian 11 system.


Open Terminal and type the following commands:


sudo apt install build-essential

Press the Enter key.


Confirm by pressing the Y key or the Enter key.


Let's verify that the GCC compiler included in the build-essential package is installed, type:


gcc --version

Perfect! Build-essential package and GCC installed.


Now we will add the linux-headers package.


sudo apt install dkms linux-headers-$(uname -r)

Yes, approve.


5. Installing restricted extras.


We will install useful add-ons such as codecs, fonts, support for RAR archives and more.


Open Terminal and type:

sudo apt install ttf-mscorefonts-installer rar unrar libavcodec-extra gstreamer1.0-libav gstreamer1.0-plugins-ugly gstreamer1.0-vaapi

Of course - confirm.


After a while we receive messages - everything has been installed without errors.



6. Installing Microsoft fonts compatibility.


If you want fonts in Debian 11 that are almost identical to those in Microsoft Office, install the alternatives with a command:


sudo apt install fonts-crosextra-carlito fonts-crosextra-caladea



7. Swappiness - configuration.


In today's computers, RAM is fast or ... very fast :) To easily improve the performance of Debian 11 even more, decrease the swappiness value.

This will result in Linux using RAM instead of the hard disk (which is slower than RAM) when needed.


Important!

This method is not recommended if you are using an old computer with slow RAM - it can lead to intermittent operation and crashes of Debian 11.



First check the current swappiness value, type:


cat /proc/sys/vm/swappiness # 60 (default)


As you can see, the system returned a default value of 60.

Let's change this value to 10.


Open /etc/sysctl.conf file as an administrator:


sudo nano /etc/sysctl.conf

At the end of the file, add vm.swappiness=10 which will reduce swap usage.


Press CTRL + O to save changes and CTRL + X to exit the nano editor.


Reboot the system.


Let's verify that the system is working with the changed swappiness value.

It is ok.



8. Faster system startup.


Each time Debian 11 is booted, a welcome screen is shown and after 5 seconds a boot sequence is executed.

We can configure the boot loader to boot immediately.


Type:


sudo nano /etc/default/grub

Change the value of GRUB_TIMEOUT from 5


To 0.


Press CTRL + O to save changes and CTRL + X to exit the nano editor.


Update the boot loader by typing the command:


sudo update-grub


Reboot the system.


If in the future you need the boot loader (GRUB) screen, you can display it by pressing SHIFT when starting Debian 11.


9. Firewall installation


The fact is that there are not many viruses and malware on Linux. And this is very good news for us - users.

Almost all modern Internet access points (e.g. routers, mesh sets) have built-in Firewall. However, it's not a bad idea to take additional proactive steps to further protect the data on our system.


You can install a firewall in Debian 11. This is optional, but advisable.


Type:


sudo apt install ufw


Activate the Firewall by typing:


sudo ufw enable


Let's check its current status, type:


sudo ufw status verbose


Everything is fine. The default settings are appropriate for most users.



10. Install BackUp Program.


There is a saying that "users are divided into those who do backups and those who will do backups."

Unfortunately, there is a lot of truth in this, and some users find out when they (for various reasons) lose important data.


On a Debian 11 system, I recommend backing up your data with Timeshift.


Open Synaptic Package Manager, search for Timeshift and install it.


Confirm by clicking Apply.


Once installed, we can open Timeshift using the program finder.


After starting Timeshift we are shown a Setup Wizard with which we can configure the program.


The setup is simple.


You can choose how many snapshots Timeshift will perform / store on a monthly, weekly, daily, hourly and boot basis


Allows you to decide which folders Timeshift will back up. You should prioritize your home directory, but depending on your space, it won’t a bad idea to include /root directory as well.


Setup completed.


Timeshift program has been activated. Of course, you can change the settings as needed.



11. Enable GNOME extensions.


The desktop you use in Debian 11 is called GNOME. Right out of the box, GNOME is minimalistic and "almost" invisible to the user. The intention is that once Debian has GNOME installed, nothing should distract the user and everything should work perfectly. Indeed, it does.


However, if you wish to enhance GNOME's capabilities, there is nothing stopping you from doing so.


First check which extensions are already installed and which you can activate.

Find Extensions in the program browser and open it.


As we can see, the system puts quite a few different extensions at the user's disposal, they are disabled by default.


I suggest enabling:

  • User Themes, which will allow you to make easy changes to your system's appearance.

  • Window List, which will make all open programs visible as bars at the bottom of the screen; making them easier to access.


Now with Firefox web browser go to GNOME Extensions website and install their browser extension first if you don’t have it already.


Install the Firefox extension by clicking the link marked with a red border.


A window appears in which you click on Continue to Installation.


Click Add.


Click Okay.

The Firefox extension has been installed.


Now you can install any GNOME Extension with a few clicks :)

We will use this functionality in the next two sections.



12. Enable Tray Icons.


Some programs can be used through their icon in the tray. For example Dropbox, Skype, Zoom and many others offer this possibility.

To make this work in GNOME we will install an extension called TopIcons Plus.


Search by topicons name.

Click on the name of this extension.


Ok, now click the button located at the top right of the window. When you click this button, it should show ON.


When you start a program that can use the tray, you should see its icon at the top of the screen in the tray.


It is a good idea to place this icon on the side of the screen so it is not centrally visible.

Go to GNOME Extensions, click on the gear wheel - TopIcons Plus extension settings.


And select the Tray location on the screen.

I chose the right side.


Perfect! That was the point.



13. Install additional GNOME themes.


Go to the website: https://www.gnome-look.org


You will find hundreds of different extensions for GNOME. They are categorized for easy site navigation.


Let's install something cool :)

When you go to the Rating tab, you can see the top extensions sorted by user ratings.


I chose Orchis gtk theme.


Once you have navigated to this extension, under the Files tab, click on the package marked with a red border.


When the download is complete, go to the Downloads folder and extract the downloaded package.


A directory named orchis will appear.


Double-click the orchis folder to open it.

Select everything and...


move it or copy it to the .themes directory.


The .themes directory should be in the Home directory. If it is not there, create one.
Remember to show hidden directories (they have a dot in front of the name) using the CTRL+H shortcut beforehand.

Open Tweaks.


Proceed to Apperance.

After expanding the Themes components, you can choose Orchis or any other theme you have downloaded.


In the case of Orchis, it is possible to select it for Applications and Shell.


Immediately after selection, GNOME components are changed.


In this way, you can customize the appearance of the entire system - all of its components - according to your preferences.

Example in the image below, in addition I added wallpaper and orchis icons (a .icons folder must be created in the Home folder).



14. Add user image.


When personalizing Debian 11 don't forget to add a picture representing the user of this system :)


Open the system settings and go to Users.


When you click on the icon (in my case named C), you can take a picture or select a picture file.


Here is the look after the change.



15. Add the minimize and maximize button.


By default, GNOME does not provide a minimize and maximize button. We can change this.


Open Tweaks,