Recently, I faced this error when i update the all application in my Raspberry Pi using:
sudo apt-get upgrade
and the error was:
W: http://deb.debian.org/debian/dists/bullseye-updates/InRelease: The key(s) in the keyring /etc/apt/trusted.gpg.d/influxdb.gpg are ignored as the file has an unsupported filetype.
W: GPG error: https://repos.influxdata.com/debian bullseye InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY D8FF8E1F7DF8B07E
To resolve the issue, I tried the following steps:
- Import the InfluxDB repository public key:
wget -qO- https://repos.influxdata.com/influxdb.key | sudo apt-key add -
- Add the InfluxDB repository to the list of trusted repositories:
echo "deb https://repos.influxdata.com/debian bullseye stable" | sudo tee /etc/apt/sources.list.d/influxdb.list
- Update the package list:
sudo apt-get update
However, I received the same problem but I could solve this issue using the following steps:
- Remove the existing keyring file:
sudo rm /etc/apt/trusted.gpg.d/influxdb.gpg
- Download a new keyring file using the
wget
command:
wget https://repos.influxdata.com/influxdb.key
- Import the new keyring file into the
trusted.gpg.d
directory:
sudo mv influxdb.key /etc/apt/trusted.gpg.d/
- Update the package list:
sudo apt-get update
I hope this solution solves your problem as well.