0

I keep getting an error when I use apt or apt-get as a root user or using sudo with the default pi account.

Ign:1 http://raspbian.raspberrypi.org/raspbian stretch InRelease

Ign:2 http://archive.raspberrypi.org/debian stretch InRelease

Err:3 http://raspbian.raspberrypi.org/raspbian stretch Release
  System error resolving 'raspbian.raspberrypi.org:80' - getaddrinfo (13: Permission denied)

Err:4 http://archive.raspberrypi.org/debian stretch Release
  System error resolving 'archive.raspberrypi.org:80' - getaddrinfo (13: Permission denied)

Reading package lists... Done

E: The repository 'http://raspbian.raspberrypi.org/raspbian stretch Release' does no longer 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.

E: The repository 'http://archive.raspberrypi.org/debian stretch Release' does no longer 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.  

Any help is greatly appreciated!

1 Answer 1

3

I don't know what repositories do you have addressed in your /etc/apt/sources.list. But it seems you have a Raspbian and a Debian repository addressed. This is not a good idea except do you really know what you are doing (sorry, but it seems not to be the case ;-).

The Permission denied is to the remote web sites raspbian.raspberrypi.org:80 and archive.raspberrypi.org:80. This has nothing to do with the local superuser root. It shows in conjunction with the other messages that there is no more a valid repository accessable.

The default entries for the repositories on Raspbian Stretch are:

rpi ~$ cat /etc/apt/sources.list
deb http://raspbian.raspberrypi.org/raspbian/ stretch main contrib non-free rpi
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://raspbian.raspberrypi.org/raspbian/ stretch main contrib non-free rpi

rpi ~$ cat /etc/apt/sources.list.d/raspi.list
deb http://archive.raspberrypi.org/debian/ stretch main ui
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://archive.raspberrypi.org/debian/ stretch main ui

I suggest to use these entries.

3
  • Currently I have: "deb raspbian.raspberrypi.org/raspbian stretch main contrib non-free rpi # Uncomment line below then 'apt-get update' to enable 'apt-get source' #deb-src raspbian.raspberrypi.org/raspbian stretch main contrib non-free rpi" in my sources.list. Is there another file I should look for?
    – Craig
    Commented May 18, 2019 at 13:04
  • @Craig Yes, there is another file to look for as shown in my answer. Check /etc/apt/sources.list.d/raspi.list.
    – Ingo
    Commented May 18, 2019 at 15:28
  • > (sorry, but it seems not to be the case ;-). ya...god forbid someone play around with their pi to learn more
    – Anthony O
    Commented Mar 27, 2022 at 18:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.