Problem updating Grafana in a Debian 9

Updating a Debian 9 I get this error with the “grafana” update:

$ apt update
Ign:7  stretch InRelease
Err:9  stretch Release
404 Not Found
Reading package lists... Done
E: The repository ' 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.

To solve this problem you can follow the next steps.

First, install the “software-properties-common” library:

$ sudo apt-get install -y software-properties-common

Install the repository for stable releases:

$ sudo add-apt-repository "deb  stable main"

Add the gpg key:

$ sudo wget -q -O - | apt-key add -

Remove the old repository file:

$ sudo rm /etc/apt/sources.list.d/grafana_stable.list

Now you can update the repo correctly:

$ sudo apt update

Leave a comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.