You need to enable JavaScript to run this app.
最新活动
大模型
产品
解决方案
定价
生态与合作
支持与服务
开发者
了解我们

Kali Linux下APT依赖异常(要求ubuntu-keyring)的修复求助

Kali Linux下APT依赖异常(要求ubuntu-keyring)的修复求助

我最近在Kali Linux上用apt安装R相关包(记得装的是r-base)之后,APT就出问题了。现在不管尝试安装任何包,都会弹出依赖错误,具体信息如下:

Reading package lists... Done

Building dependency tree... Done

Reading state information... Done

You might want to run 'apt --fix-broken install' to correct these.

The following packages have unmet dependencies:

apt : Depends: ubuntu-keyring but it is not installable

apt-utils : Depends: apt (= 2.2.3) but 2.0.2ubuntu0.2 is to be installed

r-cran-mgcv : Depends: r-cran-nlme (>= 3.1-64) but it is not going to be installed

r-recommended : Depends: r-cran-nlme (>= 3.1.52) but it is not going to be installed

E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

我已经尝试过这些操作,但都没用:

  • 执行apt --fix-broken installapt --fix-missing
  • 手动安装缺失的包,比如尝试安装r-cran-nlme时,得到的错误信息如下:
Reading package lists... Done

Building dependency tree... Done

Reading state information... Done

You might want to run 'apt --fix-broken install' to correct these.

The following packages have unmet dependencies:

apt : Depends: ubuntu-keyring but it is not installable

apt-utils : Depends: apt (= 2.2.3) but 2.0.2ubuntu0.2 is to be installed

E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

而且不管尝试安装其他包(比如mit-scheme),都会回到最开始的那堆错误提示。

我觉得特别奇怪的是,明明用的是基于Debian的Kali,系统却一直要求安装ubuntu-keyring

附上我的sources.list内容:

# See https://www.kali.org/docs/general-use/kali-linux-sources-list-repositories/

deb http://http.kali.org/kali kali-rolling main contrib non-free

# Additional line for source packages

deb-src http://http.kali.org/kali kali-rolling main contrib non-free

有没有办法修复这些错误,让APT恢复正常工作?

UPDATE:我试了评论里提到的所有命令(update、upgrade、--fix-broken等),除了apt update会提示“签名无效”并提到公钥之外,其他命令都返回最开始的那个错误。还是搞不懂为什么基于Debian的Kali会索要Ubuntu相关的东西?

备注:内容来源于stack exchange,提问作者Salty Sodiums

火山引擎 最新活动