Results 1 to 4 of 4

Thread: Kali linux apt update broken?

  1. #1
    Join Date
    2023-Feb
    Posts
    1

    Kali linux apt update broken?

    └─$ sudo apt update
    Hit:1 http://kali.download/kali kali-rolling InRelease
    Traceback (most recent call last):
    File "/usr/lib/cnf-update-db", line 27, in <module>
    col.create(db)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 95, in create
    self._fill_commands(con)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 143, in _fill_commands
    self._parse_single_contents_file(con, f, fp.stdout)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 282, in _parse_single_contents_file
    priority = component_priorities[component]
    ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
    KeyError: 'non-free-firmware'
    Reading package lists... Done
    E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/lib/command-not-found/ -a -e /usr/lib/cnf-update-db; then /usr/lib/cnf-update-db > /dev/null; fi'
    E: Sub-process returned an error code




    From kali-tweaks
    └─$ kali-tweaks
    > Writing changes to /etc/apt/sources.list
    > New repository: deb http://kali.download/kali kali-experimental main contrib non-free
    > Installing to: '/etc/apt/sources.list.d/kali-experimental.list'
    >>> Updating APT cache
    > $ sudo apt-get update
    Get:1 http://kali.download/kali kali-rolling InRelease [30.6 kB]
    Get:2 http://kali.download/kali kali-experimental InRelease [23.0 kB]
    Get:3 http://kali.download/kali kali-rolling/non-free Sources [132 kB]
    Get:4 http://kali.download/kali kali-rolling/main Sources [15.7 MB]
    Get:5 http://kali.download/kali kali-rolling/contrib Sources [77.9 kB]
    Get:6 http://kali.download/kali kali-rolling/main amd64 Packages [19.5 MB]
    Get:7 http://kali.download/kali kali-rolling/main amd64 Contents (deb) [45.4 MB]
    Get:8 http://kali.download/kali kali-rolling/contrib amd64 Packages [116 kB]
    Get:9 http://kali.download/kali kali-rolling/contrib amd64 Contents (deb) [172 kB]
    Get:10 http://kali.download/kali kali-rolling/non-free amd64 Packages [222 kB]
    Get:11 http://kali.download/kali kali-rolling/non-free amd64 Contents (deb) [931 kB]
    Get:12 http://kali.download/kali kali-experimental/main amd64 Packages [59.2 kB]
    Traceback (most recent call last):
    File "/usr/lib/cnf-update-db", line 27, in <module>
    col.create(db)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 95, in create
    self._fill_commands(con)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 143, in _fill_commands
    self._parse_single_contents_file(con, f, fp.stdout)
    File "/usr/share/command-not-found/CommandNotFound/db/creator.py", line 282, in _parse_single_contents_file
    priority = component_priorities[component]
    ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
    KeyError: 'non-free-firmware'
    Fetched 82.4 MB in 11s (7,592 kB/s)
    Reading package lists...
    E: Problem executing scripts APT::Update::Post-Invoke-Success 'if /usr/bin/test -w /var/lib/command-not-found/ -a -e /usr/lib/cnf-update-db; then /usr/lib/cnf-update-db > /dev/null; fi'
    E: Sub-process returned an error code
    > Error, restoring original sources.list files

    ┏━(Something went wrong!)
    ┃ Couldn't update the APT cache
    ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

    > Press Enter to continue...





    I initially thought I broke my install somehow, so I did a fresh install, and I get this error. I've done nothing but install kali and try to update.

  2. #2
    Join Date
    2021-May
    Location
    UK
    Posts
    772
    echo "deb http://http.kali.org/kali kali-rolling main non-free contrib" | sudo tee /etc/apt/sources.list

    and try again..

  3. #3
    Join Date
    2021-May
    Location
    UK
    Posts
    772
    Insta key again maybe..

    wget -q -O ? https://archive.kali.org/archive-key.asc | apt-key add

  4. #4
    Join Date
    2023-Feb
    Posts
    1
    Im getting the same on my VM's and now my baremetal only thing I did was apt update && apt dist-upgrade -y

    Reading package lists... Done
    Building dependency tree... Done
    Reading state information... Done
    Calculating upgrade... Done
    The following packages will be upgraded:
    desktop-base
    1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    Need to get 0 B/7,568 kB of archives.
    After this operation, 4,116 kB of additional disk space will be used.
    (Reading database ... 659643 files and directories currently installed.)
    Preparing to unpack .../desktop-base_12.0.4+kali1_all.deb ...
    Unpacking desktop-base (12.0.4+kali1) over (12.0.2+kali1) ...
    dpkg: error processing archive /var/cache/apt/archives/desktop-base_12.0.4+kali1_all.deb (--unpack):
    trying to overwrite '/etc/skel/.face', which is also in package kali-themes 2023.1.5
    dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
    grub-efi* packages found, using 16/9 as default grub background ratio
    Generating grub configuration file ...
    Found theme: /boot/grub/themes/kali/theme.txt
    Found background image: /usr/share/images/desktop-base/desktop-grub.png
    Found linux image: /boot/vmlinuz-6.1.0-kali5-amd64
    Found initrd image: /boot/initrd.img-6.1.0-kali5-amd64
    Found linux image: /boot/vmlinuz-6.0.0-kali6-amd64
    Found initrd image: /boot/initrd.img-6.0.0-kali6-amd64
    Warning: os-prober will not be executed to detect other bootable partitions.
    Systems on them will not be added to the GRUB boot configuration.
    Check GRUB_DISABLE_OS_PROBER documentation entry.
    Adding boot menu entry for UEFI Firmware Settings ...
    done
    update-initramfs: deferring update (trigger activated)
    Errors were encountered while processing:
    /var/cache/apt/archives/desktop-base_12.0.4+kali1_all.deb
    needrestart is being skipped since dpkg has failed
    E: Sub-process /usr/bin/dpkg returned an error code (1)

    I've tried all the fixes as well.... someone help please lol

Similar Threads

  1. Unstable - Broken packages after apt update
    By innerdemon in forum Kali Linux TroubleShooting
    Replies: 0
    Last Post: 2023-06-30, 00:46
  2. iwlwifi broken after last update
    By grisutheguru in forum TroubleShooting Archive
    Replies: 0
    Last Post: 2020-04-22, 10:17
  3. Kali BROKEN after full update
    By Napert in forum TroubleShooting Archive
    Replies: 8
    Last Post: 2017-03-29, 10:05
  4. Update issue - broken package
    By natv in forum TroubleShooting Archive
    Replies: 3
    Last Post: 2016-09-23, 17:35
  5. w3af broken after update on Kali 1.0.7
    By mbeaven in forum General Archive
    Replies: 3
    Last Post: 2014-08-17, 12:33

Posting Permissions

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