涉及的基本配置文件:
apt核心配置文件集中在 /etc/apt
其中,管理软件来源的配置文件如下
sources.list // 主要软件源
sources.list.d/*.list // 个别软件的源
preferences // 控制文件,具体用法参见 man apt_preferences
.list文件的基本语法
deb uri distribution [component1] [component2] [...]
uri apt源的网络地址
distribution 对于Debian就是stable/testing/unstable/experimental,Ubuntu是
component main/contrib/non-free
配置优化的依据
使用synaptic/aptitude升级或者下载软件时,包管理系统为每个apt源地址建立一个下载的线程
component是.list文件基本配置语法中涉及的最小单位,uri>distribution>component;当且仅当uri,distribution,component都相同时,两个component是相同的。
apt源是全球分布的,即uri的选择是最为丰富的
具体技巧
为每个component选择一个uri
不同的component使用不同的uri
最大的component使用最快的uri
现实中优化的sources.list
$cat sources.list
# the main Debian packages.
deb http://www.zentek-international.com/mirrors/debian/ experimental main
deb http://ftp.tw.debian.org/debian/ testing main
deb ftp://opensource.nchc.org.tw/debian/ testing contrib non-free
优化后的效果

apt核心配置文件集中在 /etc/apt
其中,管理软件来源的配置文件如下
sources.list // 主要软件源
sources.list.d/*.list // 个别软件的源
preferences // 控制文件,具体用法参见 man apt_preferences
.list文件的基本语法
deb uri distribution [component1] [component2] [...]
uri apt源的网络地址
distribution 对于Debian就是stable/testing/unstable/experimental,Ubuntu是
feisty/dapper/等
component main/contrib/non-free
配置优化的依据
使用synaptic/aptitude升级或者下载软件时,包管理系统为每个apt源地址建立一个下载的线程
component是.list文件基本配置语法中涉及的最小单位,uri>distribution>component;当且仅当uri,distribution,component都相同时,两个component是相同的。
apt源是全球分布的,即uri的选择是最为丰富的
具体技巧
为每个component选择一个uri
不同的component使用不同的uri
最大的component使用最快的uri
现实中优化的sources.list
$cat sources.list
# the main Debian packages.
deb http://www.zentek-international.com/mirrors/debian/ experimental main
deb http://ftp.tw.debian.org/debian/ testing main
deb ftp://opensource.nchc.org.tw/debian/ testing contrib non-free
优化后的效果
