首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >查找Debian包的源代码存储库

问查找Debian包的源代码存储库
EN

Server Fault用户
提问于 2016-04-14 14:03:42
回答 1查看 174关注 0票数 2

我有一个Debian喘息服务器,它在/etc/apt下配置了许多源

似乎有很多重复的来源,我想简化这一点。为了避免破坏任何东西,并错过任何软件包升级,我不想删除任何源,这是包的唯一可用来源。

我知道,我可以通过以下方法看到可用于升级的软件包的来源

代码语言:javascript
复制
apt-get upgrade --just-print

如何列出所有已安装软件包的来源?

EN

回答 1

Server Fault用户

发布于 2016-04-28 20:51:52

问得好。据我所知,在您从sources.list-file中删除deb-行之后,无法找到安装包的位置。

保存所有源的唯一方法如下所示:

代码语言:javascript
复制
% grep -h -e "^.*deb " /etc/apt/sources.list /etc/apt/sources.list.d/* | sort | uniq
deb http://apt.spideroak.com/ubuntu-spideroak-hardy/ release restricted
deb http://APT.spideroak.com/ubuntu-spideroak-hardy/ release restricted
deb     http://deb.grml.org/ grml-stable  main
deb http://debian.lagis.at/debian/ jessie main contrib non-free
deb http://debian.lagis.at/debian/ jessie-updates main contrib non-free
deb http://download.virtualbox.org/virtualbox/debian jessie contrib
deb http://extra.linuxmint.com betsy main
deb http://http.debian.net/debian jessie-backports main
deb     http://http.debian.net/debian stretch main contrib non-free
deb http://mirror.karneval.cz/pub/linux/linuxmint/packages betsy main upstream import 
deb http://repo.linrunner.de/debian jessie main
deb http://repository.spotify.com stable non-free
deb http://security.debian.org/ jessie/updates main contrib non-free
deb http://www.deb-multimedia.org jessie main non-free

为了验证我的陈述,我尝试了如下:

代码语言:javascript
复制
% apt-cache policy | sed -n -e "/^.[0-9]/p" | cut -f3,4 -d' ' | sort | uniq
http://apt.spideroak.com/ubuntu-spideroak-hardy/ release/restricted
http://APT.spideroak.com/ubuntu-spideroak-hardy/ release/restricted
http://deb.grml.org/ grml-stable/main
http://debian.lagis.at/debian/ jessie/contrib
http://debian.lagis.at/debian/ jessie/main
http://debian.lagis.at/debian/ jessie/non-free
http://debian.lagis.at/debian/ jessie-updates/contrib
http://debian.lagis.at/debian/ jessie-updates/main
http://debian.lagis.at/debian/ jessie-updates/non-free
http://download.virtualbox.org/virtualbox/debian/ jessie/contrib
http://extra.linuxmint.com/ betsy/main
http://http.debian.net/debian/ jessie-backports/main
http://mirror.karneval.cz/pub/linux/linuxmint/packages/ betsy/import
http://mirror.karneval.cz/pub/linux/linuxmint/packages/ betsy/main
http://mirror.karneval.cz/pub/linux/linuxmint/packages/ betsy/upstream
http://repo.linrunner.de/debian/ jessie/main
http://repository.spotify.com/ stable/non-free
http://security.debian.org/ jessie/updates/contrib
http://security.debian.org/ jessie/updates/main
http://security.debian.org/ jessie/updates/non-free
http://www.deb-multimedia.org/ jessie/main
http://www.deb-multimedia.org/ jessie/non-free
/var/lib/dpkg/status

基本上是一样的。

票数 1
EN
页面原文内容由Server Fault提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://serverfault.com/questions/770334

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档