Post

Ubuntu 20.04 performance optimization

Unless you are using a PC with Ubuntu OS installed as your main computer, you are likely to be using a PC with low hardware specifications or installing Ubuntu on Oracle VM VirtualBox.

If you mainly use SSH to connect remotely, it won’t have much of an impact, but if you often manipulate the UI in GNOME, performance may be disappointing. So, here are some tips to optimize performance when installing and configuring Ubuntu.

Turn Off Animations

If you use Ubuntu on Virtual Box or a low-end PC, animations may slow down the performance of the OS due to limited resources. Below is how to turn animations off and on in the Ubuntu GNOME GUI. You can run commands in the terminal.

Below is the terminal command to turn off Ubuntu animations and check the settings.

1
2
3
$ gsettings set org.gnome.desktop.interface enable-animations false
$ gsettings get org.gnome.desktop.interface enable-animations
false

Below is the terminal command to turn on Ubuntu animations. The difference is that the last argument of the command is changed from false to true.

1
2
3
$ gsettings set org.gnome.desktop.interface enable-animations true
$ gsettings get org.gnome.desktop.interface enable-animations
true

Dock icon size

If you’re using a limited-resolution display, the Dock’s default icon size may be limiting for registering and navigating many icons at once. So, you can set the Dock icon size to be small.

First, search for dock in the Application menu and open Appearance settings.

Dock Icon Size - Application Menu > Search `dock` > Appearance Settings Dock Icon Size - Application Menu > Search dock > Appearance Settings

Then reduce the Icon Size and set it to a size that looks good to you.

Dock Icon Size - Settings > Appearance > Resize `Icon Size` Dock Icon Size - Settings > Appearance > Resize Icon Size

Increase swap size

If you are using Ubuntu installed in Virtual Box, it is likely that less than 8GB of memory is allocated to the virtual machine because it is shared with your Windows computer. This may not be a problem if you use Ubuntu casually, but when attempting to compile a large platform, BSP, or software, insufficient memory can lead to compilation failure. This can be solved by increasing the swap size.

Since hard disk capacity is cheaper than memory capacity, let’s increase swap. Please see the article below.

  • https://unclesnote.com/en/231102005313/how_to_increase_swapfile_size_in_ubuntu

Secure free space on disk

If you are using Ubuntu with a virtual machine installed and the image size is not large enough, you may see a warning pop-up like the one below. This can occur if it accumulates in the system in temporary files or log files. If freespace converges to zero, your Ubuntu VM may not boot.

Warning Popup for Low Disk Space on Filessystem root Warning Popup for Low Disk Space on Filessystem root

Although you can delete temporary files or system log files manually, you can manage them more easily in a GUI environment by using the BleachBit application.

You can easily install it by searching for bleachbit in the Ubuntu software application.

Ubuntu Software - BleachBit Ubuntu Software - BleachBit

After checking the items you want to organize, pressing the Clean button automatically deletes unnecessary files to secure free space. However, you must be careful when organizing the APT and journald items. This may break your Ubuntu system or package dependencies.

BleachBit BleachBit

This post is licensed under CC BY 4.0 by the author.