Page 1 of 3 123 LastLast
Results 1 to 10 of 26

Thread: Cleanup of distribution upgrades

  1. #1
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    4,357
    Blog Entries
    5

    Default Cleanup of distribution upgrades

    Running "zypper packages --unneeded" on Tumbleweed 20220802-0 revealed no unneeded packages. Upgrading to Tumbleweed 20220804-0 resulted in:
    Code:
    6700K:~ # zypper packages --unneeded  
    Loading repository data... 
    Reading installed packages... 
    S | Repository             | Name                          | Version    | Arch 
    --+------------------------+-------------------------------+------------+------- 
    i | Haupt-Repository (OSS) | policycoreutils-lang          | 3.4-4.1    | noarch 
    i | Haupt-Repository (OSS) | python310-aiosmtpd            | 1.4.2-4.3  | noarch 
    i | Haupt-Repository (OSS) | python310-alembic             | 1.8.1-1.1  | noarch 
    i | Haupt-Repository (OSS) | python310-authheaders         | 0.14.1-1.3 | noarch 
    i | Haupt-Repository (OSS) | python310-falcon              | 3.0.1-3.5  | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.bounce        | 4.0-2.1    | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.i18n          | 4.0-2.1    | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.lock          | 7.0-1.6    | noarch 
    i | Haupt-Repository (OSS) | python310-gunicorn            | 20.1.0-2.7 | noarch 
    i | Haupt-Repository (OSS) | python310-importlib-resources | 5.4.0-1.5  | noarch 
    i | Haupt-Repository (OSS) | python310-lazr.config         | 2.2.3-1.5  | noarch 
    i | Haupt-Repository (OSS) | python310-passlib             | 1.7.4-4.6  | noarch 
    i | Haupt-Repository (OSS) | python310-zope.component      | 5.0.1-1.7  | x86_64 
    i | Haupt-Repository (OSS) | python310-zope.configuration  | 4.4.0-1.12 | noarch 
    6700K:~ #
    Removing the above and their dependencies resulted in a clean upgrade:

    Code:
    6700K:~ # zypper packages --unneeded | grep ^i|cut -d '|' -f3|xargs zypper rm --clean-deps --no-confirm 
    Reading installed packages... 
    Resolving package dependencies... 
    
    The following 40 packages are going to be REMOVED:
      libhiredis1_0_0 libmemcached11 memcached policycoreutils-lang python310-Beaker python310-Deprecated python310-Mako python310-PyNaCl python310-SQLAlchemy 
      python310-aiosmtpd python310-alembic python310-atpublic python310-authheaders python310-authres python310-bcrypt python310-dkimpy python310-falcon 
      python310-flufl.bounce python310-flufl.i18n python310-flufl.lock python310-gunicorn python310-hiredis python310-importlib-resources 
      python310-lazr.config python310-lazr.delegates python310-passlib python310-publicsuffix2 python310-pycryptodome python310-pylibmc python310-pymongo 
      python310-python-memcached python310-redis python310-scrypt python310-wrapt python310-zope.component python310-zope.configuration 
      python310-zope.hookable python310-zope.i18nmessageid python310-zope.schema redis 
    
    40 packages to remove. 
    After the operation, 52.2 MiB will be freed. 
    Continue? [y/n/v/...? shows all options] (y): y 
    ( 1/40) Removing policycoreutils-lang-3.4-4.1.noarch ...............................................................................................[done] 
    ( 2/40) Removing python310-Beaker-1.11.0-7.3.noarch ................................................................................................[done] 
    ( 3/40) Removing python310-aiosmtpd-1.4.2-4.3.noarch ...............................................................................................[done] 
    ( 4/40) Removing python310-alembic-1.8.1-1.1.noarch ................................................................................................[done] 
    ( 5/40) Removing python310-authheaders-0.14.1-1.3.noarch ...........................................................................................[done] 
    ( 6/40) Removing python310-bcrypt-3.2.2-1.4.x86_64 .................................................................................................[done] 
    ( 7/40) Removing python310-falcon-3.0.1-3.5.noarch .................................................................................................[done] 
    ( 8/40) Removing python310-flufl.bounce-4.0-2.1.noarch .............................................................................................[done] 
    ( 9/40) Removing python310-flufl.i18n-4.0-2.1.noarch ...............................................................................................[done] 
    (10/40) Removing python310-flufl.lock-7.0-1.6.noarch ...............................................................................................[done] 
    (11/40) Removing python310-gunicorn-20.1.0-2.7.noarch ..............................................................................................[done] 
    (12/40) Removing python310-hiredis-2.0.0-1.3.x86_64 ................................................................................................[done] 
    (13/40) Removing python310-importlib-resources-5.4.0-1.5.noarch ....................................................................................[done] 
    (14/40) Removing python310-lazr.config-2.2.3-1.5.noarch ............................................................................................[done] 
    (15/40) Removing python310-passlib-1.7.4-4.6.noarch ................................................................................................[done] 
    (16/40) Removing python310-pycryptodome-3.15.0-1.1.x86_64 ..........................................................................................[done] 
    (17/40) Removing python310-pymongo-4.1.1-1.1.x86_64 ................................................................................................[done] 
    (18/40) Removing python310-python-memcached-1.59-5.2.noarch ........................................................................................[done] 
    (19/40) Removing python310-redis-4.3.3-1.1.noarch ..................................................................................................[done] 
    (20/40) Removing python310-scrypt-0.8.20-1.2.x86_64 ................................................................................................[done] 
    (21/40) Removing python310-zope.component-5.0.1-1.7.x86_64 .........................................................................................[done] 
    (22/40) Removing python310-zope.configuration-4.4.0-1.12.noarch ....................................................................................[done] 
    (23/40) Removing python310-pylibmc-1.6.1-3.5.x86_64 ................................................................................................[done] 
    (24/40) Removing python310-SQLAlchemy-1.4.39-1.1.x86_64 ............................................................................................[done] 
    (25/40) Removing python310-Mako-1.2.1-1.1.noarch ...................................................................................................[done] 
    (26/40) Removing python310-publicsuffix2-2.20191221-1.11.noarch ....................................................................................[done] 
    (27/40) Removing python310-dkimpy-1.0.5-1.10.noarch ................................................................................................[done] 
    (28/40) Removing python310-atpublic-2.3-2.3.noarch .................................................................................................[done] 
    (29/40) Removing libhiredis1_0_0-1.0.2-1.5.x86_64 ..................................................................................................[done] 
    (30/40) Removing python310-lazr.delegates-2.0.4-1.11.noarch ........................................................................................[done] 
    (31/40) Removing memcached-1.6.15-1.2.x86_64 .......................................................................................................[done] 
    Failed to stop redis@.service: Unit name redis@.service is missing the instance name.
    See system logs and 'systemctl status redis@.service' for details.
    Failed to stop redis-sentinel@.service: Unit name redis-sentinel@.service is missing the instance name.
    See system logs and 'systemctl status redis-sentinel@.service' for details.
    (32/40) Removing redis-7.0.4-1.1.x86_64 ............................................................................................................[done] 
    (33/40) Removing python310-Deprecated-1.2.13-1.5.noarch ............................................................................................[done] 
    (34/40) Removing python310-zope.hookable-5.1.0-1.6.x86_64 ..........................................................................................[done] 
    (35/40) Removing python310-zope.schema-6.1.0-1.6.noarch ............................................................................................[done] 
    (36/40) Removing python310-zope.i18nmessageid-5.0.1-3.6.x86_64 .....................................................................................[done] 
    (37/40) Removing libmemcached11-1.0.18-9.5.x86_64 ..................................................................................................[done] 
    (38/40) Removing python310-authres-1.2.0-1.11.noarch ...............................................................................................[done] 
    (39/40) Removing python310-PyNaCl-1.5.0-1.3.x86_64 .................................................................................................[done] 
    (40/40) Removing python310-wrapt-1.13.3-1.5.x86_64 .................................................................................................[done] 
      
    6700K:~ #
    Removing unneeded packages results in more hassle-free maintenance. Host 6700K has some 3700 packages installed and runs "zypper dup" on a daily schedule. No problems were encountered during 3 months of operation.
    openSUSE Tumbleweed, KDE Plasma, Blogs/KeepItSimple, i7-6700K (2016), i5-8250U (2018), AMD Ryzen 5 3400G (2020), 5600X, 5700U (2022)

  2. #2
    Join Date
    Sep 2014
    Location
    Germany
    Posts
    1,088

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by karlmistelberger View Post
    Running "zypper packages --unneeded" on Tumbleweed 20220802-0 revealed no unneeded packages. Upgrading to Tumbleweed 20220804-0 resulted in:
    Code:
    6700K:~ # zypper packages --unneeded  
    Loading repository data... 
    Reading installed packages... 
    S | Repository             | Name                          | Version    | Arch 
    --+------------------------+-------------------------------+------------+------- 
    i | Haupt-Repository (OSS) | policycoreutils-lang          | 3.4-4.1    | noarch 
    i | Haupt-Repository (OSS) | python310-aiosmtpd            | 1.4.2-4.3  | noarch 
    i | Haupt-Repository (OSS) | python310-alembic             | 1.8.1-1.1  | noarch 
    i | Haupt-Repository (OSS) | python310-authheaders         | 0.14.1-1.3 | noarch 
    i | Haupt-Repository (OSS) | python310-falcon              | 3.0.1-3.5  | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.bounce        | 4.0-2.1    | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.i18n          | 4.0-2.1    | noarch 
    i | Haupt-Repository (OSS) | python310-flufl.lock          | 7.0-1.6    | noarch 
    i | Haupt-Repository (OSS) | python310-gunicorn            | 20.1.0-2.7 | noarch 
    i | Haupt-Repository (OSS) | python310-importlib-resources | 5.4.0-1.5  | noarch 
    i | Haupt-Repository (OSS) | python310-lazr.config         | 2.2.3-1.5  | noarch 
    i | Haupt-Repository (OSS) | python310-passlib             | 1.7.4-4.6  | noarch 
    i | Haupt-Repository (OSS) | python310-zope.component      | 5.0.1-1.7  | x86_64 
    i | Haupt-Repository (OSS) | python310-zope.configuration  | 4.4.0-1.12 | noarch 
    6700K:~ #
    That is interesting and leads to the question: Why does an upgrade pull in un-needed packages? Are those packages just "recommends"?

    I gave it a try on one of my openSUSE Tumbleweed installations which was installed with "no-recommends" right from the start. First I removed all "un-needed" packages and then upgraded to the current snapshot.

    After the upgrade there was a new "un-needed" package again!

    So why was this package pulled in if it is not needed and should not be installed even if it is "recommended"?

    Regards

    susejunky

  3. #3
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    4,357
    Blog Entries
    5

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by susejunky View Post
    That is interesting and leads to the question: Why does an upgrade pull in un-needed packages? Are those packages just "recommends"?

    I gave it a try on one of my openSUSE Tumbleweed installations which was installed with "no-recommends" right from the start. First I removed all "un-needed" packages and then upgraded to the current snapshot.

    After the upgrade there was a new "un-needed" package again!

    So why was this package pulled in if it is not needed and should not be installed even if it is "recommended"?

    Regards

    susejunky
    I have no idea what is going on. But it's inconsistent behavior.

    Solver configuration:
    Code:
    erlangen:~ # grep ^solver /etc/zypp/zypp.conf  
    solver.onlyRequires = true 
    solver.dupAllowDowngrade = true 
    solver.dupAllowVendorChange = true 
    erlangen:~ #
    Code:
    erlangen:~ # zypper install-new-recommends --dry-run  
    Loading repository data... 
    Reading installed packages... 
    Resolving package dependencies... 
    Nothing to do. 
    erlangen:~ # zypper install-new-recommends --dry-run --recommends  
    Loading repository data... 
    Reading installed packages... 
    Resolving package dependencies... 
    
    The following 141 NEW packages are going to be installed:
      Mesa-demo-egl NetworkManager-bluetooth NetworkManager-tui NetworkManager-wwan PackageKit PackageKit-backend-zypp PackageKit-branding-openSUSE PackageKit-gtk3-module PackageKit-lang WebKit2GTK-4.0-lang aha alsa alsa-oss alsa-plugins alsa-plugins-speexrate alsa-plugins-upmix alsa-ucm-conf alsa-utils bluez-cups discover-backend-packagekit dvdauthor dvgrab fwupd-bash-completion gdk-pixbuf-loader-libheif gimp-plugin-aa gimp-plugins-python gnome-online-accounts gnome-online-accounts-lang gnome-themes-accessibility gnome-themes-accessibility-gtk2 google-noto-coloremoji-fonts gstreamer-libnice gstreamer-plugins-bad gstreamer-plugins-bad-lang gtk2-engine-hcengine gtk4-branding-openSUSE gtk4-metatheme-greybird-geeko hwloc-devel icewm icewm-config-upstream icewm-default icewm-lang kguiaddons libSoundTouch1 libWPEBackend-fdo-1_0-1 libatopology2 libavtp0 libcdt5 libcgraph6 libdbus-glib-1-2-32bit libevent-devel libgdk_pixbuf_xlib-2_0-0 libgoa-backend-1_0-1 libgssdp-1_2-0 libgstadaptivedemux-1_0-0 libgstbadaudio-1_0-0 libgstbasecamerabinsrc-1_0-0 libgstcodecparsers-1_0-0 libgstcodecs-1_0-0 libgstisoff-1_0-0 libgstmpegts-1_0-0 libgstsctp-1_0-0 libgsturidownloader-1_0-0 libgstva-1_0-0 libgstvulkan-1_0-0 libgstwayland-1_0-0 libgstwebrtc-1_0-0 libgupnp-1_2-1 libgupnp-igd-1_0-4 libgvc6 libhiredis1_0_0 libiec61883-0 liblrdf2 libmanette-0_2-0 libnewt0_52 libnice10 libpathplan4 libproxy1-pacrunner-duktape libpython2_7-1_0 libqt5-qtspeech-plugin-speechd librest-0_7-0 libspandsp3 libsrtp2-1 libwebkit2gtk-4_0-37 libwoff2common1_0_2 libwoff2dec1_0_2 libwpe-1_0-1 libyui-qt-graph16 libzbar0 memcached nss-mdns-32bit ntfs-3g nvme-cli-bash-completion openssh-askpass-gnome perl-File-FcntlLock perl-RPM2 phonon4qt5-backend-gstreamer phonon4qt5-backend-gstreamer-lang pipewire-alsa plasma5-pk-updates plasma5-pk-updates-lang pmix-devel pmix-headers power-profiles-daemon python python-base python-gobject2 python-gtk python-xml python2-pycairo python310-Babel python310-Genshi python310-PySocks python310-colorama python310-dbm python310-h2 python310-hpack python310-hyperframe python310-pip python310-pytz python38-Brotli python38-Deprecated python38-hiredis python38-python-memcached python38-redis python38-wrapt qt6-imageformats qt6-platformtheme-gtk3 qt6-printsupport-cups qt6-translations rclone-bash-completion redis sqlite3-devel udiskie-lang webkit2gtk-4_0-injected-bundles xclock xdg-menu xscreensaver xscreensaver-data xscreensaver-lang yast2-sound 
    
    141 new packages to install. 
    Overall download size: 52.8 MiB. Already cached: 11.4 MiB. After the operation, additional 212.5 MiB will be used. 
    Continue? [y/n/v/...? shows all options] (y): 
    
    Checking for file conflicts: (113 skipped) .............................................................................................................................................................................................[done] 
    Warning: 113 packages had to be excluded from file conflicts check because they are not yet downloaded. 
    
        Note: Checking for file conflicts requires not installed packages to be downloaded in advance in 
        order to access their file lists. See option '--download-in-advance / --dry-run --download-only' 
        in the zypper manual page for details. 
    
    erlangen:~ #
    openSUSE Tumbleweed, KDE Plasma, Blogs/KeepItSimple, i7-6700K (2016), i5-8250U (2018), AMD Ryzen 5 3400G (2020), 5600X, 5700U (2022)

  4. #4
    Join Date
    Sep 2013
    Location
    Norfolk, UK
    Posts
    2,402

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by susejunky View Post
    ...

    So why was this package pulled in if it is not needed and should not be installed even if it is "recommended"?
    I've not looked at this, but my initial guess would be perhaps it's related to the setting of (zypp.conf) "solver.focus"
    Regards, Paul

  5. #5
    Join Date
    Sep 2014
    Location
    Germany
    Posts
    1,088

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by tannington View Post
    I've not looked at this, but my initial guess would be perhaps it's related to the setting of (zypp.conf) "solver.focus"
    On my system "solver.focus" is not set
    Code:
    > cat /etc/zypp/zypp.conf | grep "solver.focus"
    # solver.focus =
    >
    according to the comments provided
    Quote Originally Posted by /etc/zypp/zypp.conf
    ##
    ## The solvers general attitude when resolving jobs.
    ##
    ## Valid values:
    ##
    ## Job - Focus on installing the best version of the requested packages.
    ## Add missing dependencies as needed. This is the solvers default.
    ##
    ## Installed - Focus on applying as little changes to the installed packages
    ## as needed. Choosing an older version of a package is valid if
    ## it's dependencies require less changes to the system.
    ##
    ## Update - Focus on updating requested packages and their dependencies as
    ## much as possible.
    ##
    ## Default - If the value is not set, empty or unknown, we use the default.
    this should be equivalent to "solver.focus = Job".

    However I can't see why any of these focus-options should cause a package to be installed (by zypper dup) although
    • it is "not needed" and
    • "solver.onlyRequires = true" is set, so that even a (newly) recommended package should not be installed.


    What am I missing here? Probably my understanding of "not needed" is not correct?

    Regards

    susejunky

  6. #6
    Join Date
    Sep 2013
    Location
    Norfolk, UK
    Posts
    2,402

    Default Re: Cleanup of distribution upgrades

    As I said, it was just an initial guess, I really don't understand the inner workings of zypper...

    However, I also would expect "solver.onlyRequires = true" to take precedence.

    A second guess would be the (unneeded) packages are being pulled in by one of the installed "Patterns"

    If a genuine bug is suspected then it's probably best to raise a bug report against zypper.
    Regards, Paul

  7. #7
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    4,357
    Blog Entries
    5

    Default More cleanup

    Ran "zypper remove --clean-deps python38* python39*". "zypper se -is python|grep ^i+" found several packages I never want to use. Removed them and their dependencies too.
    openSUSE Tumbleweed, KDE Plasma, Blogs/KeepItSimple, i7-6700K (2016), i5-8250U (2018), AMD Ryzen 5 3400G (2020), 5600X, 5700U (2022)

  8. #8
    Join Date
    Sep 2014
    Location
    Germany
    Posts
    1,088

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by tannington View Post
    ... I really don't understand the inner workings of zypper ...
    Nor do I !

    Quote Originally Posted by tannington View Post
    A second guess would be the (unneeded) packages are being pulled in by one of the installed "Patterns"
    Ahhh !!! I had not thought of that one.

    Although I locked patterns after the installation there are still 8 patterns-* packages installed on my system.

    I will have to look into this.

    Thank you very much for that hint!

    Regards

    susejunky

  9. #9
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    4,357
    Blog Entries
    5

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by susejunky View Post
    What am I missing here? Probably my understanding of "not needed" is not correct?
    "unneeded" presumably means package is not needed by any user installed package and isn't a user installed package itself. Found several packages surprisingly flagged as "user installed" but which I don't need and removed them too.
    openSUSE Tumbleweed, KDE Plasma, Blogs/KeepItSimple, i7-6700K (2016), i5-8250U (2018), AMD Ryzen 5 3400G (2020), 5600X, 5700U (2022)

  10. #10
    Join Date
    Sep 2014
    Location
    Germany
    Posts
    1,088

    Default Re: Cleanup of distribution upgrades

    Quote Originally Posted by karlmistelberger View Post
    "unneeded" presumably means package is not needed by any user installed package and isn't a user installed package itself.
    As you say ... "presumably" !

    It would be nice to know the exact definition used by zypper.

    Regards

    susejunky

Page 1 of 3 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •