Debian系统下如何配置 apt-get 的安装源

配置apt-get的网络安装源:


1,编辑/etc/apt/sources.list 文件做以下操作:(建议操作前备份此文件)注释掉本地光盘安装源:

deb cdrom:[Debian GNU/Linux 6.0.4 _Squeeze_ - Official i386 DVD Binary-1 20120128-12:53]/ squeeze contrib main


取消最下面两行官方源前面的注释,添加以源:

deb http://mirrors.163.com/debian/ squeeze main non-free contrib
deb http://mirrors.163.com/debian/ squeeze-proposed-updates main contrib non-free
deb http://mirrors.163.com/debian-security/ squeeze/updates main contrib non-free
deb-src http://mirrors.163.com/debian/ squeeze main non-free contrib
deb-src http://mirrors.163.com/debian/ squeeze-proposed-updates main contrib non-free
deb-src http://mirrors.163.com/debian-security/ squeeze/updates main contrib non-free
deb http://ftp.sjtu.edu.cn/debian/ squeeze main non-free contrib
deb http://ftp.sjtu.edu.cn/debian/ squeeze-proposed-updates main contrib non-free
deb http://ftp.sjtu.edu.cn/debian-security/ squeeze/updates main contrib non-free
deb-src http://ftp.sjtu.edu.cn/debian/ squeeze main non-free contrib
deb-src http://ftp.sjtu.edu.cn/debian/ squeeze-proposed-updates main contrib non-free
deb-src http://ftp.sjtu.edu.cn/debian-security/ squeeze/updates main contrib non-free
2,使用apt-get update 命令进行更新操作,之后就可以网络安装你想要的软件了(前提是debian系统已经可以访问互联网了)


你可能感兴趣的:(Debian,apt-get,源)