Ubuntu 更換阿里源


查看新版本信息

  lsb_release -c

Ubuntu 12.04 (LTS)代號為precise。

Ubuntu 14.04 (LTS)代號為trusty。

Ubuntu 15.04 代號為vivid。

Ubuntu 15.10 代號為wily。

Ubuntu 16.04 (LTS)代號為xenial

1.備份源文件

  sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak

2.編輯源列表文件

   sudo vim /etc/apt/sources.list

3.將原有的內容注釋掉,添加以下內容(或修改)

deb http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse

deb http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

deb-src http://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse

4.更新軟件列表

  sudo apt-get update


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM