↓ 跳过正文

Debian 全球镜像站的源

正能量 1 分钟阅读 更新于 2026-10-18

解释 Debian 软件源镜像列表的用途,并说明发行版代号与安全更新源的核对方法。

Debian 全球镜像站的源:原站配图。

Debian 全球镜像站

https://www.debian.org/mirror/list.zh-cn.html

以下代码在shell里面执行后,然后执行apt -y update

中国大陆

cat <<EOF > /etc/apt/sources.list 
deb http://ftp.cn.debian.org/debian/ bullseye main non-free contrib
deb-src http://ftp.cn.debian.org/debian/ bullseye main non-free contrib
deb http://ftp.cn.debian.org/debian-security/ bullseye-security main
deb-src http://ftp.cn.debian.org/debian-security/ bullseye-security main
deb http://ftp.cn.debian.org/debian/ bullseye-updates main non-free contrib
deb-src http://ftp.cn.debian.org/debian/ bullseye-updates main non-free contrib
deb http://ftp.cn.debian.org/debian/ bullseye-backports main non-free contrib
deb-src http://ftp.cn.debian.org/debian/ bullseye-backports main non-free contrib
EOF

阿里云

cat <<EOF > /etc/apt/sources.list 
deb http://mirrors.aliyun.com/debian/ bullseye main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ bullseye main non-free contrib
deb http://mirrors.aliyun.com/debian-security/ bullseye-security main
deb-src http://mirrors.aliyun.com/debian-security/ bullseye-security main
deb http://mirrors.aliyun.com/debian/ bullseye-updates main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ bullseye-updates main non-free contrib
deb http://mirrors.aliyun.com/debian/ bullseye-backports main non-free contrib
deb-src http://mirrors.aliyun.com/debian/ bullseye-backports main non-free contrib
EOF

香港

cat <<EOF > /etc/apt/sources.list 
deb http://ftp.hk.debian.org/debian/ bullseye main non-free contrib
deb-src http://ftp.hk.debian.org/debian/ bullseye main non-free contrib
deb http://ftp.hk.debian.org/debian-security/ bullseye-security main
deb-src http://ftp.hk.debian.org/debian-security/ bullseye-security main
deb http://ftp.hk.debian.org/debian/ bullseye-updates main non-free contrib
deb-src http://ftp.hk.debian.org/debian/ bullseye-updates main non-free contrib
deb http://ftp.hk.debian.org/debian/ bullseye-backports main non-free contrib
deb-src http://ftp.hk.debian.org/debian/ bullseye-backports main non-free contrib
EOF

美国

cat <<EOF > /etc/apt/sources.list 
deb http://ftp.debian.org/debian/ bullseye main non-free contrib
deb-src http://ftp.debian.org/debian/ bullseye main non-free contrib
deb http://ftp.debian.org/debian-security/ bullseye-security main
deb-src http://ftp.debian.org/debian-security/ bullseye-security main
deb http://ftp.debian.org/debian/ bullseye-updates main non-free contrib
deb-src http://ftp.debian.org/debian/ bullseye-updates main non-free contrib
deb http://ftp.debian.org/debian/ bullseye-backports main non-free contrib
deb-src http://ftp.debian.org/debian/ bullseye-backports main non-free contrib
EOF

AWS

cat <<EOF > /etc/apt/sources.list 
deb http://cdn-aws.deb.debian.org/debian bullseye main
deb-src http://cdn-aws.deb.debian.org/debian bullseye main
deb http://security.debian.org/debian-security bullseye-security main
deb-src http://security.debian.org/debian-security bullseye-security main
deb http://cdn-aws.deb.debian.org/debian bullseye-updates main
deb-src http://cdn-aws.deb.debian.org/debian bullseye-updates main
deb http://cdn-aws.deb.debian.org/debian bullseye-backports main
deb-src http://cdn-aws.deb.debian.org/debian bullseye-backports main
EOF

补充阅读
#

解释 Debian 软件源镜像列表的用途,并说明发行版代号与安全更新源的核对方法。

如何理解与使用
#

软件源条目需要与本机发行版和版本代号匹配;镜像域名可替换,但路径与仓库分类不能随意混用。

验证与边界
#

修改前保存原列表,更新包索引并检查报错来源。安装镜像、软件包仓库和旧版本归档是不同入口,应根据要下载的内容选择。