【问题标题】:undoing damage from wrong /etc/apt/sources.list消除错误 /etc/apt/sources.list 造成的损害
【发布时间】:2016-02-20 03:24:30
【问题描述】:

我在 /etc/apt/sources.list 中列出了一些错误的 ubuntu 版本(它列出了精确而不是可靠),我是在对无法自动安装的软件包进行了一整天的解决方法后才发现的。现在一切都恢复了速度,除了一些剩余的麻烦制造者,libglu 和 libboost

root@brain2:/home/jeremy# apt-get install  libglu1-mesa libglu1-mesa-dev
Reading package lists... Done
libglu1-mesa is already the newest version.
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
libglu1-mesa-dev : Depends: libgl1-mesa-dev but it is not going to be    installed or libgl-dev

我已经试过了

apt-get -f install
dpkg --configure -a
apt-get clean
apt-get update
apt-get upgrate

但它们对我没有用。任何咨询信息表示赞赏。

【问题讨论】:

    标签: apt-get package-managers


    【解决方案1】:

    如果您不知道您的 ubuntu 版本和文件内容,很难判断您是否修复了 /apt/etc/sources.list。以下是一些可以帮助您排除故障的命令,或者比我更有经验的人可能会发表评论:

    apt-cache policy <package>
    
    rmadison <package>
    

    apt-cache 策略命令基本上会从您的 /etc/apt/services.list 文件中告诉您该软件包 apt 的哪些版本可供下载。官方文档可在此处获得: https://debian-handbook.info/browse/stable/sect.apt-cache.html

    rmadison 命令执行类似的功能,但有一个关键区别。它不是查看 /etc/apt/services.list 中的内容,而是查询 Debian 档案以查看可用的软件包版本。 rmadison 上的 Debian 手册页在这里: http://manpages.ubuntu.com/manpages/natty/man1/rmadison.1.html

    如果 apt-cache policy 的结果与 rmadison 不同,这可能表明您没有正确告诉 apt 它应该寻找哪些版本。

    【讨论】:

    • 谢谢。如果我还没有擦拭机器并重新安装 ubuntu14.04,我会试一试。
    猜你喜欢
    • 2015-02-01
    • 1970-01-01
    • 2021-06-08
    • 1970-01-01
    • 1970-01-01
    • 2012-08-27
    • 2018-10-25
    • 2012-01-05
    • 1970-01-01
    相关资源
    最近更新 更多