apt problems - dpkg and apt-listbugs

Kernels & Hardware, configuring network, installing services

apt problems - dpkg and apt-listbugs

Postby milomak » 2020-11-22 13:52

in sid, when running apt/apt-get/aptitude trying to remove a package, i am met with the following error message
Code: Select all
dpkg: unrecoverable fatal error, aborting:
 files list file for package 'libedit2:amd64' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)


and then when trying to run apt-listbugs,
Code: Select all
# apt-listbugs
Traceback (most recent call last):
        19: from /usr/sbin/apt-listbugs:419:in `<main>'
        18: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        17: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        16: from /usr/lib/ruby/vendor_ruby/gettext.rb:19:in `<top (required)>'
        15: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        14: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        13: from /usr/lib/ruby/vendor_ruby/gettext/text_domain_manager.rb:14:in `<top (required)>'
        12: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        11: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
        10: from /usr/lib/ruby/vendor_ruby/gettext/text_domain.rb:16:in `<top (required)>'
         9: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
         8: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
         7: from /usr/lib/ruby/vendor_ruby/gettext/mo.rb:22:in `<top (required)>'
         6: from /usr/lib/ruby/vendor_ruby/gettext/mo.rb:23:in `<module:GetText>'
         5: from /usr/lib/ruby/vendor_ruby/gettext/mo.rb:172:in `<class:MO>'
         4: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
         3: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
         2: from /usr/lib/ruby/2.7.0/prime.rb:15:in `<top (required)>'
         1: from /usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require'
/usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require': /usr/lib/ruby/2.7.0/singleton.rb:1: invalid multibyte char (UTF-8) (SyntaxError)
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10
Laptop: Lenovo ideapad Y700-15ISK [nVidia Optimus] (64-bit) - Sid, Win10, Solus
Kodi Box: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid
milomak
 
Posts: 2073
Joined: 2009-06-09 22:20

Re: apt problems - dpkg and apt-listbugs

Postby Head_on_a_Stick » 2020-11-22 14:55

milomak wrote:in sid, when running apt/apt-get/aptitude trying to remove a package, i am met with the following error message
Code: Select all
dpkg: unrecoverable fatal error, aborting:
 files list file for package 'libedit2:amd64' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)

Try
Code: Select all
# rm /var/lib/dpkg/info/libedit2\:amd64.list
# apt reinstall libedit2

Reference: https://askubuntu.com/questions/909719/ ... e-linux-ge

milomak wrote:
Code: Select all
/usr/lib/ruby/vendor_ruby/rubygems/core_ext/kernel_require.rb:83:in `require': /usr/lib/ruby/2.7.0/singleton.rb:1: invalid multibyte char (UTF-8) (SyntaxError)

Is the rubygems-integration package installed?

This might just be a sid SNAFU though so perhaps wait a bit and then upgrade your system and try again.
Black Lives Matter

Debian buster-backports ISO image: for new hardware support
User avatar
Head_on_a_Stick
 
Posts: 12770
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: apt problems - dpkg and apt-listbugs

Postby milomak » 2020-11-22 15:55

the problem is that i cannot install/reinstall as apt-listbugs runs which returns the ruby error
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10
Laptop: Lenovo ideapad Y700-15ISK [nVidia Optimus] (64-bit) - Sid, Win10, Solus
Kodi Box: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid
milomak
 
Posts: 2073
Joined: 2009-06-09 22:20

Re: apt problems - dpkg and apt-listbugs

Postby milomak » 2020-11-22 16:32

i commented out all the lines in /etc/apt/apt.conf.d/10apt-listbugs

it seems there are a whole lot libs that are messed up. i'll work through them piece by piece
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10
Laptop: Lenovo ideapad Y700-15ISK [nVidia Optimus] (64-bit) - Sid, Win10, Solus
Kodi Box: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid
milomak
 
Posts: 2073
Joined: 2009-06-09 22:20

Re: apt problems - dpkg and apt-listbugs

Postby milomak » 2020-11-22 17:21

there are a lot of packages missing final newline

a temporary fix is to move files out of /var/lib/dpkg/info/ into another folder

run the apt commands i want

is there a way to find out which of the files in the folder have this newline issue? what happens if i don't move them back into the info folder?
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10
Laptop: Lenovo ideapad Y700-15ISK [nVidia Optimus] (64-bit) - Sid, Win10, Solus
Kodi Box: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid
milomak
 
Posts: 2073
Joined: 2009-06-09 22:20

Re: apt problems - dpkg and apt-listbugs

Postby Head_on_a_Stick » 2020-11-23 18:29

milomak wrote:is there a way to find out which of the files in the folder have this newline issue?

Try
Code: Select all
# dpkg --verify

Sounds like the filesystem may be corrupted. Have you tried a SMART check on the drive?
Black Lives Matter

Debian buster-backports ISO image: for new hardware support
User avatar
Head_on_a_Stick
 
Posts: 12770
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: apt problems - dpkg and apt-listbugs

Postby milomak » 2020-11-25 16:38

yeah this system is borked

will be a reinstall next

just need to think what conf files i'll what to keep
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10
Laptop: Lenovo ideapad Y700-15ISK [nVidia Optimus] (64-bit) - Sid, Win10, Solus
Kodi Box: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid
milomak
 
Posts: 2073
Joined: 2009-06-09 22:20


Return to System configuration

Who is online

Users browsing this forum: No registered users and 18 guests

fashionable