我想重新安装APT工具,所以我卸载了它,然后我意识到如果我只删除/etc/apt目录,它可能会更好。我有什么办法能解决我的问题吗?
我的Ubuntu版本是18.04.2LTS,ls /etc/apt的输出是
root@user-OptiPlex-755:~# ls /etc/apt
ls: cannot access '/etc/apt': No such file or directory更新:我已经重新安装了apt,但是,这是我的输出:
root@user-OptiPlex-755:~# sudo apt install --reinstall apt-utils ubuntu-minimal ubuntu-release-upgrader-gtk ubuntu-desktop update-manager update-notifier update-notifier-common
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package update-manager is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
ubuntu-release-upgrader-core update-manager-core
Package update-notifier-common is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or is only available from another source
Package update-notifier is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
update-notifier-common
Package apt-utils is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
apt
Package ubuntu-release-upgrader-gtk is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'apt-utils' has no installation candidate
E: Unable to locate package ubuntu-minimal
E: Package 'ubuntu-release-upgrader-gtk' has no installation candidate
E: Unable to locate package ubuntu-desktop
E: Package 'update-manager' has no installation candidate
E: Package 'update-notifier' has no installation candidate
E: Package 'update-notifier-common' has no installation candidate`发布于 2019-02-28 22:02:47
更新:我有一个Ubuntu服务器就在我旁边,所以我将它的/etc/apt与这个Ubuntu合并,问题就解决了。谢谢您的帮助,我确信我的第二个问题的核心是我错过了/etc/apt/sources.list文件。一旦我复制了这些文件,我就能够安装已删除的软件包。再次感谢你的帮助!
https://askubuntu.com/questions/1122065
复制相似问题