linux下的清华镜像源
时间: 2023-08-31 11:13:25 浏览: 320
清华大学提供了多个镜像源供Linux用户使用。以下是一些常用的清华镜像源:
1. 清华大学TUNA镜像源:
- 官方网站:https://mirrors.tuna.tsinghua.edu.cn/
- 镜像地址:https://mirrors.tuna.tsinghua.edu.cn/
2. 清华大学开源软件镜像站:
- 官方网站:https://mirrors.tuna.tsinghua.edu.cn/
- 镜像地址:https://mirrors.tuna.tsinghua.edu.cn/
3. 清华大学CentOS镜像站:
- 官方网站:https://mirrors.tuna.tsinghua.edu.cn/
- 镜像地址:https://mirrors.tuna.tsinghua.edu.cn/
你可以根据自己的需要选择合适的镜像源,并按照对应的设置方法进行配置。
相关问题
linux安装清华镜像源
好的,以下是在Linux系统中安装清华镜像源的步骤:
1. 打开终端,输入以下命令以备份原有的源列表文件:
```
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
```
2. 编辑源列表文件,将原有的内容注释掉,添加清华镜像源的地址。以Ubuntu 20.04为例,输入以下命令:
```
sudo nano /etc/apt/sources.list
```
在打开的文件中添加以下内容:
```
# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
```
3. 更新源列表:
```
sudo apt-get update
```
4. 安装软件时,使用清华镜像源的方式:
```
sudo apt-get install <package-name> -y -o=Acquire::http::timeout=60
```
其中,`<package-name>`为要安装的软件包名称。
linux设置清华镜像源
可以通过以下步骤来设置清华镜像源:
1. 打开终端并输入以下命令:
```
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak
```
2. 使用vim编辑器打开sources.list文件:
```
sudo vim /etc/apt/sources.list
```
3. 将以下内容复制并粘贴到sources.list文件中:
```
# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
```
4. 保存并关闭文件。使用以下命令:
```
:wq
```
5. 更新软件包列表:
```
sudo apt-get update
```
现在,您的Linux系统已经成功设置了清华镜像源。
阅读全文
相关推荐














