debian 9(代号为 stretch)的镜像源已经从jessie更新到了stretch。为了确保安全,首先需要备份原有配置,然后再配置新的镜像源。以下是修改debian 9镜像源的步骤:
1、备份原有镜像源配置文件:执行命令 cp /etc/apt/sources.list /etc/apt/sources.list.bak

2、打开sources.list文件,注释掉原有的CD源代码,并将镜像源地址更新为163镜像源。具体代码如下:
deb http://mirrors.163.com/debian/ stretch main non-free contrib deb http://mirrors.163.com/debian/ stretch-updates main non-free contrib deb http://mirrors.163.com/debian/ stretch-backports main non-free contrib deb-src http://mirrors.163.com/debian/ stretch main non-free contrib deb-src http://mirrors.163.com/debian/ stretch-updates main non-free contrib deb-src http://mirrors.163.com/debian/ stretch-backports main non-free contrib deb http://mirrors.163.com/debian-security/ stretch/updates main non-free contrib deb-src http://mirrors.163.com/debian-security/ stretch/updates main non-free contrib
配置完成后,输入命令 apt update 来更新系统镜像源配置文件。












