Home > Article > Computer Tutorials > How to configure software mirror source in Ubuntu?
Configuring software mirror sources in Ubuntu is an effective way to increase download speeds and obtain software updates. The following are the configuration steps:
Ctrl Alt T
key combination can open the terminal. Back up the original software source configuration file (optional): If you want to keep the original software source configuration backup, you can execute the following command to backup /etc/apt/sources.list
document:
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
Edit the software source configuration file: Use a text editor (such as nano
or vi
) to open the software source configuration file:
sudo nano /etc/apt/sources.list
Choose a suitable mirror source: Choose a suitable mirror source based on your geographical location or personal preference. Here are some common Ubuntu image sources:
Alibaba Cloud Mirror Source: Add the following mirror source configuration to the file:
deb deb http://mirrors.aliyun.com/ubuntu/ focal-security main restricted universe multiverse deb deb
Tsinghua University Mirror Source: Add the following mirror source configuration to the file:
deb deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse deb deb
University of Science and Technology of China Mirror Source: Add the following mirror source configuration to the file:
deb deb https://mirrors.ustc.edu.cn/ubuntu/ focal-security main restricted universe multiverse deb deb
You can choose other mirror sources as needed.
nano
In the editor, press Ctrl O
Save the file and press Ctrl X
Close the editor. Update the package list: Execute the following command to update the package list and use the new mirror source:
sudo apt update
Now, your Ubuntu system has been configured with a new software image source. You can use the apt
or apt-get
command to install, update, or uninstall the software package, and obtain the software package from the selected mirror source.
The above is the detailed content of How to configure software mirror source in Ubuntu?. For more information, please follow other related articles on the PHP Chinese website!