香港云主机最佳企业级服务商!

ADSL拨号VPS包含了中国大陆(联通,移动,电信,)

中国香港,国外拨号VPS。

当前位置:云主机 > 服务器资讯 >

电信ADSL拨号VPS
联通ADSL拨号VPS
移动ADSL拨号VPS

怎么修改Ubuntu的源列表(source list)详解


时间:2020-10-27 10:57 作者:admin610456


简介

Ubuntu缺省的配置的源并不是国内的服务器,下载更新软件都比较慢,本文介绍如何设置源列表,选择比较快的源以节省下载时间。

配置步骤

1. 备份源列表

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

2. 选择合适的源,替换原文件的内容,保存编辑好的文件

以阿里云更新服务器为例(从实际测试上结果分析,个人认为阿里云比网易和搜狐的服务器要快):

deb http://mirrors.aliyun.com/ubuntu/ XXXXX main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ XXXXX-security main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ XXXXX-updates main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ XXXXX-proposed main restricted universe multiversedeb http://mirrors.aliyun.com/ubuntu/ XXXXX-backports main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ XXXXX main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ XXXXX-security main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ XXXXX-updates main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ XXXXX-proposed main restricted universe multiversedeb-src http://mirrors.aliyun.com/ubuntu/ XXXXX-backports main restricted universe multiverse

根据具体使用的Ubuntu的版本不同,将上述文本中XXXXX替换为下面对应版本的字符串:

Utopic(14.10): utopic
Trusty(14.04): trusty
Precise(12.04): precise
Lucid(10.04): lucid

3. 刷新列表

sudo apt-get update

更新完毕后,再次安装源时,将从新服务器上下载源包。

备注:

Ubuntu 16.04 TLS版本镜像源:

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiversedeb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted universe multiverse# 预发布软件源,不建议启用# deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-proposed main restricted universe multiverse

总结

到此这篇关于怎么修改Ubuntu的源列表(source list)的文章就介绍到这了,更多相关修改Ubuntu源列表(source list)内容请搜索脚本之家以前的文章或继续浏览下面的相关文章希望大家以后多多支持脚本之家!

(责任编辑:admin)






帮助中心
会员注册
找回密码
新闻中心
快捷通道
域名登录面板
虚机登录面板
云主机登录面板
关于我们
关于我们
联系我们
联系方式

售前咨询:17830004266(重庆移动)

企业QQ:383546523

《中华人民共和国工业和信息化部》 编号:ICP备00012341号

Copyright © 2002 -2018 香港云主机 版权所有
声明:香港云主机品牌标志、品牌吉祥物均已注册商标,版权所有,窃用必究

云官方微信

在线客服

  • 企业QQ: 点击这里给我发消息
  • 技术支持:383546523

  • 公司总台电话:17830004266(重庆移动)
  • 售前咨询热线:17830004266(重庆移动)