当前位置:   article > 正文

【Ubuntu】更换阿里源

阿里源

参考网址

1. 备份原来的源

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

2. 使用管理员权限编辑 source.list

sudo vim /etc/apt/sources.list
ubuntu 14.04 LTS (trusty) (EOL) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
  7. deb https://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
  8. deb-src https://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
  9. ## Not recommended
  10. # deb https://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
  11. # deb-src https://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
ubuntu 16.04 LTS (xenial) (EOL) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ xenial main
  2. deb-src https://mirrors.aliyun.com/ubuntu/ xenial main
  3. deb https://mirrors.aliyun.com/ubuntu/ xenial-updates main
  4. deb-src https://mirrors.aliyun.com/ubuntu/ xenial-updates main
  5. deb https://mirrors.aliyun.com/ubuntu/ xenial universe
  6. deb-src https://mirrors.aliyun.com/ubuntu/ xenial universe
  7. deb https://mirrors.aliyun.com/ubuntu/ xenial-updates universe
  8. deb-src https://mirrors.aliyun.com/ubuntu/ xenial-updates universe
  9. deb https://mirrors.aliyun.com/ubuntu/ xenial-security main
  10. deb-src https://mirrors.aliyun.com/ubuntu/ xenial-security main
  11. deb https://mirrors.aliyun.com/ubuntu/ xenial-security universe
  12. deb-src https://mirrors.aliyun.com/ubuntu/ xenial-security universe
ubuntu 18.04 LTS (bionic) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ bionic main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ bionic-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ bionic-updates main restricted universe multiverse
  7. # deb https://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
  8. # deb-src https://mirrors.aliyun.com/ubuntu/ bionic-proposed main restricted universe multiverse
  9. deb https://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
  10. deb-src https://mirrors.aliyun.com/ubuntu/ bionic-backports main restricted universe multiverse
ubuntu 20.04 LTS (focal) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ focal main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ focal-updates main restricted universe multiverse
  7. # deb https://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse
  8. # deb-src https://mirrors.aliyun.com/ubuntu/ focal-proposed main restricted universe multiverse
  9. deb https://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
  10. deb-src https://mirrors.aliyun.com/ubuntu/ focal-backports main restricted universe multiverse
ubuntu 22.04 LTS (jammy) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ jammy main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ jammy-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ jammy-updates main restricted universe multiverse
  7. # deb https://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse
  8. # deb-src https://mirrors.aliyun.com/ubuntu/ jammy-proposed main restricted universe multiverse
  9. deb https://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
  10. deb-src https://mirrors.aliyun.com/ubuntu/ jammy-backports main restricted universe multiverse
ubuntu 23.04 (lunar) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ lunar main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ lunar main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ lunar-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ lunar-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ lunar-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ lunar-updates main restricted universe multiverse
  7. # deb https://mirrors.aliyun.com/ubuntu/ lunar-proposed main restricted universe multiverse
  8. # deb-src https://mirrors.aliyun.com/ubuntu/ lunar-proposed main restricted universe multiverse
  9. deb https://mirrors.aliyun.com/ubuntu/ lunar-backports main restricted universe multiverse
  10. deb-src https://mirrors.aliyun.com/ubuntu/ lunar-backports main restricted universe multiverse
ubuntu 24.04 (noble) 配置如下
  1. deb https://mirrors.aliyun.com/ubuntu/ noble main restricted universe multiverse
  2. deb-src https://mirrors.aliyun.com/ubuntu/ noble main restricted universe multiverse
  3. deb https://mirrors.aliyun.com/ubuntu/ noble-security main restricted universe multiverse
  4. deb-src https://mirrors.aliyun.com/ubuntu/ noble-security main restricted universe multiverse
  5. deb https://mirrors.aliyun.com/ubuntu/ noble-updates main restricted universe multiverse
  6. deb-src https://mirrors.aliyun.com/ubuntu/ noble-updates main restricted universe multiverse
  7. # deb https://mirrors.aliyun.com/ubuntu/ noble-proposed main restricted universe multiverse
  8. # deb-src https://mirrors.aliyun.com/ubuntu/ noble-proposed main restricted universe multiverse
  9. deb https://mirrors.aliyun.com/ubuntu/ noble-backports main restricted universe multiverse
  10. deb-src https://mirrors.aliyun.com/ubuntu/ noble-backports main restricted universe multiverse

3. 更新源

sudo apt-get update

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Li_阴宅/article/detail/1007847
推荐阅读
相关标签
  

闽ICP备14008679号