apt-get install update
との違いは何ですかapt-get update
?apt-get install update
私の場合はうまく動作しません。理由がわかりません。
出力apt-get install update
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package updat
出力の一部apt-get update
Ign:2 http://ppa.launchpad.net/cassou/emacs/ubuntu xenial InRelease
Ign:3 http://dl.google.com/linux/chrome/deb stable InRelease
Get:4 http://linux.dropbox.com/ubuntu wily Release [6,596 B]
Hit:5 http://ubuntu-archive.mirror.serveriai.lt xenial InRelease
Hit:6 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu xenial InRelease
Hit:7 http://dl.google.com/linux/chrome/deb stable Release
Hit:9 http://repo.mysql.com/apt/ubuntu xenial InRelease
Ign:10 http://ppa.launchpad.net/kirillshkrogalev/ffmpeg-next/ubuntu xenial InRelease
代わりにを使っても大丈夫ですかapt-get update
?
ありがとう、ピース。
PS:- 私は 16.04 LTS を使用しています。
答え1
apt-get update
apt に、リモート リポジトリから利用可能な新しいパッケージのリストを取得するように指示します (何もインストールされず、利用可能なもののリストを取得するだけであることに注意してください)。
apt-get install update
は、apt に という名前のパッケージをインストールするように指示しますupdate
。その名前のパッケージは、既知のリポジトリに存在しません。これがエラー メッセージの原因です。存在しないパッケージのインストールを要求するたびに、この種のメッセージが表示されます。
私は@terranceのようには考えていませんが、この質問はapt-get update と upgrade の違いは何ですか?提案されたように、そのページを確認したほうがよいでしょう。
2 番目の質問、「代わりに apt-get update を使用しても大丈夫ですか?」については、
それはすべて、何を達成しようとしているかによります。利用可能なソフトウェア パッケージの apt リストを更新することが目的であれば、その通りです。一方、エラー メッセージを出力し、apt の内部状態を変更しないことが目的であれば、その通りではありません。