Kali-Pi icon indicating copy to clipboard operation
Kali-Pi copied to clipboard

Can't 'apt-get upgrade' the system brokes.

Open Skeleton022 opened this issue 5 years ago • 8 comments

I flashed StickyFingers-Kali-Pi-armhf-190703.img to my sd card. It boots everything goes well until I try to upgrade the system. When I type apt-get upgrade -y everything brokes, and nothing helps. (#Section1:)

I have already tried apt --fix-broken install, but his happens (#Section2:) I tried "sudo dpkg --configure -a" as well, it didn't help.

I already expanded the partition using gparted, so it will fit :)

If I try to install anything like:"apt-get install python3 python3-pip -y" I get this: (#Section3:) It depends on pure-ftpd what is causes the problem.

I have reflashed the whole sd card and did it again, the results are the same :(

Please send help. EDIT: I don't know if it matters but it is running on a raspberry pi 4 with 4gb ram. error.txt

Skeleton022 avatar Nov 18 '19 21:11 Skeleton022

I run into this 7/10 times installing. You have 2 options that I know of...

Option #1 Use “sudo apt-mark hold pure-ftpd” to bypass it for now and be able to continue on.

Option #2 Physically go to that directory and manually unpack the .deb that’s causing the issue. This fixes the issue for me.

Pr0l1f1c avatar Jan 02 '20 07:01 Pr0l1f1c

I have the same problem with a raspberry pi 4 with 4gb ram.

zabpavel avatar Feb 17 '20 18:02 zabpavel

My English is not very good, so sorry for the mistakes. Maybe I found a solution to the problem. This sequence of commands fixed everything for me: sudo apt-mark hold pure-ftpd sudo apt-mark hold pure-ftpd-common sudo dpkg --configure -a sudo apt-get install -f pure-ftpd sudo apt-get install -f pure-ftpd-common sudo apt-mark unhold pure-ftpd sudo apt-mark unhold pure-ftpd-common sudo dpkg --configure -a apt-get upgrade

Do not scold for this approach. I'm new to this business

zabpavel avatar Feb 17 '20 20:02 zabpavel

This solved it for me:

rm -rf /usr/share/doc/pure-ftpd-common/ /usr/share/doc/pure-ftpd/
apt install pure-ftpd pure-ftpd-common
dpkg -i --force-overwrite /var/cache/apt/archives/pure-ftpd-common_1.0.49-1_all.deb

magoo-magoo avatar Apr 06 '20 20:04 magoo-magoo

May 2020 . This has been driving me nuts ,I have tried a number of methods. I am afraid Zabpavel fix did not work ,I tried it twice . I hope to try magoo-Magoo method tomorrow.

I am using the pi 3b+

I also had to disable screen and power savers Remove lightdm and replace with slim There was another instruction that did not work ,to enable auto log on but This has now been taken care of with Kali pi config

This pure-ftpd problem is very annoying as it stopped me being able to install even minor things that use apt-get .

It’s a strange problem as it says the file or directory it is looking for does not exist. Anyway I look forward to trying magoos suggestion tomorrow

Anyone else been struggling with this? Best regards

sn4akedoctor avatar May 27 '20 01:05 sn4akedoctor

Well Magoo magoo’s solution has solved my problem so far . It installed pure-ftpd properly and I can now apt-get install. Thank you so much

sn4akedoctor avatar May 27 '20 17:05 sn4akedoctor

Were you getting the THE FOLLOWING SIGNATURES WERE INVALID error when using apt get?

Here was my solution:

I had to expand the filesystem AND set the timezone - I installed raspi-config for it

Install raspi-config git clone https://github.com/EmilGus/install_raspi-config sh install.sh

do raspi-config and change the time zone https://www.mbtechworks.com/how-to/change-time-zone-raspbian.html

Use Raspi-config to expand the filesystem

also do

sudo apt install ntp service ntp restart #check using date

For the signatures were invalid issue:

#to fix THE FOLLOWING SIGNATURES WERE INVALID - KALI wget -q -O - https://archive.kali.org/archive-key.asc | apt-key add #for res4on kernel sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 11764EE8AC24832F #or wget -O - https://re4son-kernel.com/keys/http/archive-key.asc | sudo apt-key add -

marko-kovacevic avatar Apr 16 '21 14:04 marko-kovacevic

This solved it for me:

rm -rf /usr/share/doc/pure-ftpd-common/ /usr/share/doc/pure-ftpd/
apt install pure-ftpd pure-ftpd-common
dpkg -i --force-overwrite /var/cache/apt/archives/pure-ftpd-common_1.0.49-1_all.deb

it is work for my Mint upgrade 19.3 -> 20.0 Thank you very much!

olegMarin avatar Jun 04 '24 23:06 olegMarin