As these “big” updates happen regularly, you might ask another question: why has this system 6500 packages?
It depends…but there are some basic mitigations which reduce the overall amount of packages on every system.
- Skim regularly through your app list. Do i need this app? No? Uninstall it. Do you need a special pattern? No? Remove it…
- How to properly uninstall a package? Do not simply remove a package via
zypper rm <package>. Uninstall all the deps which came with the installation of the package (and are no longer needed) viazypper rm --clean-deps <package>(the same can be achived by setting the checkbox in Myrlyn to remove unneeded deps on removal of a package)
See this easy example. A package gets installed and installs 8 deps:
ich@rennsemmel:~> LANG=C sudo zypper in kmahjongg
Refreshing service 'NVIDIA'.
Refreshing service 'openSUSE'.
Loading repository data...
Reading installed packages...
Resolving package dependencies...
The following 9 NEW packages are going to be installed:
kmahjongg kmahjongg-lang libKDEGames6 libKMahjongg6 libkdegames libkdegames-imports libkdegames-lang libkmahjongg libkmahjongg-lang
9 new packages to install.
Package download size: 6.4 MiB
Package install size change:
| 9.0 MiB required by packages that will be installed
9.0 MiB | - 0 B released by packages that will be removed
Backend: classic_rpmtrans
Continue? [y/n/v/...? shows all options] (y):
Preloading: libkdegames-26.04.0-1.2.x86_64.rpm [done]
Preloading: libkmahjongg-lang-26.04.0-1.2.noarch.rpm [Error: "The requested URL returned error: 404", trying next mirror.]
Preloading: libkdegames-imports-26.04.0-1.2.x86_64.rpm [done]
Preloading: libkmahjongg-lang-26.04.0-1.2.noarch.rpm [done]
Preloading: libkdegames-lang-26.04.0-1.2.noarch.rpm [done]
Preloading: libKMahjongg6-26.04.0-1.2.x86_64.rpm [Error: "The requested URL returned error: 404", trying next mirror.]
Preloading: libKMahjongg6-26.04.0-1.2.x86_64.rpm [done]
Preloading: libKDEGames6-26.04.0-1.2.x86_64.rpm [done]
Preloading: kmahjongg-26.04.0-1.2.x86_64.rpm [done]
Preloading: libkmahjongg-26.04.0-1.2.x86_64.rpm [done]
Preloading: kmahjongg-lang-26.04.0-1.2.noarch.rpm [done]
Preload finished. [success (6.1 MiB/s) ] ................................................................................................................................................................................................[done]
Retrieving: libkdegames-26.04.0-1.2.x86_64 (repo-oss) (1/9), 17.1 KiB
Retrieving: libkmahjongg-26.04.0-1.2.x86_64 (repo-oss) (2/9), 2.0 MiB
Retrieving: libkdegames-lang-26.04.0-1.2.noarch (repo-oss) (3/9), 121.8 KiB
Retrieving: libKDEGames6-26.04.0-1.2.x86_64 (repo-oss) (4/9), 315.0 KiB
Retrieving: libkdegames-imports-26.04.0-1.2.x86_64 (repo-oss) (5/9), 37.1 KiB
Retrieving: libkmahjongg-lang-26.04.0-1.2.noarch (repo-oss) (6/9), 39.4 KiB
Retrieving: libKMahjongg6-26.04.0-1.2.x86_64 (repo-oss) (7/9), 55.7 KiB
Retrieving: kmahjongg-26.04.0-1.2.x86_64 (repo-oss) (8/9), 678.2 KiB
Retrieving: kmahjongg-lang-26.04.0-1.2.noarch (repo-oss) (9/9), 3.1 MiB
Checking for file conflicts: ............................................................................................................................................................................................................[done]
(1/9) Installing: libkdegames-26.04.0-1.2.x86_64 ........................................................................................................................................................................................[done]
(2/9) Installing: libkmahjongg-26.04.0-1.2.x86_64 .......................................................................................................................................................................................[done]
(3/9) Installing: libkdegames-lang-26.04.0-1.2.noarch ...................................................................................................................................................................................[done]
(4/9) Installing: libKDEGames6-26.04.0-1.2.x86_64 .......................................................................................................................................................................................[done]
(5/9) Installing: libkdegames-imports-26.04.0-1.2.x86_64 ................................................................................................................................................................................[done]
(6/9) Installing: libkmahjongg-lang-26.04.0-1.2.noarch ..................................................................................................................................................................................[done]
(7/9) Installing: libKMahjongg6-26.04.0-1.2.x86_64 ......................................................................................................................................................................................[done]
(8/9) Installing: kmahjongg-26.04.0-1.2.x86_64 ..........................................................................................................................................................................................[done]
(9/9) Installing: kmahjongg-lang-26.04.0-1.2.noarch .....................................................................................................................................................................................[done]
Running post-transaction scripts ........................................................................................................................................................................................................[done]
ich@rennsemmel:~>
Now simply remove the main package (the “bad” way). Only 2 packages get uninstalled.
ich@rennsemmel:~> LANG=C sudo zypper rm kmahjongg
Reading installed packages...
Resolving package dependencies...
The following 2 packages are going to be REMOVED:
kmahjongg kmahjongg-lang
2 packages to remove.
Package install size change:
| 0 B required by packages that will be installed
-5.1 MiB | - 5.1 MiB released by packages that will be removed
Backend: classic_rpmtrans
Continue? [y/n/v/...? shows all options] (y):
(1/2) Removing: kmahjongg-lang-26.04.0-1.2.noarch .......................................................................................................................................................................................[done]
(2/2) Removing: kmahjongg-26.04.0-1.2.x86_64 ............................................................................................................................................................................................[done]
Running post-transaction scripts ........................................................................................................................................................................................................[done]
ich@rennsemmel:~>
How it is done properly with --clean-deps: all 9 packages get removed.
ich@rennsemmel:~> LANG=C sudo zypper rm --clean-deps kmahjongg
Reading installed packages...
Resolving package dependencies...
The following 9 packages are going to be REMOVED:
kmahjongg kmahjongg-lang libKDEGames6 libKMahjongg6 libkdegames libkdegames-imports libkdegames-lang libkmahjongg libkmahjongg-lang
9 packages to remove.
Package install size change:
| 0 B required by packages that will be installed
-9.0 MiB | - 9.0 MiB released by packages that will be removed
Backend: classic_rpmtrans
Continue? [y/n/v/...? shows all options] (y):
(1/9) Removing: kmahjongg-lang-26.04.0-1.2.noarch .......................................................................................................................................................................................[done]
(2/9) Removing: libkdegames-lang-26.04.0-1.2.noarch .....................................................................................................................................................................................[done]
(3/9) Removing: libkmahjongg-lang-26.04.0-1.2.noarch ....................................................................................................................................................................................[done]
(4/9) Removing: kmahjongg-26.04.0-1.2.x86_64 ............................................................................................................................................................................................[done]
(5/9) Removing: libKMahjongg6-26.04.0-1.2.x86_64 ........................................................................................................................................................................................[done]
(6/9) Removing: libKDEGames6-26.04.0-1.2.x86_64 .........................................................................................................................................................................................[done]
(7/9) Removing: libkmahjongg-26.04.0-1.2.x86_64 .........................................................................................................................................................................................[done]
(8/9) Removing: libkdegames-imports-26.04.0-1.2.x86_64 ..................................................................................................................................................................................[done]
(9/9) Removing: libkdegames-26.04.0-1.2.x86_64 ..........................................................................................................................................................................................[done]
Running post-transaction scripts ........................................................................................................................................................................................................[done]
…see next comment for further recommendations (size limit applies)