This is a repost of the updated guide, because the old post has been closed in the meantime.
You can always find the most recent version of this guide on my GitLab page.
Kubuntu 24.04 LTS - essential and advisable things to do directly after an installation
I always perform (and strongly recommend) the following 6 (7) steps directly after any Kubuntu 24.04 LTS desktop installation. These steps usually take 5 to 10 minutes (including restart) if you have at least a little experience with these kinds of things:
To do so
-> open the Konsole terminal emulator from your -> Application Launcher -> System.
Please copy and paste the following commands one by one into Konsole - e.g. with your mouse or with
[Ctrl] [c] and [Ctrl] [Shift] [v] - and execute them with [Return].
Double-check that you did not miss a character or two. ;-)
Everything with a grey background behind a single "⦁" is a whole command and has to be copied as a whole - even if it is longer than one line.
- Preliminary remark: I consider the following step 1. important, but - as far as I could test - it is only necessary for a new installation on specific targets such as SATA HDDs, SATA SSDs and certain virtual machines - and all with ext4 file systems.
The bug does not seem to occur if the installation target is an ext4 file system e.g. on an NVMe SSD connected to an M.2 port - as used by the majority of computers produced in recent years.
1. Please correct a possible installation bug for ext4 file systems in the /etc/fstab file first
(= replace the "discard" option with "defaults" because a systemd timer for fstrim is already running)!
- Technical background: To not do both is recommended by e.g. Red Hat and the ArchWiki (and openSUSE, Debian or Ubuntu's main distribution also do not do it)!
Furthermore Red Hat and SUSE (openSUSE) also recommend in general to use a timer/fstrim instead of the "discard" option (and Fedora, Debian or Ubuntu's main distribution also use fstrim.timer instead) - except for special cases.
If you are unlucky, using the "discard" option in /etc/fstab may decrease the SSD's lifetime and can lead to performance degradation. Also fstrim can behave unpredictably when the "discard" option is additionally set…
In case you don't know whether you chose the ext4 file system during installation (the chance you did is quite high as it is the default for Kubuntu 24.04 LTS), in case the installation bug did not occur, or if the bug has been corrected in the meantime:
The following cp command in step 1. a) and b) will just make a backup copy of your /etc/fstab file, and neither the following sed command in step 1. a) nor in b) will do anything at all.
a) either I would even suggest the additional option "noatime" if you don't run any programs (such as certain servers) that specifically need information about when a file or folder was accessed (= opened or read) and therefore to use b).
This makes old HDDs run a tiny little bit faster because it reduces write actions - and thus also wear on SSDs:
OR
b) alternatively For safety reasons don't use the sed commands of step 1. a) or b) in any other context than a fresh Kubuntu 24.04 LTS installation!
Instead check and modify your /etc/fstab file by hand if need be - and back it up first.
The change will be applied with the reboot after step 6. (7.)
2. Reduce swappiness for desktop installations like it is suggested for *Ubuntu and like e.g. TUXEDO OS also does it
(= the system will use the physical memory modules longer and use the swap file or partition later).
If you are curious you can check the setting before and after the reboot with sudo sysctl vm.swappiness. The change will be applied with the reboot after step 6. (7.)
3. Reduce systemd timeouts for desktop installations like KDE suggests for Plasma in their Distribution/Packaging Recommendations
(= the system will not "hang" for 90 seconds - which is the default value - from time to time when logging out, rebooting or shutting down).
I am reasonably conservative here and use 15 seconds because on older machines it has seldom taken as long as 10–14 seconds for certain processes to quit gracefully by themselves (for example: KDE neon used to use 5 seconds, TUXEDO OS and Garuda KDE use 10 seconds). The change will be applied with the reboot after step 6. (7.)
4.a) Change GRUB (the boot loader) to show the boot menu for 1 second in single-boot setups
(= only Kubuntu is installed - this makes the boot menu much easier to access whenever you might need it). OR
4.b) Change GRUB to show the boot menu with all installed systems for 5 seconds in multi-boot setups
(= Kubuntu and another Linux or/and Windows are installed - and make sure to definitely disable Windows fast startup if you intend to access the "C:" drive from Linux). The change will be visible during the reboot after step 6. (7.)
5. Update your system and your programs for the first time
(this is generally one of the first things you should do after installing any operating system). In case this is not a fresh Kubuntu 24.04 LTS installation, be careful with the autopurge in step 5. and thoroughly read and understand the output in Konsole !
6. Install missing essential software for desktop installations like
7. If you have a DVD or Blu-ray drive, install libdvdcss to be able to play back e.g. encrypted video DVDs.
You can select with [Tab] and confirm with [Return] in the following dialogues - select "Ok" and "Yes" to install.
Bonus - 5 individual and potentially less important things to do:
Everything with a grey background behind a single "⦁" is a whole command and has to be copied into Konsole as a whole - even if it is longer than one line.
a. It is possible to remove Snap from Kubuntu 24.04 LTS and/or use the "traditional" Firefox and Thunderbird instead of or additionally to the Snaps
(you could use the following shell scripts).
b. Enable Flatpak instead of or additionally to Snap
(e.g. to increase your pool of available programs). You will have to log out and in again or reboot to apply the change.
If need be, you now have the possibility to adjust the permissions of installed Flatpaks
in -> System Settings -> Applications (section: Personalization) -> Flatpak Permission Settings.
Also see Flatpak Kubuntu Quick Setup.
c. Enable password feedback for the command line interface
(= so you can see something like ***** instead of nothing when typing in your password in Konsole - like you can see it in e.g. Linux Mint and Garuda KDE). You will have to close Konsole and open it again to apply the change.
d. Always start with an empty session
(e.g. for stability, performance or security reasons).
Go to -> System Settings -> Startup and Shutdown (section: Workspace) -> Desktop Session -> Session Restore
and set “On login, launch apps that were open:”
to “Start with an empty session”.
Click [Apply].
You will have to log out and in again or reboot to apply the change.
e. Disable fast user switching
(e.g. for security or performance reasons in multi-user setups). You will have to log out and in again or reboot to apply the change.
You can always find the most recent version of this guide on my GitLab page.
Kubuntu 24.04 LTS - essential and advisable things to do directly after an installation
I always perform (and strongly recommend) the following 6 (7) steps directly after any Kubuntu 24.04 LTS desktop installation. These steps usually take 5 to 10 minutes (including restart) if you have at least a little experience with these kinds of things:
To do so
-> open the Konsole terminal emulator from your -> Application Launcher -> System.
Please copy and paste the following commands one by one into Konsole - e.g. with your mouse or with
[Ctrl] [c] and [Ctrl] [Shift] [v] - and execute them with [Return].
Double-check that you did not miss a character or two. ;-)
Everything with a grey background behind a single "⦁" is a whole command and has to be copied as a whole - even if it is longer than one line.
- Preliminary remark: I consider the following step 1. important, but - as far as I could test - it is only necessary for a new installation on specific targets such as SATA HDDs, SATA SSDs and certain virtual machines - and all with ext4 file systems.
The bug does not seem to occur if the installation target is an ext4 file system e.g. on an NVMe SSD connected to an M.2 port - as used by the majority of computers produced in recent years.
1. Please correct a possible installation bug for ext4 file systems in the /etc/fstab file first
(= replace the "discard" option with "defaults" because a systemd timer for fstrim is already running)!
- Technical background: To not do both is recommended by e.g. Red Hat and the ArchWiki (and openSUSE, Debian or Ubuntu's main distribution also do not do it)!
Furthermore Red Hat and SUSE (openSUSE) also recommend in general to use a timer/fstrim instead of the "discard" option (and Fedora, Debian or Ubuntu's main distribution also use fstrim.timer instead) - except for special cases.
If you are unlucky, using the "discard" option in /etc/fstab may decrease the SSD's lifetime and can lead to performance degradation. Also fstrim can behave unpredictably when the "discard" option is additionally set…
In case you don't know whether you chose the ext4 file system during installation (the chance you did is quite high as it is the default for Kubuntu 24.04 LTS), in case the installation bug did not occur, or if the bug has been corrected in the meantime:
The following cp command in step 1. a) and b) will just make a backup copy of your /etc/fstab file, and neither the following sed command in step 1. a) nor in b) will do anything at all.
a) either
- sudo cp /etc/fstab /etc/fstab.orig
(this makes a backup of your /etc/fstab file first) - sudo sed -i '/ext4/ s/discard/defaults/g' /etc/fstab
(this replaces the wrong option with the right one - only if applicable)
This makes old HDDs run a tiny little bit faster because it reduces write actions - and thus also wear on SSDs:
OR
b) alternatively
- sudo cp /etc/fstab /etc/fstab.orig
(this makes a backup of your /etc/fstab file first) - sudo sed -i '/ext4/ s/discard/defaults,noatime/g' /etc/fstab
(this replaces the wrong option with the right ones - only if applicable)
Instead check and modify your /etc/fstab file by hand if need be - and back it up first.
The change will be applied with the reboot after step 6. (7.)
2. Reduce swappiness for desktop installations like it is suggested for *Ubuntu and like e.g. TUXEDO OS also does it
(= the system will use the physical memory modules longer and use the swap file or partition later).
If you are curious you can check the setting before and after the reboot with sudo sysctl vm.swappiness.
- echo -e "# Reduce swappiness for desktop installation (default = 60)\nvm.swappiness=10" | sudo tee /etc/sysctl.d/99-sysswappiness.conf
(this writes the modified value to your system)
3. Reduce systemd timeouts for desktop installations like KDE suggests for Plasma in their Distribution/Packaging Recommendations
(= the system will not "hang" for 90 seconds - which is the default value - from time to time when logging out, rebooting or shutting down).
I am reasonably conservative here and use 15 seconds because on older machines it has seldom taken as long as 10–14 seconds for certain processes to quit gracefully by themselves (for example: KDE neon used to use 5 seconds, TUXEDO OS and Garuda KDE use 10 seconds).
- sudo mkdir -p /etc/systemd/system.conf.d && echo -e "# Reduce timeout (default = 90s)\n\n[Manager]\nDefaultTimeoutStopSec=15s" | sudo tee /etc/systemd/system.conf.d/99-systemtimeout.conf
(this writes the modified value for the system processes to your system) - sudo mkdir -p /etc/systemd/user.conf.d && echo -e "# Reduce timeout (default = 90s)\n\n[Manager]\nDefaultTimeoutStopSec=15s" | sudo tee /etc/systemd/user.conf.d/99-usertimeout.conf
(this writes the modified value for the user processes to your system)
4.a) Change GRUB (the boot loader) to show the boot menu for 1 second in single-boot setups
(= only Kubuntu is installed - this makes the boot menu much easier to access whenever you might need it).
- sudo cp /etc/default/grub /etc/default/grub.orig
(this makes a backup of your /etc/default/grub file first) - sudo sed -i 's/GRUB_TIMEOUT_STYLE=hidden/GRUB_TIMEOUT_STYLE=menu/' /etc/default/grub
(this makes GRUB show the boot menu) - sudo sed -i 's/GRUB_TIMEOUT=0/GRUB_TIMEOUT=1/' /etc/default/grub
(this writes the timeout value to your system) - echo -e "\n# Match RECORDFAIL_TIMEOUT to TIMEOUT\nGRUB_RECORDFAIL_TIMEOUT=\$GRUB_TIMEOUT" | sudo tee -a /etc/default/grub
(this keeps the timeout value if GRUB has "problems" with a partition - could be e.g. Btrfs or LVM) - sudo update-grub
(this updates your GRUB boot loader with the new values)
4.b) Change GRUB to show the boot menu with all installed systems for 5 seconds in multi-boot setups
(= Kubuntu and another Linux or/and Windows are installed - and make sure to definitely disable Windows fast startup if you intend to access the "C:" drive from Linux).
- sudo cp /etc/default/grub /etc/default/grub.orig
(this makes a backup of your /etc/default/grub file first) - sudo sed -i 's/GRUB_TIMEOUT_STYLE=hidden/GRUB_TIMEOUT_STYLE=menu/' /etc/default/grub
(this makes GRUB show the boot menu) - sudo sed -i 's/GRUB_TIMEOUT=0/GRUB_TIMEOUT=5/' /etc/default/grub
(this writes the timeout value to your system) - echo -e "\n# Match RECORDFAIL_TIMEOUT to TIMEOUT\nGRUB_RECORDFAIL_TIMEOUT=\$GRUB_TIMEOUT" | sudo tee -a /etc/default/grub
(this keeps the timeout value if GRUB has "problems" with a partition - could be e.g. Btrfs or LVM) - sudo sed -i 's/#GRUB_DISABLE_OS_PROBER=false/GRUB_DISABLE_OS_PROBER=false/' /etc/default/grub
(this makes other systems visible in the boot menu) - sudo update-grub
(this updates your GRUB boot loader with the new values)
5. Update your system and your programs for the first time
(this is generally one of the first things you should do after installing any operating system).
- sudo snap refresh && sudo systemctl daemon-reload
(this updates the Snaps - not necessary if you have chosen the "Minimal Installation" option) - sudo apt update && sudo apt full-upgrade
(this updates your installation - except for the Snaps) - sudo apt autopurge && sudo apt autoclean
(this removes remaining packages from the installation process - if there are any)
6. Install missing essential software for desktop installations like
- multimedia codecs etc.
- Microsoft Web and replacement fonts.
- exFAT utilities (the file system you should use to format USB sticks and to share them between Linux, Windows and macOS).
You can select with [Tab] and confirm with [Return] in the following dialogues - select "Ok" and "Yes" to install.
- sudo apt install kubuntu-restricted-extras gstreamer1.0-vaapi fonts-crosextra-carlito fonts-crosextra-caladea exfatprogs
(this installs all of the above listed)
7. If you have a DVD or Blu-ray drive, install libdvdcss to be able to play back e.g. encrypted video DVDs.
You can select with [Tab] and confirm with [Return] in the following dialogues - select "Ok" and "Yes" to install.
- sudo apt install libdvd-pkg
(this installs the play back for encrypted media) - sudo dpkg-reconfigure libdvd-pkg
(this activates the play back for encrypted media)
- reboot and enjoy Kubuntu 24.04 LTS !
Bonus - 5 individual and potentially less important things to do:
Everything with a grey background behind a single "⦁" is a whole command and has to be copied into Konsole as a whole - even if it is longer than one line.
a. It is possible to remove Snap from Kubuntu 24.04 LTS and/or use the "traditional" Firefox and Thunderbird instead of or additionally to the Snaps
(you could use the following shell scripts).
- Script to get rid of Snap (like e.g. Linux Mint and TUXEDO OS do - can also block Snap in a "Minimal Installation")
- Script to install "traditional" Firefox (the way e.g. Debian suggested formerly, installs as shown on Mozilla.org)
- Script to install "traditional" Thunderbird (installs as shown on Mozilla.org)
b. Enable Flatpak instead of or additionally to Snap
(e.g. to increase your pool of available programs).
- sudo apt update && sudo apt install flatpak plasma-discover-backend-flatpak kde-config-flatpak
(this installs Flatpak for your system, Flatpak support for Discover and Flatpak permission management for System Settings) - flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
(this adds Flathub, currently the largest repository for Flatpaks)
If need be, you now have the possibility to adjust the permissions of installed Flatpaks
in -> System Settings -> Applications (section: Personalization) -> Flatpak Permission Settings.
Also see Flatpak Kubuntu Quick Setup.
c. Enable password feedback for the command line interface
(= so you can see something like ***** instead of nothing when typing in your password in Konsole - like you can see it in e.g. Linux Mint and Garuda KDE).
- echo -e "# Enable password feedback\nDefaults pwfeedback" | sudo tee /etc/sudoers.d/pwfeedback
(this writes the modified value to your system) - sudo chmod 0440 /etc/sudoers.d/pwfeedback
(this applies the correct permissions to the written file)
d. Always start with an empty session
(e.g. for stability, performance or security reasons).
Go to -> System Settings -> Startup and Shutdown (section: Workspace) -> Desktop Session -> Session Restore
and set “On login, launch apps that were open:”
to “Start with an empty session”.
Click [Apply].
You will have to log out and in again or reboot to apply the change.
e. Disable fast user switching
(e.g. for security or performance reasons in multi-user setups).
- sudo mkdir -p /etc/xdg && echo -e "\n[KDE Action Restrictions] [\$i]\naction/switch_user=false\naction/start_new_session=false" | sudo tee -a /etc/xdg/kdeglobals
(this writes the modified values for all users to your system)

