「sudo apt-get update」コマンドが Ubuntu ボックスでエラーを起こす

「sudo apt-get update」コマンドが Ubuntu ボックスでエラーを起こす

Ubuntu 12.04 ボックスで「sudo apt-get update」コマンドを実行するたびに、次のエラーが発生します。

Fetched 837 B in 0s (29.0 kB/s)
Reading package lists... Done
N: Ignoring 'build' in directory '/etc/apt/sources.list.d/' as it is not a regular file
W: A error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://installsvc.vip precise Release: The following signatures were invalid: KEYEXPIRED 1468001658

W: Failed to fetch http://installsvc.vip/mirrors/apt.puppetlabs.com/dists/precise/Release

W: Some index files failed to download. They have been ignored, or old ones used instead.

何が問題なのか、どうすれば解決できるのか分かりません。

答え1

/etc/apt/sources.list.d/フォルダーまたはファイル自体に期限切れのリポジトリがあります/etc/apt/sources.list

お気に入りのコンソール(私は好きですyakuake)を開いてkonsole(デフォルトはそうだgnome-terminalと思います)、

sudo grep "installsvc" -R /etc/apt/

これにより、「installsvc」が参照されている場所がわかります。そのファイルでは、代わりに Puppet Labs リポジトリに直接リンクする必要があります。installsvc.vip/mirrors/リポジトリ URL から部分を削除します (たとえばgksudo gedit /etc/apt/$fileToChangeName、ファイルを手動で編集し、プログラムを閉じる前に保存することを忘れないでください)。

また、ファイルが間違って配置されているように見えますが、これは何ら害はありませんが、出力で「認識」されていますapt-get

sudo rm /etc/apt/sources.list.d/build

削除されてしまいます (復元はできません) が、まずそれを保持するかどうかを確認し、mvそのchownときに必要になる可能性が高いでしょう。

また、12.04 Precise Pangolin は古くなっていることにも注意してください。新しい Ubuntuaptでは の代わりにを使用しますapt-getが、問題を修正したら次の操作を実行できます。

sudo apt-get autoclean; sudo apt-get update; sudo apt-get dist-upgrade

新しく追加された Puppet Labs リポジトリ (以前のリポジトリはミラーでした) からのものも含め、利用可能な最新のアップグレードを実行します。

関連情報