deb http://apt-mirror.sourceforge.net/ apt-mirror/
2:apt-get update
3:apt-get install apt-mirror
4:根据需要修改/etc/apt/mirror.list,添加离你最近的源
deb http://debian.cn99.com/debian/ etch main contrib non-free
deb-src http://debian.cn99.com/debian/ etch main contrib non-free
deb http://security.debian.org/ etch/updates main contrib non-free
deb-src http://security.debian.org/ etch/updates main contrib non-free
#deb http://archive.Ubuntu.com/ubuntu hardy main restricted universe multiverse
#deb http://archive.Ubuntu.com/ubuntu hardy-updates main restricted universe multiverse
##deb http://archive.Ubuntu.com/ubuntu hardy-backports main restricted universe multiverse
#deb http://archive.Ubuntu.com/ubuntu hardy-security main restricted universe multiverse
##deb http://archive.Ubuntu.com/ubuntu hardy-proposed main restricted universe multiverse
#
#deb-src http://archive.Ubuntu.com/ubuntu hardy main restricted universe multiverse
#deb-src http://archive.Ubuntu.com/ubuntu hardy-updates main restricted universe multiverse
##deb-src http://archive.Ubuntu.com/ubuntu hardy-backports main restricted universe multiverse
#deb-src http://archive.Ubuntu.com/ubuntu hardy-security main restricted universe multiverse
##deb-src http://archive.Ubuntu.com/ubuntu hardy-proposed main restricted universe multiverse
clean http://debian.cn99.com/debian/
#
# deb cdrom:[Debian GNU/Linux 4.0 r0 _Etch_ - Official i386 NETINST Binary-1 20070407-11:29]/ etch contrib main
5:获得源信息
su apt-mirror -c apt-mirror
可能会报错:
“
jumping:~# su apt-mirror -c apt-mirror
Downloading 30 index files using 20 threads...
Begin time: Fri Aug 29 11:38:38 2008
[20]... [19]... [18]... [17]... [16]... [15]... [14]... [13]... [12]... [11]... [10]... [9]... [8]... [7]... [6]... [5]... [4]... [3]... [2]... [1]... [0]...
End time: Fri Aug 29 11:40:49 2008
