1. 程式人生 > >阿裏雲apt-get安裝包時Err:2 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git amd64 1:2.7.4-0ubuntu1.2 404 Not Found

阿裏雲apt-get安裝包時Err:2 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git amd64 1:2.7.4-0ubuntu1.2 404 Not Found

spa http 百度一 main operation 服務器 這不 may fix

新部署的雲服務器出現如下錯誤:

root@iZj6cbjalvhsw0fhndmm5xZ:~# apt-get install git
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  git-man liberror-perl
Suggested packages:
  git-daemon-run | git-daemon-sysvinit git-doc git-el git-email git-gui gitk gitweb git-arch git-cvs git-mediawiki git-svn
The following NEW packages will be installed:
  git git
-man liberror-perl 0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded. Need to get 3,898 kB/3,918 kB of archives. After this operation, 25.6 MB of additional disk space will be used. Do you want to continue? [Y/n] y Ign:1 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-updates/main i386 git-man all 1:2.7.4-0ubuntu1.2 Ign:
2 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git amd64 1:2.7.4-0ubuntu1.2 Ign:1 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git-man all 1:2.7.4-0ubuntu1.2 Err:2 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git amd64 1:2.7.4-0ubuntu1.2 404 Not Found Err:
1 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main i386 git-man all 1:2.7.4-0ubuntu1.2 404 Not Found Err:1 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main i386 git-man all 1:2.7.4-0ubuntu1.2 404 Not Found E: Failed to fetch http://mirrors.cloud.aliyuncs.com/ubuntu/pool/main/g/git/git-man_2.7.4-0ubuntu1.2_all.deb 404 Not Found E: Failed to fetch http://mirrors.cloud.aliyuncs.com/ubuntu/pool/main/g/git/git_2.7.4-0ubuntu1.2_amd64.deb 404 Not Found E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?

這不很明顯是一些安裝源失效,甚至還有命令提示)為了避免像我一樣看到錯誤就百度一波,結果沒找到一個靠譜的方法。

超簡單,更新一下源就可以了。

sudo apt-get update

阿裏雲apt-get安裝包時Err:2 http://mirrors.cloud.aliyuncs.com/ubuntu xenial-security/main amd64 git amd64 1:2.7.4-0ubuntu1.2 404 Not Found