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 'https://packagecloud.io/grafana/stable/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.
...

Failed to fetch http://ftp.debian.org/debian/dists/jessie-updates/main/ 404 Not Found

Executing apt update in a Debian 8 I get the error

W: Failed to fetch http://ftp.debian.org/debian/dists/wheezy-backports/main/binary-amd64/Packages 404 Not Found [IP: 2001:67c:2564:a119::148:12 80]
W: Failed to fetch http://ftp.debian.org/debian/dists/jessie-updates/main/source/Sources 404 Not Found [IP: 2001:41d0:202:100:213:32:5:7 80]
W: Failed to fetch http://ftp.debian.org/debian/dists/jessie-updates/main/binary-amd64/Packages 404 Not Found [IP: 2001:41d0:202:100:213:32:5:7 80]
W: Failed to fetch http://ftp.debian.org/debian/dists/jessie-backports/main/source/Sources 404 Not Found [IP: 2001:41d0:202:100:213:32:5:7 80]
W: Failed to fetch http://ftp.debian.org/debian/dists/jessie-backports/main/binary-amd64/Packages 404 Not Found [IP: 2001:41d0:202:100:213:32:5:7 80]
E: Some index files failed to download. They have been ignored, or old ones used instead.