linux修改源镜像地址
1.1 CentOS修改yum源镜像地址为:mirrors.163.com (也可以改为阿里云镜像)
1、首先备份系统自带yum源配置文件/etc/yum.repos.d/CentOS-Base.repo
[root@iZ91q68xe2hhxlZ yum.repos.d]# mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
2、进入yum源配置文件所在的文件夹
[root@iZ91q68xe2hhxlZ yum.repos.d]# cd /etc/yum.repos.d/
3、下载163的yum源配置文件(CentOS7)
[root@iZ91q68xe2hhxlZ yum.repos.d]# wget http://mirrors.163.com/.help/CentOS7-Base-163.repo
1.2 Ubuntu修改apt-get源
1、首先备份系统自带apt-get源配置文件/etc/apt/sources.list
cp /etc/apt/sources.list /etc/apt/sources.list.bak
2、编辑源配置文件/etc/apt/sources.list,替换内容为:
#阿里云源
deb http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-security main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-updates main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-proposed main restricted universe multiverse
deb-src http://mirrors.aliyun.com/ubuntu/ trusty-backports main restricted universe multiverse
1
2
3
4
5
6
7
8
9
10
#清华大学源
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security universe
deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security multiverse
1
2
3
4
5
6
7
8
9
10
3、更新测试一下
apt-get update
————————————————
原文链接:https://blog.csdn.net/qq_39263240/article/details/79342582
linux修改源镜像地址的更多相关文章
- 配置Linux本地源镜像
今天看到同事做了一个公司本地的apache镜像源,感觉好叼的样子.然后就自己上网找些资料,尝试自己搭建一套出来.然后就有了这篇博文... 声明:本文中充满了浓浓的技术嫉妒的心理,阅读需谨慎. 本文以 ...
- Unraid修改docker镜像地址&默认启动
起源 由于Unraid系统每次启动都会清空Docker的镜像地址配置,故需要默认配置镜像地址 方法 添加修改镜像脚本到开机文件中实现 先找一个镜像加速地址,我使用的是阿里云的容器镜像服务 形如 :ht ...
- 修改nvm镜像地址
最近几个项目切换开发要求Node版本不一样,没法运行.需要用nvm或n等来管理node版本,选谁见仁见智了,反正我选了nvm. 下载个node慢得要死,等半天结果还失败,真是窝火.官方文档又详细过了一 ...
- python学习笔记 | 国内常用源镜像地址
各镜像列表 清华:https://pypi.tuna.tsinghua.edu.cn/simple 阿里云:http://mirrors.aliyun.com/pypi/simple/ 中国科技大学 ...
- 免费yum源镜像地址
收集的镜像,yum源等网站地址 阿里巴巴开源镜像站 https://opsx.alibaba.com/mirror http://mirrors.aliyun.com/centos/ 网易开源镜像站 ...
- Docker系列06:Linux修改docker镜像和容器数据存储位置
指定镜像和容器存放路径的参数是--graph=/var/lib/docker,其默认存储位置为/var/lib/docker, Docker 的配置文件可以设置大部分的后台进程参数,在各个操作系统中的 ...
- Docker 修改国内镜像地址
curl -sSL https://get.daocloud.io/daotools/set_mirror.sh | sh -s http://86d2a50b.m.daocloud.io 该脚本可以 ...
- 修改docker镜像地址
vim /etc/docker/daemon.json,使用国内加速站点镜像 https://registry.docker-cn.com http://hub-mirror.c.163.com ht ...
- 树莓派(Linux)与镜像源
树莓派学习笔记--修改树莓派软件源 1. linux 镜像源文件 >> vim /etc/apt/sources.list 可在树莓派官网 http://www.raspbian.org/ ...
随机推荐
- [刘阳Java]_EasyUI环境搭建_第2讲
在EasyUI的第1讲中我们介绍了学习EasyUI能够做什么,这次我们得快速搭建一个EasyUI环境,来测试一下它的运行效果 1.jQuery EasyUI环境搭建 <script type=& ...
- 高版本(8以上)tomcat不支持rest中的delete和put方式请求怎么办
出现问题 当我们去访问delete方式和put方式: 后来才知道tomcat8以上是不支持delete方式和put方式 解决方法: 在跳转目标的jsp头文件上改为(加上了isErrorPage=&qu ...
- Linux下Apache(HTTP)基础知识梳理-运维笔记
HTTP介绍: HTTP协议是Hyper Text Transfer Protocol(超文本传输协议)的缩写,是用于从万维网(WWW:World Wide Web )服务器传输超文本到本地浏览器的传 ...
- jumpserver 用户,系统用户和管理用户 普通用户和特权用户 区别
前言 现在很多公司都有在用Jumpserver跳板机 有很多人一直对jumpserver的各种用户还不是很了解 当你了解了这几个概念了之后,就能更好的灵活的运用到分配权限当中去. 下面我们一个一个的说 ...
- 使用xampp在本地环境配置虚拟域名
最近在学习ThinkPHP5.1.手册里面提到"实际部署中,应该是绑定域名访问到public目录,确保其它目录不在WEB目录下面."所以把使用xampp在本地配置虚拟域名的过程记录 ...
- Linux + NodeJS 常用命令
Linux系统常用命令 1.su 由当前用户切换至root用户: 2. su username 切换至某一用户: 3.chmod u+w /etc/sudoers 为/etc/sudoers文件添加写 ...
- Python基础之读取ini文件
基本使用方法 第一步:准备一份INI文件.如test1.ini [ITEMS] item1=1 item2=2 item3=3 item4=4 [ITEM1] test1=aaa [ITEM2] te ...
- Python3.9安装PySpider步骤及问题解决
先写一些前言吧,自己感觉python已经有一定的基础了,但是在安装这个过程居然用了一下午,感觉有些收货,特地写下来与大家分享一下. PySpider是一个强大的网络爬虫系统,GitHub地址:http ...
- SpringData JPA 使用原生 SQL
在实现个人博客系统的归档功能的时候,遇上这样的需求: 先把数据库中所有条目的时间按照年月分组,并查询出年月(String)的列表 根据年月字符串查询符合条件的博客,并返回博客列表 由于数据访问层使用的 ...
- tp3常量
__MODULE__ __CONTROLLER__