top of page

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, go to Window Titlebars and select the appropriate options.



16. Enable Nigh Light.


Open Settings, go to Displays - Night Light and select the appropriate options.



17. Enable FlatPak and Snap.


FlatPak and Snap are application packaging formats used in many Linux distributions, including for Debian 11.

It's worth having them installed, even if you don't use them very often. For example, the latest version of the good chess program Jerry can be installed using Snap.



Open Software program.

In the search box, type: gnome software and click on Software.


At the bottom of the newly opened page, check both options.


Confirm by entering your account password.


Flatpak and Snap will be automatically installed.

Close and then restart the Software program.


The directory from these two packages will be loaded when you run Software,


Let's test if Software is able to find the chess program Jerry that is in the Snap package.

In the search box, type: Jerry

It works!


After clicking on the program icon a new window will open where we can read about Jerry and install it.



18. Running executable text files.


Some Linux programs are run using what is called an executable text file (script).

Such programs include Banksia GUI - a Free Chess Graphical User Interface.


But no worries, there is no need to create such a file; there is an executable file in Banksia GUI.


In this section, I'll show you what to do to make Debian 11 run Banksia GUI the standard way, by double-clicking on the executable file with the left mouse button.


First, open the Files program.


Now click on the options icon. A menu will be expanded.


Click on Preferences.


On the Behavior tab, select Run them.


Close the Preferences window.

From now on, after double-clicking the executable text file, the program will start.


Important !

If you do not make this small but important change in the Files program, then when you double-click on an executable text file - it will be opened by a text editor. And this is not what we want - we want to run the program, not edit the startup script in a text editor.



19. Create a program shortcut.


Sometimes there is a need to create a shortcut to a program. For example, if you download a program from a developer site that is not in DEB format and is not listed in the Debian database (Software, Snap, etc).


This situation can also occur with a chess program. For example, if you do not have or delete the shortcut to the Arena program, you will only be able to run it when you enter the directory with that program.


In this section, I'll show you how to create a shortcut to Arena.


Let's get started.


1.

On my computer, the Arena program is located in the Downloads directory.


Check the computer you are using to see which directory the Arena program is in.

2.

Launch your favorite word processor. I chose the system Text Editor.


3.

Fill in. Make sure you fill it out correctly.


For your convenience, I have included this text to copy to the clipboard. You can use it.

[Desktop Entry]
Type=Application
Name=Arena
Exec=/home/chessengeria/Downloads/arenalinux_64bit_3.10beta/Arena_x86_64_linux
Path=/home/chessengeria/Downloads/arenalinux_64bit_3.10beta/
Icon=/home/chessengeria/Downloads/arenalinux_64bit_3.10beta/Arena.ico
StartupNotify=true
Terminal=false
Categories=Game;

If the Arena program is in a different directory on the computer you are using, make the appropriate changes to the text.

4.

Save the file by clicking the Save button - A new window will open.


In the Name field, type Arena.desktop

Specify the save location to: ~/.local/share/applications

Click Save to store the Arena.desktop file in the selected location.


5.

Now, I suggest you log out and log in (or reboot the system) to have the system place the icon-shortcut to the Arena program in Applications.


If we did everything correctly, the Arena shortcut will appear among the shortcuts to other programs.



20. GDebi installation.


Debian is one of the most popular Linux distributions, and consequently many companies such as Microsoft, Google and others provide software for it.

Debian users can install programs via DEB packages.

Just as, for example, in Windows the programs are in EXE format, in macOS in PKG format, so for Debian the programs prepared for installation are in DEB format.


Instead of using the Terminal command line to install programs in DEB format, you can use the gdebi program.

With gdebi and its graphical interface, you can easily install and uninstall DEB programs.


Use the Synaptic Package Manager to install gdebi.


Below is an example of using gdebi to install Dropbox.




21. Extend the Battery Life.


If you use Debian 11 on a laptop, you can install tlp, a power management tool.


Open a Terminal and type:


sudo apt install tlp


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

After the installation is complete, restart your Debian 11 system.



In the next and last part of the course: Linux for Chess Part 3 - Installing chess software in Debian 11, we will, as you may have guessed... installing chess software in Debian 11 :)




 

This is the end of the course:

Linux for Chess Part 2 - Debian 11 customization.


I invite you to choose the next course :-))


 

Comments


bottom of page