You are not logged in.
Pages: 1
I have been trying to clean some packages on my system. When i use pacman -Qtdq it jsut prints out a bunch of packages that I actually use and need. I tought its supposed to print out only orphans.
pacman -Qtdq
arch-install-scripts
aria2
base
bat
btop
chaotic-keyring
chaotic-mirrorlist
cups
dconf-editor
debootstrap
discord
distrobox
eog
etc-update
exaile
eza
fdupes
file-roller
filezilla
flatseal
fragments
fzf
gdm-settings-git
geary
gedit
gimp-extras
gnome-browser-connector
gnome-calculator
gnome-dictionary
gnome-font-viewer
gnome-logs
gnome-multi-writer
gnome-notes
gnome-shell-extension-pop-shell-git
gnome-software
gnome-sound-recorder
gnome-system-monitor
gnome-terminal
gnome-text-editor
gnome-tweaks
gparted
grub-customizer
inkscape
intel-ucode
inxi
jdownloader2
kodi-addon-audioencoder-flac
kodi-addon-audioencoder-lame
kodi-addon-audioencoder-vorbis
kodi-addon-audioencoder-wav
kodi-addon-imagedecoder-heif
kodi-addon-imagedecoder-raw
kodi-addon-inputstream-adaptive
kodi-addon-inputstream-rtmp
kodi-addon-peripheral-joystick
kodi-addon-screensaver-asteroids
kodi-addon-screensaver-biogenesis
kodi-addon-screensaver-greynetic
kodi-addon-screensaver-matrixtrails
kodi-addon-screensaver-pingpong
kodi-addon-screensaver-pyro
kodi-addon-screensaver-stars
kodi-addon-visualization-projectm
kodi-addon-visualization-shadertoy
kodi-addon-visualization-spectrum
kodi-addon-visualization-waveform
kvantum-theme-nordic-git
libreoffice-fresh
librewolf
lollypop
lsb-release
man-db
mplayer
musikcube
nano
nautilus
ncdu
neovim
nvidia-dkms
openvpn
pacman-contrib
pacutils
piavpn-bin
polari
qbittorrent-enhanced-git
qt5-styleplugins
ranger
reflector
ripgrep
screen
shell-color-scripts
spotify
telegram-desktop
tilix
tldr
vinagre
vscodium-insiders-marketplace
warp
wgetpaste
whatsapp-for-linux
yayOffline
That command does only print out orphans in the sense that they were installed as dependencies but nothing that requires them is still installed. Any of those that you actually want should be marked as explicitly installed, then you can remove anything else.
EDIT: though there are some odd entries in that list. As just one example, there are very few packages that require arch-install-scripts; that package would typically be installed explicilty. But yours was installed as a dependency. So either A) you had previously installed and have since removed at least one of archinstall, archiso, or devtools, or B) you are using some odd pacman wrapper to install packages and it is screwing up the package database with incorrect installation reasons.
Last edited by Trilby (2023-09-15 19:21:38)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
How do i mark the packages as explicitly installed?
EDIT:
I found this command: sudo pacman -D --asexplicit
How would you go on fixing this mess? Should i mark them all as explicit?
Last edited by InvisibleRasta (2023-09-15 20:21:33)
Offline
Should i mark them all as explicit?
Absolutely not - unless you really want to keep all of them (in which case you really wouldn't need to do anything anyways). I said what I would recommend.
Any of those that you actually want should be marked as explicitly installed, then you can remove anything else.
But I'd also want to find out whey there are so many packages in that list. In a properly maintained system, `pacman -Qdtq` shouldn't really produce any output - or perhaps rarely a couple packages will be listed and can then be removed. Having such a long lists suggests that either something has gone wrong with your package database, and / or you are not using the proper command to remove / uninstall packages. I'd want to figure out which of these is the case before doing much of anything else.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Well I am not sure how all those packages ended up there. To uninstall packages I use sudo pacman -Rnsc
Offline
"sudo pacman -Scc (removes unused packages)&& sudo pacman -R (all the packages comes here at the front)" is that what you mean, if not RTFM
Last edited by dhzalol (2023-09-15 22:17:38)
Offline
maybe you should learn some manners and RTFM yourself. -Scc is for cleaning cache
Offline
Remember that, in Arch-land, the F in "RTF*" stands for "Fine".
Instead of getting side-tracked by perceived (or intended) ad hominem attacks, Trilby's solution seems dead-on to me. Beyond that, we cannot know what caused this situation (though the most likely cause would be an interrupted pacman operation or other database-update failure) without more information (e.g., a pacman.log). Though, given the actual topic has been solved, I'd probably suggest marking this thread appropriately, and doing an investigation of the log yourself to see if you can diagnose the cause.
All the best,
-HG
Offline
To uninstall packages I use sudo pacman -Rnsc
That is an appropriate way. Personally I would not use the -c in this context, but that's unrelated to this thread - the -s flag is the relevant one for the present topic; I typically use -Rsn for removing.
While you can mark some of those as explicit and remove the rest, if I were in your shoes I'd check the pacman.log and search for some of those packages like arch-install-scripts. Was it actually installed as a dependency (of one of the three packages I mentioned)? Or was it originally explictly installed? If the latter, there should also be an indication in the log of when / how the package's installation reason changed.
Yay is another package in your list that is rarely pulled in as a dependency but typically explicitly installed. But I'd always advocate for removing yay, regardless of how it was installed.
Last edited by Trilby (2023-09-17 12:52:58)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
1. Maybe something from the chaotic repo depended on all of this or multiple packages did, like meta packages. You removed those packag[es] without the -s flag and now all those useful packages are orphans.
2. I'd grep my pacman log file for a few of those packages to see what happened to them.
3. Beyond diagnostics, if you want to manually flag "good" packages as explicit, I recommend fzf:
https://wiki.archlinux.org/title/Fzf
One of the examples can be modified for your case:
pacman -Qqdt | fzf --multi --preview 'pacman -Qi {1}' | xargs -ro sudo pacman -D --asexplicitMark with the tab key, execute with enter and cancel with esc.
Offline
Thank you I was able to solve it with your suggestions.
Offline
Pages: 1