Page 1 of 2 12 LastLast
Results 1 to 10 of 18

Thread: online update errors when trying to remove non-existent packages; zypper update dumps core

  1. #1

    Default online update errors when trying to remove non-existent packages; zypper update dumps core

    OpenSUSE 15.1 laptop. On a machine I maintain for someone else (thus not one I normally use), we noticed that online updates were not taking place. When I updated manually via yast2, I ran into errors attempting to install patches - the patch installs failed because they tried to remove package versions that were not on the machine. I tried to find out more information about what might be going on via zypper, and got the following error on zypper commands that involved patches:

    Code:
    # zypper list-updatesLoading repository data...
    Reading installed packages...
    /usr/include/c++/7/bits/stl_vector.h:797: std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::reference = std::__cxx11::basic_string<char>&; std::vector<_Tp, _Alloc>::size_type = long unsigned int]: Assertion '__builtin_expect(__n < this->size(), true)' failed.
    Aborted (core dumped)
    zypper commands that do not involve updates seem to be fine.

    Any suggestions on straightening this out would be welcomed.

  2. #2
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    26,511

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Hello and welcome.

    What do you mean with "online updates not taking place"? Apparently not what you call "manualy via yast2", but it is not clear which "non-manualy" way of online update you do.

    In any case, you could try if
    Code:
    zypper clean -a
    zypper ref
    helps

    Also, you could post
    Code:
    zypper lr -d
    to enable people to check if your repo list shows problems.
    Henk van Velden

  3. #3

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    What do you mean with "online updates not taking place"?
    I had thought that the Plasma "Discover" applet/widget/whatever was running periodic updates on the system; but when I manually ran the yast2 online update, I found there had been no updates for about 2 months, and I got about 390 patches at that time. Of those 390, about 20 failed because their actions included removing rpm packages from the machine that were not present.

    I ran the commands you requested:

    Code:
    # zypper clean -a
    All repositories have been cleaned up.
    
    
    # zypper ref
    Retrieving repository 'brave-browser' metadata ---------------------------------------------------------------------------------------------------------------------------------[\]
    File 'repomd.xml' from repository 'brave-browser' is signed with an unknown key 'A8580BDC82D3DC6C'. Continue? [yes/no] (no): y
    Retrieving repository 'brave-browser' metadata ..............................................................................................................................[done]
    Building repository 'brave-browser' cache ...................................................................................................................................[done]
    Repository 'openSUSE-Leap-15.1-1' is up to date.                                                                                                                                   
    Building repository 'openSUSE-Leap-15.1-1' cache ............................................................................................................................[done]
    Retrieving repository 'Non-OSS Repository' metadata .........................................................................................................................[done]
    Building repository 'Non-OSS Repository' cache ..............................................................................................................................[done]
    Retrieving repository 'Main Repository' metadata ............................................................................................................................[done]
    Building repository 'Main Repository' cache .................................................................................................................................[done]
    Retrieving repository 'Main Update Repository' metadata .....................................................................................................................[done]
    Building repository 'Main Update Repository' cache ..........................................................................................................................[done]
    Retrieving repository 'Update Repository (Non-Oss)' metadata ................................................................................................................[done]
    Building repository 'Update Repository (Non-Oss)' cache .....................................................................................................................[done]
    All repositories have been refreshed.
    
    
    # zypper lr -d
    #  | Alias                     | Name                               | Enabled | GPG Check | Refresh | Priority | Type   | URI                                                                      | Service
    ---+---------------------------+------------------------------------+---------+-----------+---------+----------+--------+--------------------------------------------------------------------------+--------
     1 | brave-browser             | brave-browser                      | Yes     | ( p) Yes  | No      |   99     | rpm-md | https://brave-browser-rpm-release.s3.brave.com/x86_64/                   |  
     2 | openSUSE-Leap-15.1-1      | openSUSE-Leap-15.1-1               | Yes     | (r ) Yes  | No      |   99     | rpm-md | cd:/?devices=/dev/disk/by-id/ata-HL-DT-ST_DVDRAM_GU70N_M2OD6I43555       |  
     3 | repo-debug                | Debug Repository                   | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/debug/distribution/leap/15.1/repo/oss/      |  
     4 | repo-debug-non-oss        | Debug Repository (Non-OSS)         | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/debug/distribution/leap/15.1/repo/non-oss/  |  
     5 | repo-debug-update         | Update Repository (Debug)          | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/debug/update/leap/15.1/oss/                 |  
     6 | repo-debug-update-non-oss | Update Repository (Debug, Non-OSS) | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/debug/update/leap/15.1/non-oss/             |  
     7 | repo-non-oss              | Non-OSS Repository                 | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://download.opensuse.org/distribution/leap/15.1/repo/non-oss/        |  
     8 | repo-oss                  | Main Repository                    | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://download.opensuse.org/distribution/leap/15.1/repo/oss/            |  
     9 | repo-source               | Source Repository                  | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/source/distribution/leap/15.1/repo/oss/     |  
    10 | repo-source-non-oss       | Source Repository (Non-OSS)        | No      | ----      | ----    |   99     | NONE   | http://download.opensuse.org/source/distribution/leap/15.1/repo/non-oss/ |  
    11 | repo-update               | Main Update Repository             | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://download.opensuse.org/update/leap/15.1/oss/                       |  
    12 | repo-update-non-oss       | Update Repository (Non-Oss)        | Yes     | (r ) Yes  | Yes     |   99     | rpm-md | http://download.opensuse.org/update/leap/15.1/non-oss/ 
    Apologies for the formatting. I noted the Brave browser key error, which I've seen prior to this problem and which I don't think is related.

    I also backed up and rebuilt the rpm database (rpm --rebuilddb). That seems to have fixed one problem; yast is no longer trying to uninstall rpm's that don't exist on the machine. However, yast online update fails without any error message when trying to install any patches in yast's 'recommended' list (which I suspect may be related to the core dump in zypper).

    Thanks for the response.


  4. #4
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    26,511

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Your repo list seems to be OK.

    So you mean the update applet from the KDE desktop. I am not sure it does updates unattended. Maybe it can be configured as such. I would never let an update happen without explicitly starting it myself (on a moment I decide is the best moment to do so). I never used the applet (it is not installed on my systems), so I can not be of much help with it.

    I see you did already a rpm --rebuilddb, that would have been my next suggestion .

    Now, I am a bit usure on what yast online update does exactly. Can you try from the YaST GUI?
    I know that the i last update (but that is one that would be involved in your case) there was a patch for zypper/zypplib. That one will then run on it's own (it will be the only one that is checked in the list). After that, YaST will reload itself to do the rest.
    This is of course because one does not want to patch a tool during it being used.
    Henk van Velden

  5. #5

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Out of curiosity, what tool(s) do you use to keep your system(s) up to date? I had assumed that the yast online update was pretty much the standard.

    Anyway, rebuilding the rpmdb and running the ncurses version of 'yast online update' allowed me to install the pending patches.

    Now my one remaining problem is with zypper dumping core. I suspect this may be the root of how the system updates got messed up in the first place; at least some zypper commands that involve updating (like 'zypper lu', or 'zypper pch') ends in this core dump:

    Code:
    # zypper pch
    Loading repository data...
    Reading installed packages...
    /usr/include/c++/7/bits/stl_vector.h:797: std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc =
     std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::reference = std::__cxx11::basic_string<char>&; std::vector<_Tp, _Alloc>::size_type = long unsigned int]: Assertion '__builtin_ex
    pect(__n < this->size(), true)' failed.
    Aborted (core dumped)
    
    I tried force-reinstalling zypper, libzypp, and the libsolv-tools rpm's via yast, but no change in behavior.

  6. #6
    Join Date
    Sep 2012
    Posts
    5,646

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Quote Originally Posted by dcfleck33 View Post
    I tried force-reinstalling zypper, libzypp, and the libsolv-tools rpm's via yast, but no change in behavior.
    It could be one of libraries used by zypper or something in your environment triggers it. In any case, as you can consistently reproduce it and get core dump, open bug report.

  7. #7
    Join Date
    Jan 2014
    Location
    Erlangen
    Posts
    1,628

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Quote Originally Posted by dcfleck33 View Post
    OpenSUSE 15.1 laptop. On a machine I maintain for someone else (thus not one I normally use), we noticed that online updates were not taking place. When I updated manually via yast2, I ran into errors attempting to install patches - the patch installs failed because they tried to remove package versions that were not on the machine. I tried to find out more information about what might be going on via zypper, and got the following error on zypper commands that involved patches:

    Code:
    # zypper list-updates
    Loading repository data...
    Reading installed packages...
    /usr/include/c++/7/bits/stl_vector.h:797: std::vector<_Tp, _Alloc>::reference std::vector<_Tp, _Alloc>::operator[](std::vector<_Tp, _Alloc>::size_type) [with _Tp = std::__cxx11::basic_string<char>; _Alloc = std::allocator<std::__cxx11::basic_string<char> >; std::vector<_Tp, _Alloc>::reference = std::__cxx11::basic_string<char>&; std::vector<_Tp, _Alloc>::size_type = long unsigned int]: Assertion '__builtin_expect(__n < this->size(), true)' failed.
    Aborted (core dumped)
    zypper commands that do not involve updates seem to be fine.

    Any suggestions on straightening this out would be welcomed.
    GUI is nice when working properly. When encountering issues you better rely on the command line. What about "zypper update"? "zypper verify"? Post the command and the outcome uncensored:
    Code:
    erlangen:~ # zypper verify
    Loading repository data...
    Reading installed packages...
    
    Dependencies of all installed packages are satisfied.
    erlangen:~ #
    AMD Athlon 4850e (2009), openSUSE 13.1, KDE 4, Intel i3-4130 (2014), i7-6700K (2016), i5-8250U (2018), AMD Ryzen 5 3400G (2020), openSUSE Tumbleweed, KDE Plasma 5

  8. #8
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    26,511

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Quote Originally Posted by dcfleck33 View Post
    Out of curiosity, what tool(s) do you use to keep your system(s) up to date? I had assumed that the yast online update was pretty much the standard.
    Normaly once a week it is maintenance time.
    I start YaST > Software Management > Online update (either from the GUI, or when working remote on a system in the CLI the ncurses interfcae, or even you). I check if there are any important updates that require a reboot (kernel). I may then postpone, depending on who is still doing what on a system). I also may read some of explanatory the texts coming with the patches. Normaly I then Continue with the update.

    As I have only Packman as extra repo, I then start YaST > Software > Software Management, use the Repositories View and select Packman. at right, in the list of packages, I rightclick- and then click Update if a newer Veriosn is available (that is equivalent to a zypper up --from Packman).

    The whole above is equivalent with
    Code:
    zypper up
    but more in step by step to have a bit more control over it. I understand that when you have many systems, you maybe want to restrict the step by step to one system and when not encountering problems, do all the others in a one step approach.

    Main ideas behind this are:

    • there is a clear boundary between different roles of human on a system: end-user and system manager (even if in the end they are the same person, which is of course true for me personaly);
    • most patches are not so urgent that they must be applied with the hour after being published (but keep an eye on the forum News & Aouncments section);
    • end-users have no task in manageing the system and thus should not be bothered with applets that try to lure them into doing updates (thus the applet and PackageKit are not installed on my systems);
    • as system manager one should claim regularly maintenance time for doing update, maybe system backups and other things that require users to be loged out. Even if you do not use those this very often, they will be much less annoyed when you claim down time. Many will even appreciate that somebody realy cares for their system.


    This is of course my very personal approach and you may think different, but you asked for it
    Henk van Velden

  9. #9

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Code:
    > zypper ve
    Loading repository data...
    Reading installed packages...
    
    Dependencies of all installed packages are satisfied.
    
    Code:
    > zypper patch
    Loading repository data...
    Reading installed packages...
    Resolving package dependencies...
    
    The following NEW package is going to be installed:
      systemd-network
    
    The following 4 NEW patches are going to be installed:
      openSUSE-2020-900 openSUSE-2020-901 openSUSE-2020-903 openSUSE-2020-904
    
    The following 16 packages are going to be upgraded:
      krb5 krb5-32bit libsystemd0 libsystemd0-32bit libudev1 libudev1-32bit libudev-devel mutt mutt-doc mutt-lang perl-TimeDate systemd systemd-32bit systemd-bash-completion s
    ystemd-sysvinit udev
    
    The following 2 packages require a system reboot:
      systemd udev
    
    16 packages to upgrade, 1 new.
    Overall download size: 8.9 MiB. Already cached: 0 B. After the operation, additional 6.5 KiB will be used.
    
        Note: System reboot required.
    Continue? [y/n/v/...? shows all options] (y)
    (Patching continues successfully)
    
    In addition, I ran all the zypper subcommands that didn't make require additional input or make changes to the installed packages. All but three ran successfully:

    Code:
    > 
    > zypper ?      
    > zypper lr      
    > zypper ref 
    > zypper cc 
    > zypper ls 
    > zypper refs 
    > zypper ve 
    > zypper lu       dumps core
    > zypper patch 
    > zypper lp       dumps core
    > zypper pchk 
    > zypper pch      dumps core
    > zypper pa 
    > zypper pt 
    > zypper pd 
    > zypper ll 
    > zypper cl 
    > zypper licenses 
    > zypper needs-rebooting 
    > zypper ps

  10. #10
    Join Date
    Jun 2008
    Location
    Netherlands
    Posts
    26,511

    Default Re: online update errors when trying to remove non-existent packages; zypper update dumps core

    Will not help you much, but those three that dump core at your system, run without problems here.
    Henk van Velden

Page 1 of 2 12 LastLast

Tags for this Thread

Posting Permissions

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