The software introduced this time is: Apt-spy
Install Apt-spy
Apt-get Install Apt-spy-y
Choose the best source
apt-spy-d stable-a asia-t 5
The-d option specifies the release version, which can be selected as "stable, testing, unstable". Unstable is an unstable version, stable is a stable version, it is recommended to select stable.
The-a option specifies the area of the Debian installation source server, such as Asia, Europe, and North-america. Asia is Asian, it is recommended to select this item.
-T is the time-out threshold value. Setting a smaller value can ignore slower servers. To select a smaller server, you can select a smaller value.
So the file above is the best Debian source in Asia.
After the command completes, Apt-spy automatically creates the/etc/apt/sources.list.d folder and creates the Apt-spy.list file inside the folder.
Update Replacement Source
We'd better back up the/etc/apt/sources.list file before we replace it.
Cp/etc/apt/sources.list/etc/apt/sources.list.bak
After the backup is complete, we overwrite the contents of the Sources.list file with the "apt-spy.list" file content
Mv/etc/apt/sources.list.d/apt-spy.list/etc/apt/sources.list
Finally, we will be able to use the source to update the normal.
Apt-get Update
The latest and fastest source has been installed.