Debian
由於 GPG 錯誤 (NODATA) 無法更新 Debian Wheezy
我有一台在 Debian Wheezy 上執行的伺服器。
它的 apt 源文件具有以下配置:
deb http://ftp.uk.debian.org/debian/ wheezy main non-free contrib deb-src http://ftp.uk.debian.org/debian/ wheezy main non-free contrib deb http://security.debian.org/ wheezy/updates main contrib non-free deb-src http://security.debian.org/ wheezy/updates main contrib non-free # wheezy-updates, previously known as 'volatile' deb http://ftp.uk.debian.org/debian/ wheezy-updates main contrib non-free deb-src http://ftp.uk.debian.org/debian/ wheezy-updates main contrib non-free
當我嘗試更新時,我收到官方 Debian 儲存庫的 GPG 錯誤:
root@osgb:~# apt-get clean root@osgb:~# apt-get update Get:1 http://security.debian.org wheezy/updates Release.gpg Get:2 http://ftp.uk.debian.org wheezy Release.gpg Get:3 http://ftp.uk.debian.org wheezy-updates Release.gpg Get:4 http://security.debian.org wheezy/updates Release Ign http://security.debian.org wheezy/updates Release E: GPG error: http://security.debian.org wheezy/updates Release: The following signatures were invalid: NODATA 1 NODATA 2
如果我從
sources.list
文件中刪除安全儲存庫並再次嘗試apt-get update
,那麼這次會彈出相同的錯誤ftp.uk.debian.org
root@osgb:~# apt-get clean root@osgb:~# apt-get update Get:1 http://ftp.uk.debian.org wheezy Release.gpg Get:2 http://ftp.uk.debian.org wheezy-updates Release.gpg Get:3 http://ftp.uk.debian.org wheezy Release Ign http://ftp.uk.debian.org wheezy Release E: GPG error: http://ftp.uk.debian.org wheezy Release: The following signatures were invalid: NODATA 1 NODATA 2
到目前為止,我嘗試的是;
- 嘗試了許多其他鏡子,
- 嘗試手動安裝
debian-keyring
和debian-archive-keyring
deb 文件,- 通過創建部分文件夾、apt-get 清理等刪除
/var/lib/apt/lists
並強制重新生成。(如許多文章中所提供的)他們都沒有幫助。
那麼,這個錯誤是關於什麼的,即它是什麼意思?你有什麼想法來解決它嗎?
更新(2015 年 8 月 18 日):
伺服器沒有任何磁碟空間問題。它有一個單獨的分區設置,有足夠的空白空間:
root@osgb:~# df -h Filesystem Size Used Avail Use% Mounted on rootfs 259G 22G 224G 9% / udev 10M 0 10M 0% /dev tmpfs 1.2G 240K 1.2G 1% /run /dev/disk/by-uuid/b76a2c04-44b6-4a9e-bace-7286a67a0f8d 259G 22G 224G 9% / tmpfs 5.0M 0 5.0M 0% /run/lock tmpfs 4.6G 0 4.6G 0% /run/shm
更新(2015 年 8 月 20 日)
正如建議的那樣,我嘗試更新密鑰,但似乎我的伺服器已經擁有最新的密鑰。不幸的是,強大的 NODATA 錯誤仍然存在。
root@osgb:~# apt-key update gpg: key B98321F9: "Squeeze Stable Release Key <debian-release@lists.debian.org>" not changed gpg: key 473041FA: "Debian Archive Automatic Signing Key (6.0/squeeze) <ftpmaster@debian.org>" not changed gpg: key 65FFB764: "Wheezy Stable Release Key <debian-release@lists.debian.org>" not changed gpg: key 46925553: "Debian Archive Automatic Signing Key (7.0/wheezy) <ftpmaster@debian.org>" not changed gpg: key 518E17E1: "Jessie Stable Release Key <debian-release@lists.debian.org>" not changed gpg: key 2B90D010: "Debian Archive Automatic Signing Key (8/jessie) <ftpmaster@debian.org>" not changed gpg: key C857C906: "Debian Security Archive Automatic Signing Key (8/jessie) <ftpmaster@debian.org>" not changed gpg: Total number processed: 7 gpg: unchanged: 7 root@osgb:~# apt-get update Get:1 http://ftp.uk.debian.org wheezy Release.gpg Get:2 http://ftp.uk.debian.org wheezy-updates Release.gpg Get:3 http://ftp.uk.debian.org wheezy Release Ign http://ftp.uk.debian.org wheezy Release E: GPG error: http://ftp.uk.debian.org wheezy Release: The following signatures were invalid: NODATA 1 NODATA 2
=========================================================================
決議和最後的話:
我認為這不可能是防火牆問題,因為使用的埠是 80,我可以手動連接。但是,檢測到防火牆在應用程序級別阻止了伺服器的請求。防火牆認為 apt-get 是一個可疑的應用程序,除非明確允許,否則將被阻止。我們將它添加到了白名單中,它現在可以正常執行了!
當我被本地防火牆阻止時,我遇到了這個問題。您可能希望更改儲存庫行以不使用 ftp 鏡像。
試試http://free.hands.com/debian/>。該行的其餘部分很好;你只是替換<http://ftp.uk.debian.org。