Backend Development
Python Tutorial
The perfect guide to Tsinghua Mirror Source: Make your software installation smoother
The perfect guide to Tsinghua Mirror Source: Make your software installation smoother

Tsinghua mirror source usage guide: To make your software installation smoother, specific code examples are needed
In the process of daily use of computers, we often need to install various software to meet different needs. However, when installing software, we often encounter problems such as slow download speed and inability to connect, especially when using foreign mirror sources. In order to solve this problem, Tsinghua University provides a mirror source, which provides rich software resources and has very fast download speed. Next, let us learn about the usage strategy of Tsinghua mirror source.
First, we need to set up the Tsinghua mirror source. Open the terminal (for Windows systems, you can search cmd in the start menu and open it), enter the following instructions:
For Ubuntu systems:
sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak #备份原 sources.list 文件 sudo sed -i 's/security.ubuntu.com/mirrors.tuna.tsinghua.edu.cn/g' /etc/apt/sources.list sudo sed -i 's/archive.ubuntu.com/mirrors.tuna.tsinghua.edu.cn/g' /etc/apt/sources.list sudo apt update #更新软件源
For CentOS systems:
sudo cp /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak #备份原 CentOS-Base.repo 文件 sudo sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-Base.repo sudo sed -i 's/#baseurl/baseurl/g' /etc/yum.repos.d/CentOS-Base.repo sudo sed -i 's|http://mirror.centos.org/centos|https://mirrors.tuna.tsinghua.edu.cn/centos|g' /etc/yum.repos.d/CentOS-Base.repo sudo yum makecache #生成缓存元数据
Next, we can use the Tsinghua mirror source to install the software. Taking the apt package manager as an example, enter the following command:
sudo apt install 软件名
where "software name" is the name of the software you need to install. For example, to install Google Chrome, you can enter the following command:
sudo apt install google-chrome-stable
In this way, the apt package manager will automatically download and install Google Chrome from the Tsinghua mirror source, and the download speed will be very fast.
If the software you need to install is not in the default software source, you can also manually add the Tsinghua mirror source for installation. Taking Docker as an example, enter the following command:
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 0EBFCD88 #添加Docker官方GPG密钥 echo "deb [arch=amd64] https://mirrors.tuna.tsinghua.edu.cn/docker-ce/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list sudo apt update sudo apt install docker-ce docker-ce-cli containerd.io #安装Docker
In this example, we first added the official GPG key of Docker, then added the Tsinghua image source, and finally installed Docker using the apt package manager.
Through the above steps, we can easily use the Tsinghua mirror source to install the software. This not only increases the speed of installing software, but also reduces download failures caused by connection issues. At the same time, Tsinghua Image Source also provides various versions of software to meet the needs of different users.
In general, the guide to using Tsinghua Mirror Source includes two steps: setting up Tsinghua Mirror Source and using Tsinghua Mirror Source to install software. Through these steps, we can easily enjoy a fast and stable software download experience. Hope this article is helpful to everyone!
The above is the detailed content of The perfect guide to Tsinghua Mirror Source: Make your software installation smoother. For more information, please follow other related articles on the PHP Chinese website!
Hot AI Tools
Undresser.AI Undress
AI-powered app for creating realistic nude photos
AI Clothes Remover
Online AI tool for removing clothes from photos.
Undress AI Tool
Undress images for free
Clothoff.io
AI clothes remover
AI Hentai Generator
Generate AI Hentai for free.
Hot Article
Hot Tools
Notepad++7.3.1
Easy-to-use and free code editor
SublimeText3 Chinese version
Chinese version, very easy to use
Zend Studio 13.0.1
Powerful PHP integrated development environment
Dreamweaver CS6
Visual web development tools
SublimeText3 Mac version
God-level code editing software (SublimeText3)
Hot Topics
1378
52
Why can't I install the software downloaded from win11?
Dec 26, 2023 pm 09:10 PM
When users use computers, they often encounter the problem that the WIndows 11 system cannot successfully install software. There may be thousands of reasons for this phenomenon. Today I will bring you two common problems and coping strategies. I hope can help you solve this difficult problem. Why the software downloaded in Win11 cannot be installed Reason 1: The installation of third-party software is not allowed in Win11 settings 1. First, open the Windows 11 startup interface, look for the "Settings" option and click on it. 2. After the win11 setting interface pops up, move the mouse to "Application" in the left menu and select it. 3. Then, find and click the "Apps and Features" option on the right to easily switch to the corresponding page
CentOS7 various version image download addresses and version descriptions (including Everything version)
Feb 29, 2024 am 09:20 AM
When loading CentOS-7.0-1406, there are many optional versions. For ordinary users, they don’t know which one to choose. Here is a brief introduction: (1) CentOS-xxxx-LiveCD.ios and CentOS-xxxx- What is the difference between bin-DVD.iso? The former only has 700M, and the latter has 3.8G. The difference is not only in size, but the more essential difference is that CentOS-xxxx-LiveCD.ios can only be loaded into the memory and run, and cannot be installed. Only CentOS-xxx-bin-DVD1.iso can be installed on the hard disk. (2) CentOS-xxx-bin-DVD1.iso, Ce
How to speed up pip download speed
Feb 02, 2024 pm 12:03 PM
How to solve the problem of slow download speed of pip Introduction: When developing in Python, we often use the pip tool to install various third-party modules. However, sometimes we encounter the problem of slow pip download speed, which will cause some trouble to our development work. This article will introduce some methods to solve the problem of slow pip download speed, and give specific code examples to help readers better solve this problem. 1. Change the pip source. By default, pip will use the official source to download modules. However, due to the network environment
How to solve the problem of scipy library installation failure? Quick method sharing
Feb 19, 2024 pm 08:02 PM
What should I do if the scipy library installation fails? Quick solution sharing, specific code examples are required scipy is a powerful Python library widely used in scientific computing, providing many functions for mathematical, scientific and engineering calculations. However, when installing scipy, sometimes you encounter some problems that cause the installation to fail. This article will introduce you to some common scipy installation failure problems, and provide corresponding solutions and specific sample codes. Problem 1: Missing dependent libraries. Before installing scipy, you need to install it first.
How to set up Tsinghua source with pip
Dec 07, 2023 pm 05:11 PM
Setting method: 1. Open a terminal or command prompt window; 2. Run the "touch ~/.pip/pip.conf" command to create a configuration file named pip; 3. Open the pip.conf file, and then add "[global ];index-url = https://pypi.tuna.tsinghua.edu.cn/simple" content, this will set the mirror source of pip to the mirror source of Tsinghua University; 4. Save and close the file.
Simple guide to pip mirror source: easily master how to use it
Jan 16, 2024 am 10:18 AM
Get started easily: How to use pip mirror source With the popularity of Python around the world, pip has become a standard tool for Python package management. However, a common problem that many developers face when using pip to install packages is slowness. This is because by default, pip downloads packages from Python official sources or other external sources, and these sources may be located on overseas servers, resulting in slow download speeds. In order to improve download speed, we can use pip mirror source. What is a pip mirror source? To put it simply, just
Efficient installation: tips and tricks to quickly install the pandas library
Feb 21, 2024 am 09:45 AM
Efficient Installation: Tips and tricks for quickly installing the pandas library, requiring specific code examples Overview: Pandas is a powerful data processing and analysis tool that is very popular among Python developers. However, installing the pandas library may sometimes face some challenges, especially if the network conditions are poor. This article will introduce some tips and tricks to help you quickly install the pandas library, and provide specific code examples. Install using pip: pip is the official package manager for Python
The perfect guide to Tsinghua Mirror Source: Make your software installation smoother
Jan 16, 2024 am 10:08 AM
Tsinghua mirror source usage guide: To make your software installation smoother, specific code examples are needed. In the process of daily use of computers, we often need to install various software to meet different needs. However, when installing software, we often encounter problems such as slow download speed and inability to connect, especially when using foreign mirror sources. In order to solve this problem, Tsinghua University provides a mirror source, which provides rich software resources and has very fast download speed. Next, let us learn about the usage strategy of Tsinghua mirror source. first,


