Ubunutu的apt-get软件下载工具的国内镜像源
2024-10-21 11:44:02
Ubunutu安装时,默认没有给apt-get配置国内镜像源,其默认配置的镜像源国内不能访问到,安装软件处处失败,所以我们需要配置国内镜像源:
首先避免出错,我们先备份原sources.list文件,这是一个好习惯。避免出错
cp /etc/apt/sources.list /etc/sources.list.bak
删除sources.list中的原内容,ubuntu16.04添加如下内容,可以使用阿里云的镜像源:
deb http://mirrors.aliyun.com/ubuntu/ xenial main
deb-src http://mirrors.aliyun.com/ubuntu/ xenial main
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main
deb http://mirrors.aliyun.com/ubuntu/ xenial universe
deb-src http://mirrors.aliyun.com/ubuntu/ xenial universe
deb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates universe
deb http://mirrors.aliyun.com/ubuntu/ xenial-security main
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main
deb http://mirrors.aliyun.com/ubuntu/ xenial-security universe
deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security universe
最后使用命令更新源信息:
sudo apt-get update
最新文章
- vim没有颜色
- c++编译错误提示及解决
- paip.注册java程序为LINUX系统服务的总结。
- Testlink中分析结果的图表显示乱码
- Android7.0 Phone应用源码分析(一) phone拨号流程分析
- net core 实战之 redis 负载均衡和";高可用";实现
- js 函数闭包内部返回函数体调用方法难点解答
- Signs of a poorly written jQuery plugin 翻译 (Jquery插件开发注意事项,Jquey官方推荐)
- vs2012如何创建报表
- React中的Statics对象
- Maven插件实现的autoconfig机制(转)
- 从string.size()和string.length()聊到长度的问题和一个关于数据结构定义的技巧
- IOS--UIButton的使用方法
- hdoj 1175 (bfs)
- redis五种数据类型
- MS SQL xp_instance_regwrite设置注册表疑惑
- mybatis 在xml文件中获取当前时间的sql
- Python爬虫入门教程 36-100 酷安网全站应用爬虫 scrapy
- C#中Skip和Take的用法
- 文件传输协议(FTP)