apt-get 未注册新添加的存储库

apt-get 未注册新添加的存储库

我已将新的存储库添加到 /etc/apt/sources.list:

deb http://mirrors.nic.cz/R/bin/linux/debian wheezy-cran3/

但是当我安装新软件包 (r-base) 时,它们不会从那里获取!当我查看是否考虑了这个存储库时(使用一个恶作剧),但似乎不是:

root@apkserver2:~# apt-cache policy
Package files:
 100 /var/lib/dpkg/status
     release a=now
 500 http://hwraid.le-vert.net/debian/ wheezy/main i386 Packages
     release o=hwraid.le-vert.net,a=wheezy,l=hwraid.le-vert.net,c=main
     origin hwraid.le-vert.net
 500 http://ftp.cz.debian.org/debian/ wheezy-updates/main Translation-en
 500 http://ftp.cz.debian.org/debian/ wheezy-updates/main i386 Packages
     release o=Debian,a=stable-updates,n=wheezy-updates,l=Debian,c=main
     origin ftp.cz.debian.org
 500 http://security.debian.org/ wheezy/updates/main Translation-en
 500 http://security.debian.org/ wheezy/updates/main i386 Packages
     release v=7.0,o=Debian,a=stable,n=wheezy,l=Debian-Security,c=main
     origin security.debian.org
 500 http://ftp.cz.debian.org/debian/ wheezy/main Translation-en
 500 http://ftp.cz.debian.org/debian/ wheezy/main i386 Packages
     release v=7.8,o=Debian,a=stable,n=wheezy,l=Debian,c=main
     origin ftp.cz.debian.org
Pinned packages:

如何解决这个问题?更改 sources.list 后是否需要运行或重新启动任何程序?

答案1

当您在 Debian 中添加新的存储库时,您还需要更新软件包列表。apt-get update以 root 身份运行以获取新列表。您可能还需要清除软件包缓存,因此请运行apt-get clean(也以 root 身份运行)。

相关内容