Totally broken APT repo signatures (apt update won't work)

Help for Current Versions of MX
When asking for help, use Quick System Info from MX Tools. It will be properly formatted using the following steps.
1. Click on Quick System Info in MX Tools
2. Right click in your post and paste.
Message
Author
User avatar
SilverX
Posts: 35
Joined: Tue Oct 17, 2023 3:24 am

Re: Totally broken APT repo signatures (apt update won't work)

#11 Post by SilverX »

Any chance reinstalling apt-key might help?
Szmelc.INC Limited

User avatar
fehlix
Developer
Posts: 12842
Joined: Wed Apr 11, 2018 5:09 pm

Re: Totally broken APT repo signatures (apt update won't work)

#12 Post by fehlix »

SilverX wrote: Tue Sep 17, 2024 7:40 pm Any chance reinstalling apt-key might help?
I guess that's not a apt-key issue.
Probably simply to many changes at once, or to much removed
Maybe mini checks:

Code: Select all

ls -al /etc/apt/trusted.gpg  /etc/apt/trusted.gpg.d/*
and

Code: Select all

mount | grep /tmp 

User avatar
SilverX
Posts: 35
Joined: Tue Oct 17, 2023 3:24 am

Re: Totally broken APT repo signatures (apt update won't work)

#13 Post by SilverX »

Code: Select all

❯ ls -al /etc/apt/trusted.gpg  /etc/apt/trusted.gpg.d/*

zsh: no matches found: /etc/apt/trusted.gpg.d/*

And no output for mount | grep /tmp
Szmelc.INC Limited

User avatar
fehlix
Developer
Posts: 12842
Joined: Wed Apr 11, 2018 5:09 pm

Re: Totally broken APT repo signatures (apt update won't work)

#14 Post by fehlix »

SilverX wrote: Tue Sep 17, 2024 8:29 pm

Code: Select all

❯ ls -al /etc/apt/trusted.gpg  /etc/apt/trusted.gpg.d/*
zsh: no matches found: /etc/apt/trusted.gpg.d/*
No idea, why you have removed those files uner /etc/apt/trusted.gpg.d/*. Perhaps, check your snapshot or the host the snapshot is build from, in case some other file have also been removed. I'd realy rty to fix the snapshot, or the reason,
to avoid other sideffects.

User avatar
SilverX
Posts: 35
Joined: Tue Oct 17, 2023 3:24 am

Re: Totally broken APT repo signatures (apt update won't work)

#15 Post by SilverX »

I transplanted /etc/apt/trusted.gpg.d/ folder from source distribution
This is output now:

Code: Select all

❯ ls -al /etc/apt/trusted.gpg  /etc/apt/trusted.gpg.d/*

ls: cannot access '/etc/apt/trusted.gpg': No such file or directory
-rw-r--r-- 1 root root 11861 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-automatic.asc
-rw-r--r-- 1 root root 11873 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-security-automatic.asc
-rw-r--r-- 1 root root   461 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-stable.asc
-rw-r--r-- 1 root root 11861 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-automatic.asc
-rw-r--r-- 1 root root 11873 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-security-automatic.asc
-rw-r--r-- 1 root root  3403 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-stable.asc
-rw-r--r-- 1 root root 11093 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-automatic.asc
-rw-r--r-- 1 root root 11105 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-security-automatic.asc
-rw-r--r-- 1 root root  1704 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-stable.asc
-rw-r--r-- 1 root root  1211 Jan 21  2024 /etc/apt/trusted.gpg.d/mx23-archive-keyring.gpg
updating apt still won't work
Szmelc.INC Limited

User avatar
fehlix
Developer
Posts: 12842
Joined: Wed Apr 11, 2018 5:09 pm

Re: Totally broken APT repo signatures (apt update won't work)

#16 Post by fehlix »

SilverX wrote: Tue Sep 17, 2024 8:46 pm I transplanted /etc/apt/trusted.gpg.d/ folder from source distribution
This is output now:

Code: Select all

❯ ls -al /etc/apt/trusted.gpg  /etc/apt/trusted.gpg.d/*

ls: cannot access '/etc/apt/trusted.gpg': No such file or directory
-rw-r--r-- 1 root root 11861 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-automatic.asc
-rw-r--r-- 1 root root 11873 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-security-automatic.asc
-rw-r--r-- 1 root root   461 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bookworm-stable.asc
-rw-r--r-- 1 root root 11861 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-automatic.asc
-rw-r--r-- 1 root root 11873 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-security-automatic.asc
-rw-r--r-- 1 root root  3403 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-bullseye-stable.asc
-rw-r--r-- 1 root root 11093 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-automatic.asc
-rw-r--r-- 1 root root 11105 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-security-automatic.asc
-rw-r--r-- 1 root root  1704 Jul 30  2023 /etc/apt/trusted.gpg.d/debian-archive-buster-stable.asc
-rw-r--r-- 1 root root  1211 Jan 21  2024 /etc/apt/trusted.gpg.d/mx23-archive-keyring.gpg
updating apt still won't work
Maybe start again, and with every step you tweak, observe whether the system is still healthy or was just broken.
B/c just copy back some files will not explain to find the cause of the issue, and to help get it properly fixed.

User avatar
SilverX
Posts: 35
Joined: Tue Oct 17, 2023 3:24 am

Re: Totally broken APT repo signatures (apt update won't work)

#17 Post by SilverX »

The thing is im not sure what caused the issue to begin with, probably adding some broken repos, and now its stuck this way.
I literally transplanted healthy files from source os, and it still won't get over this issue.

Trying to repeat the action that broke it to analyze is pretty much impossible at this point.
All I can do now, is to keep transplanting file by file from known working source os and hope it works at some point.

Was there maybe some files i missed? Or is there any other way to re-do entire APT in a way that would fix itself?

I really appreciate your time and willingness to help. (sorry for wasting your time with this, but im already pretty helpless here)
Szmelc.INC Limited

User avatar
fehlix
Developer
Posts: 12842
Joined: Wed Apr 11, 2018 5:09 pm

Re: Totally broken APT repo signatures (apt update won't work)

#18 Post by fehlix »

SilverX wrote: Wed Sep 18, 2024 6:58 am The thing is im not sure what caused the issue to begin with, probably adding some broken repos, and now its stuck this way.
I literally transplanted healthy files from source os, and it still won't get over this issue.

Trying to repeat the action that broke it to analyze is pretty much impossible at this point.
All I can do now, is to keep transplanting file by file from known working source os and hope it works at some point.

Was there maybe some files i missed? Or is there any other way to re-do entire APT in a way that would fix itself?

I really appreciate your time and willingness to help. (sorry for wasting your time with this, but im already pretty helpless here)
apt and anything around it is one of the most important, essential system level packages on debian systems. Trying now with manual fixes by copying fixing files to revert into a healthy state is maybe possible, but would not be guarantee, the system get broken by the same causing issue one day. So I personally would not try fix, but to start and reinstall, maybe backup all you adjustment and data, so you can redo your tweaking, stepwise with always checking, whether the step just done, has just created a broken system.

User avatar
SilverX
Posts: 35
Joined: Tue Oct 17, 2023 3:24 am

Re: Totally broken APT repo signatures (apt update won't work)

#19 Post by SilverX »

To be fair.
I suspect both trying to add Ubuntu's PPA's, and trying to add Debian testing...
Im using both apt-get and nala (instead of apt).

Once when i tried to install some newer version of package that was supposedly available in debian testing, I came across this very weird behavior from nala.
It tried to remove over 90 different important packages while trying to just install some package.

After that, naturally I removed the debian testing and ubuntu's ppa's, but as you see, to no avail.
So yeah, this im pretty positive 99% it is due to user error, but I can't understand why trying to clear cache & transplant files won't work...
Szmelc.INC Limited

User avatar
fehlix
Developer
Posts: 12842
Joined: Wed Apr 11, 2018 5:09 pm

Re: Totally broken APT repo signatures (apt update won't work)

#20 Post by fehlix »

SilverX wrote: Wed Sep 18, 2024 8:19 am I suspect both trying to add Ubuntu's PPA's, and trying to add Debian testing...
Yes, you can quickly create a FrankenDebian, with this type of attitutde.
So, quick and simple advice would be: Start again, and avoid adding any PPA's
or non Debian bookworm repos. In case something missing, formulate a package request,
or seek advice in the forum.
Good luck.

Post Reply

Return to “MX Help”