To change the software source configuration on Ubuntu, you can follow these steps:
Back up the current software source configuration file (optional):
Execute the following command to back up the current software source configuration file:
sudo cp /etc/apt/sources.list /etc/apt/sources.list.backup
Open 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
Select the appropriate software source image:
#character. For example, for Ubuntu 20.04 version, you can use the following mirror source:
deb deb deb deb http://security.ubuntu.com/ubuntu/ focal-security main restricted universe multiverse
Save and close the file:
Ctrl X
, then press Y
Confirm to save changes. Update package list:
Execute the following command to update the software package list to make the new software source configuration take effect:
sudo apt update
Now, you have successfully changed Ubuntu’s software source configuration. By choosing an appropriate mirror source, you can improve the speed and stability of software package downloads. Remember to execute the sudo apt update
command regularly to get the latest package list.
The above is the detailed content of Tutorial on changing configuration source in ubantu.. For more information, please follow other related articles on the PHP Chinese website!