I have to confess I haven’t removed orphaned packages yet since installing Manjaro and thought I’ll give this a go before the big update to lsb-release 24.0. I read the pacman passage in the System Maintenance wiki and started with user $ pacman -Qdt to show me the list:
Is there any package in there where I would run into problems when removing? Right after this I tried to run sudo pacman -Rs $(pacman -Qdtq) before aborting the command with the ‘n’ key:
Hmm, why would pacman mark this one as orphan then?
I’m a little bit confused now. On the one hand you say it’s okay to remove orphans but on the other hand it seems I risk bricking GNOME because of removing the display manager?
Is sudo pacman -Rs $(pacman -Qdtq) then not the right way to go?
It is always a good idea to check the result as you did - as the package manager is just a computer program which only can deduce the action to take based on information retrieved from the system.
man pacman
If you prefer something but the command line Arch Linux provides web based man pages
If you are using yay, yay -Yc is safe to remove dependencies if they are not used by any installed packages and are not explicit installed too
or paru --clean does the same.
Both of these aren’t installed yet and I don’t want to throw in another package manager in the mix when I have a big update for the next lsb-release outstanding.
pacman -Qi gdm ✔
Name : gdm
Version : 45.0.1-1
Description : Display manager and login screen
Architecture : x86_64
URL : https://wiki.gnome.org/Projects/GDM
Licenses : GPL
Groups : gnome
Provides : None
Depends On : gnome-session gnome-shell libcanberra libxdmcp systemd upower xorg-server xorg-xhost xorg-xrdb libgdm
Optional Deps : fprintd: fingerprint authentication [installed]
Required By : None
Optional For : None
Conflicts With : None
Replaces : None
Installed Size : 4,73 MiB
Packager : Jan Alexander Steffens (heftig) <heftig@archlinux.org>
Build Date : So 01 Okt 2023 14:37:29 CEST
Install Date : Di 07 Nov 2023 04:07:44 CET
Install Reason : Installed as a dependency for another package
Install Script : Yes
Validated By : Signature
It’s neither “Required” nor “Optional” for anything, yet @Zesko warns, I need it to run GNOME and the package itself says it’s the “Display manager and login screen”.
Timeshift will save your ass, so even if something goes wrong you can rollback with a Life Boot on a USB Drive and rollback your system with the Timeshift GUI and a already created snapshot.
Its easy… i did it 3 days ago again on my Laptop… just for fun
If you unsure, just buy another external HDD and backup your files additional. So you will have less fear in future and not worrie so much of something goes wrong.
It isn’t. I deliberatly chose to remove orphans before the big upgrade (that’s at least what I initially thought) because I read somewhere about big downloads because of rebuilding electron.
When I checked for orphans on my system, I noticed an old version 19 and thought it might be a good idea to get rid of that before the update.
Makes total sense, the problem is when you remove your Ophans and update instant after it, without using all program’s and all possible features around them.
You will probably never know if the program’s don’t work after, because of the update or because you removed orphans.
I’m already running a Timeshift backup on an external hdd before every update and save all my personal files with Borg via Vorta GUI. I haven’t tested the waters though which means I don’t know exactly how to restore the Timeshift backup especially without a running window manager. I thought that’s a bridge I cross when needed.
But maybe I really should read up on this realizing how quickly I can run into problems with pacman.
I haven’t made any significant changes to my GNOME system since I installed it back in February '23. I’ve investigated the issue in the forum though and found a post by @deemon back in August '23: