1

I have tried to get php 8.0 but it was a pain so I want it removed which I did. Now when I update I get this:

ubuntu@ubuntu:~$ sudo apt update
Hit:1 https://download.docker.com/linux/ubuntu focal InRelease
Ign:2 https://packages.sury.org/php focal InRelease                                                                                                           
Hit:3 http://ports.ubuntu.com/ubuntu-ports focal InRelease                                                                                                    
Err:4 https://packages.sury.org/php focal Release                                  
  404  Not Found [IP: 104.21.18.148 443]
Get:5 http://ports.ubuntu.com/ubuntu-ports focal-updates InRelease [114 kB]        
Hit:6 http://ppa.launchpad.net/ondrej/php/ubuntu focal InRelease                              
Get:7 http://ports.ubuntu.com/ubuntu-ports focal-backports InRelease [101 kB]
Get:8 http://ports.ubuntu.com/ubuntu-ports focal-security InRelease [114 kB]
Get:9 http://ports.ubuntu.com/ubuntu-ports focal-updates/restricted arm64 Packages [2992 B]
Get:10 http://ports.ubuntu.com/ubuntu-ports focal-updates/restricted Translation-en [57.0 kB]
Get:11 http://ports.ubuntu.com/ubuntu-ports focal-updates/multiverse arm64 Packages [7720 B]
Get:12 http://ports.ubuntu.com/ubuntu-ports focal-updates/multiverse Translation-en [6888 B]
Get:13 http://ports.ubuntu.com/ubuntu-ports focal-security/restricted arm64 Packages [2804 B]
Get:14 http://ports.ubuntu.com/ubuntu-ports focal-security/restricted Translation-en [47.8 kB]
Reading package lists... Done            
E: The repository 'https://packages.sury.org/php focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

I have tried to read forums on how to delete repos but I didn't know the name of the repo. I can install and purge just fine but updating is the main problem.

Human
  • 13
  • Welcome to Askubuntu. Please edit your question and copy and paste the code and do not post a screenshot. Posting a screenshot is a good way to have your question ignored. Paste the output into the question, highlight the code and then press CTRL+K to automatically format it as code. Thanks. – mchid Aug 17 '21 at 09:30
  • The readme.txt suggest the file is named /etc/apt/sources.list.d/php.list –  Aug 17 '21 at 10:31
  • 1
    @bac0n Thanks I found the package link thing in there like this deb https://packages.sury.org/php/ focal main which I believe is the repo link i'm looking for. Though would I remove php.list or just the repo? – Human Aug 17 '21 at 10:34
  • it works fine actually without the files I will write an answer and refer your comment thanks – Human Aug 17 '21 at 10:43
  • the dist is stretch buster or bullseye suggests it's suited for debian and not ubuntu. (yes you can delete it) –  Aug 17 '21 at 10:48
  • that makes a lot of sense thanks – Human Aug 18 '21 at 07:43

1 Answers1

4

Edit the file /etc/apt/sources.list, for example, with nano editor:

sudo nano /etc/apt/sources.list

Then comment the lines with the "sury" repo, adding a # at the beginning of the line.

Then come back to the terminal, and repeat the sudo apt-get update command.

Unix
  • 197