Debian 里源的优先级是怎么规定的?
- 0次
- 2021-07-09 17:19:22
- idczone
apt-get install 可以通过指定包的版本号或者发行版来安装软件。
但 sources.list 包含多个源地址的时候,在不指定包的版本号,发行版等信息的情况下, apt 是怎么决定从那个仓库里安装软件的?
谢谢解答!
哪个新装哪个
1. 混源死的快
2. Pin-Priority
3. dmo 这种流氓源通过修改 epoch 版本数字,使自己的包看上去比官方的新。
我可以问下...阿里云 ECS
我把 sources.list 换成 ustc 的了,特么还是先在 Aliyun 下载!
主要是添加了 dotdeb 的源。
你可以搜 apt priority
似乎好像是匹配版本号最新的。。。前几天 debian 配置了 kali 的源, kali 内核 3.18 ,原装 debian 3.16 的内核。它提示更新我也没在意,就把 debian 更新成 kali 了。。。到现在 kali 都没删干净。。
你应该看下 /etc/apt/sources.list.d/ 这个目录下有没有东西
看 man apt_preferences ,有详细说明
· Never downgrade unless the priority of an available version exceeds
1000. ("Downgrading" is installing a less recent version of a package
in place of a more recent version. Note that none of APT's default
priorities exceeds 1000; such high priorities can only be set in the
preferences file. Note also that downgrading a package can be risky.)
· Install the highest priority version.
· If two or more versions have the same priority, install the most recent
one (that is, the one with the higher version number ).
· If two or more versions have the same priority and version number but
either the packages differ in some of their metadata or the --reinstall
option is given, install the uninstalled one.
1. 看版本号
2. 看 pin-priority
3&4. 如果版本号和优先级都相同,用其它规则
参考 http://forum.ubuntu.org.cn/viewtopic.php?f=15&t=472760
在一个包已安装的情况下,再安装版本号和优先级完全相同的一个包时
指定了 --reinstall ? 是 --> 安装新包, 否 --> 下一步
元数据完全相同?是 --> 不安装(保留旧包),否 --> 安装新包
(credit to [email&)
没有,空的